Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 18 Apr 2011
Offline Last Active Jun 19 2011 12:15 AM

#4820709 What exactly is an "OpenGL Context"? How does it work?

Posted by on 07 June 2011 - 04:24 PM

Hello, im in the process of attempting to teach myself OpenGL programming but so far all i've managed to do is become extremely confused. I have a few questions, they are probably pretty silly and i apologize but still, any help would be appreciated!

From my experiments and what i've read before using any OpenGL function calls and such an "OpenGL context" is required. Im a bit puzzled as to what this actually means, my initial thought was that this would just be a window capable of displaying pixel data, but clearly there is something more to it.

What actually defines a window as being an OpenGL context?
How does OpenGL know if a window is a valid OpenGL context?

Lets say on operating system X i've used the native API to create a window, what steps would i then need to take to make it capable of displaying openGL data, do native api's include special openGL settings or something?

Currently im using SFML to abstract the creation of an OpenGL context and it works perfectly but i'd still like to have a at least vague idea of the inner working that are going on...

For example SFML 1.6 does not work with OpenGL 3.0+ whereas SFML 2.0 does, i don't understand this, why is displaying the pixels rendered by OpenGL so complicated that compatibility becomes an issue?

Thank you for any help, and im sorry that my writing is not very good!