Re: [Gimp-developer] Plug-in preview API proposal

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

Ernst Lippe <ernstl@xxxxxxxxx> writes:

> As promised here is my API proposal for a plug-in preview widget. 
> You can find it at http://refocus.sourceforge.net/preview.

In the section "Design" in "Calling the render function" you state:

 A somewhat smarter version of this preview used a different
 approach. The rendering function had to call back to the GTK main
 loop, so it could process new events.

I wouldn't call this a smart version since this is something that you
better not try to implement. Why do you want to drive the GTK+ main
loop yourself? This only leads to really complicated behaviour (as you
seem to have experienced yourself). The easiest approach to this
problem seems to be to split the rendering function into small
chunks. Instead of calling some function that processes events, the
render function returns after computing a small tile of the preview
image. The standard GTK+ main loop takes back control, user events are
processed and if it ever becomes idle again, the list of invalid tiles
is examined and the render function is called with the next area to
update. Did you consider this approach?


Salut, Sven

[Index of Archives]     [Video For Linux]     [Photo]     [Yosemite News]     [gtk]     [GIMP for Windows]     [KDE]     [GEGL]     [Gimp's Home]     [Gimp on GUI]     [Gimp on Windows]     [Steve's Art]

  Powered by Linux