Hi,

I'm trying to make an app which would render smooth 'animation' in more than 30 
fps. Animated objects are drawn through cairo to Cairo.ImageSurface and then 
drawn in OnExposeEvent to Gtk.DrawingArea. 

Second thread updates scene and calls QueueDraw on the widget. I think this 
technique (to draw everything in OnExposeEvent) is good for painting widgets 
but not for performance rendering. 
Screen response is low because rendering depends on UI message queue. I need to 
render graphics directly. 
I can't use GDK functions in the second thread because they need to be called 
on the first thread where GUI was created and I'd like to avoid locking also 
(gdk_threads_enter / gdk_threads_leave).

My idea is to create offscreen buffer where the second thread can render 
graphics and then somehow blit it fast to the gtk drawing area or window 
directly by flipping (changing only pointers or I don't know).

Do you have any idea how to do that?

[pinggi]
_______________________________________________
Gtk-sharp-list maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/gtk-sharp-list

Reply via email to