Re: [GtkGLExt] What about GTK+-3.0 support?



On Mon, 2011-06-27 at 14:24 -0400, Braden McDaniel wrote:
> I'm not ruling out the possibility of something happening in the future; 
> but I know of no movement on this now and there hasn't been any in a 
> while.  If you're someone who has informed ideas about what the API 
> should look like, I encourage you to make your voice heard.

I've been thinking about this recently as well.  In addition to just
adding GTK3 support, it'd be a good opportunity to improve the API in
other ways as well, since GTK3 breaks API compatibility anyway.  In
particular, support for OpenGL 3 and newer would be useful -- the GL
context has to be created a little differently, using
GLX_ARB_create_context or GLX_ARB_create_context_profile.

Since GdkDrawable no longer exists in GDK3 as far as I can tell,
GdkGLDrawable will probably need to be reworked.  GDK's functions for
creating Cairo contexts may be a good model to follow.

(Caveat to the below:  I haven't actually used GtkGLExt directly, only
gtkglextmm, so I might be overlooking differences between the two.)

Might it make sense to separate the processes of creating a GL context
and creating a GL widget to render using the context?  Right now it
seems that each GL-enabled widget wants to create its own context, so
the application must wait for the widget to be mapped before it can do
"initialization" tasks like loading textures and compiling shaders.  It
would be useful to do those things beforehand, and display the GL
widgets only if the initialization succeeds.

If support for OpenGL 3+ is added, the widget can't create a context
entirely automatically anyway, since needs to know what version and
profile to use.
-- 
Mike Paul <mike wyzardry net>



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