RSS/Atom feed Twitter
Site is read-only, email is disabled

about gimp zoom preview new

This discussion is connected to the gimp-developer-list.gnome.org mailing list which is provided by the GIMP developers and not related to gimpusers.com.

This is a read-only list on gimpusers.com so this discussion thread is read-only, too.

17 of 17 messages available
Toggle history

Please log in to manage your subscriptions.

about gimp_zoom_preview_new Luis A. Florit 12 Mar 15:22
  about gimp_zoom_preview_new gg@catking.net 12 Mar 18:16
   about gimp_zoom_preview_new Chris Seaton 12 Mar 22:55
    about gimp_zoom_preview_new Michael Schumacher 12 Mar 23:22
  about gimp_zoom_preview_new Sven Neumann 12 Mar 22:37
about gimp zoom preview new Luis A. Florit 12 Mar 22:48
about gimp zoom preview new Luis A. Florit 12 Mar 23:11
  about gimp zoom preview new Sven Neumann 12 Mar 23:13
   about gimp zoom preview new Sven Neumann 12 Mar 23:28
about gimp zoom preview new Luis A. Florit 12 Mar 23:36
  about gimp zoom preview new Ori Bernstein 13 Mar 00:55
   about gimp zoom preview new Luis A. Florit 13 Mar 03:13
    about gimp zoom preview new Sven Neumann 13 Mar 08:29
     about gimp zoom preview new Luis A. Florit 14 Mar 01:21
      about gimp zoom preview new Sven Neumann 14 Mar 08:06
  about gimp zoom preview new Sven Neumann 13 Mar 08:26
about gimp zoom preview new Luis A. Florit 13 Mar 02:24
Luis A. Florit
2007-03-12 15:22:49 UTC (about 17 years ago)

about gimp_zoom_preview_new

Pals,

I realized that gimp 2.3.15 (and some versions before) comes with zoom for previews. A very useful feature for what I want to develop (a noise reduction plugin).

I added a line 'gimp_zoom_preview_new (drawable);' that I got from http://developer.gimp.org/api/2.0/libgimp/GimpZoomPreview.html The plugin complies just fine, but when trying to run it in gimp 2.3.15 the plugin crashes with a message in the console:

: symbol lookup error: : undefined symbol: gimp_zoom_preview_new (gimp-2.3:21083): Gimp-Plug-In-WARNING **: gimp-2.3: plug_in_flush(): error: Broken pipe

So, what am I doing wrong?

Thanks!

Luis.

gg@catking.net
2007-03-12 18:16:14 UTC (about 17 years ago)

about gimp_zoom_preview_new

On Mon, 12 Mar 2007 15:22:49 +0100, Luis A. Florit wrote:

(gimp-2.3:21083): Gimp-Plug-In-WARNING **: gimp-2.3: plug_in_flush(): error: Broken pipe

This is nothing to do with the zoom preview mate, you've got a blocked toilet !! I should call out a plumber , this could get messy. This often happens in older properties due to subsidence or nearby tree roots.

LOL !

sorry , had to laugh at the way that error came out. ;)

Sven Neumann
2007-03-12 22:37:33 UTC (about 17 years ago)

about gimp_zoom_preview_new

Hi,

On Mon, 2007-03-12 at 11:22 -0300, Luis A. Florit wrote:

I added a line 'gimp_zoom_preview_new (drawable);' that I got from http://developer.gimp.org/api/2.0/libgimp/GimpZoomPreview.html The plugin complies just fine, but when trying to run it in gimp 2.3.15 the plugin crashes with a message in the console:

: symbol lookup error: : undefined symbol: gimp_zoom_preview_new

Looks like the plug-in is not picking up recent enough versions of libgimpui. Try ldd on the executable.

Sven

Luis A. Florit
2007-03-12 22:48:48 UTC (about 17 years ago)

about gimp zoom preview new

On Mon, 12 Mar 2007 15:22:49 +0100, Luis A. Florit wrote:

(gimp-2.3:21083): Gimp-Plug-In-WARNING **: gimp-2.3: plug_in_flush(): error: Broken pipe

This is nothing to do with the zoom preview mate, you've got a blocked toilet!! I should call out a plumber, this could get messy. This often happens in older properties due to subsidence or nearby tree roots.

LOL !

sorry, had to laugh at the way that error came out. ;)

Sorry, I didn't understand your answer...

I just want to add zoom buttons to the preview window. I saw that many plugins use this. How to do it?

Thanks,

Luis.

Chris Seaton
2007-03-12 22:55:12 UTC (about 17 years ago)

about gimp_zoom_preview_new

