Re: [GtkGLExt] Drawing Each Frame
- From: jlm <jsado_sc4 earthlink net>
- Cc: gtkglext-list gnome org
- Subject: Re: [GtkGLExt] Drawing Each Frame
- Date: Sat, 12 Nov 2005 06:33:58 -0500
You probably want to call gtk_widget_queue_draw() after updating the
particles.
flood wrote:
Hello, I'm making a particle system using gtkglext but I have ran into a
problem. Whenever I run my program it only updates the scene when the window
is not in focus. Meaning once a few particles are drawn it stops updating
the window. I have click on another window and drag it and only than do I
see the scene being updated.
My setup is simple:
/* Initialize, Resize, and Render */
g_signal_connect_after (G_OBJECT (gtkinit->drawing_area), "realize",
G_CALLBACK (InitGL), NULL);
g_signal_connect (G_OBJECT (gtkinit->drawing_area), "configure_event",
G_CALLBACK (ResizeWin), NULL);
g_signal_connect (G_OBJECT (gtkinit->drawing_area), "expose_event",
G_CALLBACK (DrawScene), NULL);
/* Show the Program */
gtk_container_add(GTK_CONTAINER(winInit.window), winInit.drawing_area);
gtk_widget_show (winInit.drawing_area);
gtk_widget_show (winInit.window);
gtk_main();
During expose_event I call two functions which update the particles.
--
~flood
------------------------------------------------------------------------
_______________________________________________
gtkglext-list mailing list
gtkglext-list gnome org
http://mail.gnome.org/mailman/listinfo/gtkglext-list
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]