Re: [GtkGLExt] off-screen rendering
- From: "Christophe Dehais" <christophe dehais gmail com>
- To: "Jean Bréfort" <jean brefort normalesup org>
- Cc: gtkglext-list gnome org
- Subject: Re: [GtkGLExt] off-screen rendering
- Date: Fri, 30 Nov 2007 17:21:21 +0100
On Nov 30, 2007 5:16 PM, Christophe Dehais <christophe dehais gmail com> wrote:
> Then something like this in my main() does what I need:
>
> context = gdk_gl_context_get_current();
> if (!gdk_gl_drawable_gl_begin (pixmap, context)) {
> printf ("*** problem beginning OpenGL operations\n");
> return 0;
> }
> printf ("Direct rendering ?: %d\n", gdk_gl_context_is_direct (context));
>
> do_some_processing_or_drawing_using_opengl ();
>
> gdk_gl_drawable_gl_end (pixmap);
>
where of course
pixmap = init_offline_context (width, height);
width and height can even be 1 if you e.g. intend to use FBOs instead
of the default OpenGL framebuffer.
C.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]