I've been on this mailing list for two days and this is the second time I've seen someone arrogantly laughing at someone's very reasonable questions.

Chris Seaton

On 12 Mar 2007, at 17:16, gg@catking.net wrote:

On Mon, 12 Mar 2007 15:22:49 +0100, Luis A. Florit wrote:

(gimp-2.3:21083): Gimp-Plug-In-WARNING **: gimp-2.3: plug_in_flush(): error: Broken pipe

This is nothing to do with the zoom preview mate, you've got a blocked toilet !! I should call out a plumber , this could get messy. This often
happens in older properties due to subsidence or nearby tree roots.

LOL !

sorry , had to laugh at the way that error came out. ;)

Luis A. Florit
2007-03-12 23:11:09 UTC (about 17 years ago)

about gimp zoom preview new

Hi,

On Mon, 2007-03-12 at 11:22 -0300, Luis A. Florit wrote:

I added a line 'gimp_zoom_preview_new (drawable);' that I got from http://developer.gimp.org/api/2.0/libgimp/GimpZoomPreview.html The plugin complies just fine, but when trying to run it in gimp 2.3.15 the plugin crashes with a message in the console:

: symbol lookup error: :

undefined symbol: gimp_zoom_preview_new

Looks like the plug-in is not picking up recent enough versions of libgimpui. Try ldd on the executable.

Mmmm... I see...

# ldd .gimp-2.3/plug-ins/anulardenoise linux-gate.so.1 => (0x00cf4000) libgimpui-2.0.so.0 => /usr/lib/libgimpui-2.0.so.0 (0x004f1000) libgimpwidgets-2.0.so.0 => /usr/lib/libgimpwidgets-2.0.so.0 (0x003db000) libgimp-2.0.so.0 => /usr/lib/libgimp-2.0.so.0 (0x0034d000) libgimpcolor-2.0.so.0 => /usr/lib/libgimpcolor-2.0.so.0 (0x002cc000) libgimpmath-2.0.so.0 => /usr/lib/libgimpmath-2.0.so.0 (0x00101000) libgimpbase-2.0.so.0 => /usr/lib/libgimpbase-2.0.so.0 (0x0033c000) libgtk-x11-2.0.so.0 => /usr/lib/libgtk-x11-2.0.so.0 (0x04fa0000) libgdk-x11-2.0.so.0 => /usr/lib/libgdk-x11-2.0.so.0 (0x053b0000) libatk-1.0.so.0 => /usr/lib/libatk-1.0.so.0 (0x02aaa000) libgdk_pixbuf-2.0.so.0 => /usr/lib/libgdk_pixbuf-2.0.so.0 (0x029d8000) libm.so.6 => /lib/libm.so.6 (0x00d4a000) libpangocairo-1.0.so.0 => /usr/lib/libpangocairo-1.0.so.0 (0x0543f000) libpango-1.0.so.0 => /usr/lib/libpango-1.0.so.0 (0x0533f000) libcairo.so.2 => /usr/lib/libcairo.so.2 (0x02a3c000) libgobject-2.0.so.0 => /lib/libgobject-2.0.so.0 (0x02979000) libgmodule-2.0.so.0 => /lib/libgmodule-2.0.so.0 (0x029d3000) libdl.so.2 => /lib/libdl.so.2 (0x00d73000) libglib-2.0.so.0 => /lib/libglib-2.0.so.0 (0x028d9000) libc.so.6 => /lib/libc.so.6 (0x00110000) libgimpmodule-2.0.so.0 => /usr/lib/libgimpmodule-2.0.so.0 (0x00297000) libX11.so.6 => /usr/lib/libX11.so.6 (0x00ae4000) libXfixes.so.3 => /usr/lib/libXfixes.so.3 (0x0278c000) libfontconfig.so.1 => /usr/lib/libfontconfig.so.1 (0x0274f000) libXext.so.6 => /usr/lib/libXext.so.6 (0x00d9b000) libXrender.so.1 => /usr/lib/libXrender.so.1 (0x00de9000) libXinerama.so.1 => /usr/lib/libXinerama.so.1 (0x00dfa000) libXi.so.6 => /usr/lib/libXi.so.6 (0x02a32000) libXrandr.so.2 => /usr/lib/libXrandr.so.2 (0x00df4000) libXcursor.so.1 => /usr/lib/libXcursor.so.1 (0x02780000) /lib/ld-linux.so.2 (0x00bea000) libpangoft2-1.0.so.0 => /usr/lib/libpangoft2-1.0.so.0 (0x05380000) libfreetype.so.6 => /usr/lib/libfreetype.so.6 (0x026a5000) libz.so.1 => /usr/lib/libz.so.1 (0x00d79000) libpng12.so.0 => /usr/lib/libpng12.so.0 (0x02727000) libXau.so.6 => /usr/lib/libXau.so.6 (0x00d8e000) libXdmcp.so.6 => /usr/lib/libXdmcp.so.6 (0x00d93000) libexpat.so.0 => /lib/libexpat.so.0 (0x00dc6000)

