Sign in to follow this  
Butter

rendering context with no window?

Recommended Posts

Is it possible to get a rendering context without an application instance or window handle? Can you do that without using an extensions? Thanks for any info.

Share this post


Link to post
Share on other sites
no, I dont think this is possible... this is probably a long shot
but take a look at PBuffers I cant quite remember whether or not they required
an exisiting GL context (AFAIK they are windowing extensions... so they might
not..)

Cheers
-Danu

Share this post


Link to post
Share on other sites
I guess I should elaborate on what I am trying to do. I am working on processing live video, some of it is done with OpenGL. I would like to put all of this code into a DLL. This mean that I would have no window. Without a window, is there any way to get a Device Context to use to create a rendering context?

Share this post


Link to post
Share on other sites
well.. thats an odd situation, but here's my 2c

create a window using CreateWindow, make it very very small and
only request a basic OpenGL context, create it with the SW_HIDE flag (ie, don't
make the window visible) now using that windows rendering context create
a PBuffer with your required dimensions/attributes and use that for rendering
or processing or whatever. that should work.

PS. there are some PBuffer implementations floating around the net, so you most
likely won't have to re-implement a wrapper.

Cheers
-Danu

Share this post


Link to post
Share on other sites
Just to clear things up, you cant issue any OpenGL commands without a valid context, which means you need a window to create that context in.

The ARB is working on a method which doesnt require a window however, but I wouldnt expect it, or any implimentations, any time soon.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this