wglCreateContextAttribsARB not needed anymore?

Is wglCreateContextAttribsARB not needed anymore? I just recently noticed with the latest drivers from both NVIDIA and AMD that just calling wglCreateContext gives me access to all OpenGL versions and associated extensions up to the version supported without having to call wglCreateContextAttribsARB. Is this a bug or was it intended? Has anybody else experienced this?

It is needed, more than ever before. There are several attributes/flags that cannot be set without that function.

wglCreateContext should make non-debug compatibility non-forward profile/context. If it is so, there is no bug.

I’m fully aware of what the specification says for the expected behavior of wglCreateContextAttribsARB and its uses. However that wasn’t my question. My question was really whether or not anybody else has experienced this behavior.

I’m really sorry my English is so bad that you cannot understand me (and even I didn’t understand what you wrote). There are three questions and I’ll explicitly answer to each one.

It is needed since there is no other way to define context’s attributes.

It is intended behavior.

Yes

There is a clear state in the spec:

Intended (for backward compatibility), and yes. If compatibility profile alone is all you need, just use *CreateContext and be happy.

However, *CreateContextAttribs is useful for creating a debug profile if nothing else (produces perf tips from the driver on what you’re doing). You can also target a specific OpenGL version. And/or if you’re a purist, you might want to target the core profile which keeps you from using any of the deprecated features.

For NVIDIA and ATI, if you just want features then *CreateContext is fine.

But, for Intel with Mesa under Linux, using glxCreateContext will give one a GL3.0 context; if you want greater than 3.0 under Intel with Mesa (or really any driver implemented via Mesa) then you must use glxCreateContextAttribsARB AND select core profile. One important feature is that geometry shader development in Mesa has been geometry shaders as found in 3.2, not as found in GL_ARB_geometry_shader; so there is a real advantage of glxCreateContextAttribsARB over glxCreateContext for Mesa based GL implementations.

This topic was automatically closed 183 days after the last reply. New replies are no longer allowed.