I compiled gimp with './configure --prefix=/opt/gimp' for it not to touch my stable gimp 2.2 RPM install. I am compiling the plug-in with

/opt/gimp/bin/gimptool-2.0 --install

Thanks,

Luis.

Sven Neumann
2007-03-12 23:13:32 UTC (about 17 years ago)

about gimp zoom preview new

Hi,

On Mon, 2007-03-12 at 19:11 -0300, Luis A. Florit wrote:

I compiled gimp with './configure --prefix=/opt/gimp' for it not to touch my stable gimp 2.2 RPM install. I am compiling the plug-in with

/opt/gimp/bin/gimptool-2.0 --install

You will probably have to set PKG_CONFIG_PATH to get this right.

Sven

Michael Schumacher
2007-03-12 23:22:25 UTC (about 17 years ago)

about gimp_zoom_preview_new

Chris Seaton wrote:

I've been on this mailing list for two days and this is the second time I've seen someone arrogantly laughing at someone's very reasonable questions.

Took me some time to get the joke, but it is one, IMO:

On 12 Mar 2007, at 17:16, gg@catking.net wrote:

On Mon, 12 Mar 2007 15:22:49 +0100, Luis A. Florit wrote:

(gimp-2.3:21083): Gimp-Plug-In-WARNING **: gimp-2.3:

The "punchline" is the following:

plug_in_flush(): error: Broken pipe

This is nothing to do with the zoom preview mate, you've got a blocked toilet !! I should call out a plumber , this could get messy.

flush() does get the toilet reference, broken pipe to the "blocked" (although it is debatable if "broken" and be read as "blocked" in this case)

sorry , had to laugh at the way that error came out. ;)

The last line should show how this message was meant to be understood - and it does hint towards the reason as well.

HTH, Michael

Sven Neumann
2007-03-12 23:28:23 UTC (about 17 years ago)

about gimp zoom preview new

Hi,

On Mon, 2007-03-12 at 23:13 +0100, Sven Neumann wrote:

You will probably have to set PKG_CONFIG_PATH to get this right.

Thinking about it, perhaps gimptool-2.0 should do this for you. We could add something like

PKG_CONFIG_PATH=$libdir/pkgconfig:$PKG_CONFIG_PATH

to gimptool-2.0.in. Would this be a good idea or am I missing something?

Sven

Luis A. Florit
2007-03-12 23:36:42 UTC (about 17 years ago)

about gimp zoom preview new

Hi Sven,

On Mon, 2007-03-12 at 19:11 -0300, Luis A. Florit wrote:

I compiled gimp with './configure --prefix=/opt/gimp' for it not to touch my stable gimp 2.2 RPM install. I am compiling the plug-in with

/opt/gimp/bin/gimptool-2.0 --install

You will probably have to set PKG_CONFIG_PATH to get this right.

I am doing something wrong... I tried with this command:

export PKG_CONFIG_PATH=/opt/gimp/lib/pkgconfig ; /opt/gimp/bin/gimp-2.3

and I still having the same error.

Thanks,

Luis.

Ori Bernstein
2007-03-13 00:55:22 UTC (about 17 years ago)

about gimp zoom preview new

On Mon, 12 Mar 2007 19:36:42 -0300, "Luis A. Florit" said:

I am doing something wrong... I tried with this command:

Yes, yes you are.

export PKG_CONFIG_PATH=/opt/gimp/lib/pkgconfig ; /opt/gimp/bin/gimp-2.3

and I still having the same error.

PKG_CONFIG_PATH only affects where stuff looks as it gets compiled. Also, you'd want to use PKG_CONFIG_PATH=/opt/gimp/lib/pkgconfig:$PKG_CONFIG_PATH, to keep the old stuff in there (assuming it's non-empty).

IIRC, you'd want to set $LD_LIBRARY_PATH=/opt/gimp/lib/ for runtime.

Luis A. Florit
2007-03-13 02:24:36 UTC (about 17 years ago)

about gimp zoom preview new

gg,

I didn't get your joke at a first sight. English is not my language...

BTW, it was funny. :)

L.

Luis A. Florit
2007-03-13 03:13:25 UTC (about 17 years ago)

about gimp zoom preview new

Hi Ori,

* El 12/03/07 a las 19:55, Ori Bernstein chamullaba:

On Mon, 12 Mar 2007 19:36:42 -0300, "Luis A. Florit" said:

I am doing something wrong... I tried with this command:

Yes, yes you are.

export PKG_CONFIG_PATH=/opt/gimp/lib/pkgconfig ; /opt/gimp/bin/gimp-2.3

and I still having the same error.

PKG_CONFIG_PATH only affects where stuff looks as it gets compiled. Also, you'd want to use PKG_CONFIG_PATH=/opt/gimp/lib/pkgconfig:$PKG_CONFIG_PATH, to keep the old stuff in there (assuming it's non-empty).

IIRC, you'd want to set $LD_LIBRARY_PATH=/opt/gimp/lib/ for runtime.

Interesting.
In fact, I didn't recompile GIMP, I only did a

export LD_LIBRARY_PATH=/opt/gimp/lib:$LD_LIBRARY_PATH

and the zoom preview worked! :)

However, I am getting many errors. One of them is due to the fact that I don't know how to retrieve the origin of the preview. For non-zoom previews, the funcion 'gimp_preview_get_position' gives you the origin. I wasn't able to find the correspoding one for zoom_preview (gimp_zoom_preview_get_position does not exist?!). Another one is that I don't know which is the equivalent to 'gimp_drawable_preview_draw_region' for zoom_preview.....

Thanks for the help, and the prompt answers!!!

Luis.

Sven Neumann
2007-03-13 08:26:58 UTC (about 17 years ago)

about gimp zoom preview new

Hi,

On Mon, 2007-03-12 at 19:36 -0300, Luis A. Florit wrote:

I am doing something wrong... I tried with this command:

export PKG_CONFIG_PATH=/opt/gimp/lib/pkgconfig ; /opt/gimp/bin/gimp-2.3

and I still having the same error.

Are you actually using the LD_LIBRARY_PATH environment variables as explained in the release notes for the development version?

Sven

Sven Neumann
2007-03-13 08:29:39 UTC (about 17 years ago)

about gimp zoom preview new

Hi,

On Mon, 2007-03-12 at 23:13 -0300, Luis A. Florit wrote:

However, I am getting many errors. One of them is due to the fact that I don't know how to retrieve the origin of the preview. For non-zoom previews, the funcion 'gimp_preview_get_position' gives you the origin. I wasn't able to find the correspoding one for zoom_preview (gimp_zoom_preview_get_position does not exist?!).

GimpZoomPreview is derived from GimpPreview so you can use all methods from GimpPreview.

Another one is that I don't know which is the equivalent to 'gimp_drawable_preview_draw_region' for zoom_preview.....

Perhaps have a look at one of the many plug-ins in the source distribution that use a GimpZoomPreview...

Sven

Luis A. Florit
2007-03-14 01:21:36 UTC (about 17 years ago)

about gimp zoom preview new

* El 13/03/07 a las 8:29, Sven Neumann chamullaba:

On Mon, 2007-03-12 at 23:13 -0300, Luis A. Florit wrote:

However, I am getting many errors. One of them is due to the fact that I don't know how to retrieve the origin of the preview. For non-zoom previews, the funcion 'gimp_preview_get_position' gives you the origin. I wasn't able to find the correspoding one for zoom_preview (gimp_zoom_preview_get_position does not exist?!).

GimpZoomPreview is derived from GimpPreview so you can use all methods from GimpPreview.

Oops...

Another one is that I don't know which is the equivalent to 'gimp_drawable_preview_draw_region' for zoom_preview.....

Perhaps have a look at one of the many plug-ins in the source distribution that use a GimpZoomPreview...

I did it already.
And all of them implemented it with complicated code. No easy command. So, by your answer I understand that there is no 'gimp_zoom_preview_draw_region' equivalent (I wonder why...). I will try to understand what those codes do and implement then one.

Thanks,

Luis.

Sven Neumann
2007-03-14 08:06:46 UTC (about 17 years ago)

about gimp zoom preview new

Hi,

On Tue, 2007-03-13 at 21:21 -0300, Luis A. Florit wrote:

And all of them implemented it with complicated code. No easy command. So, by your answer I understand that there is no 'gimp_zoom_preview_draw_region' equivalent (I wonder why...).

The point of using a zoomed out preview is that the effect can be applied on the zoomed out view. Otherwise it would be unreasonably slow. So there's no equivalent of draw_region() because you aren't working directly with pixel regions here. You are usually using the gimp_drawable_get_sub_thumbnail() function to retrieve a scaled view of the pixel data and then apply your effect on these preview pixels.

Sven