View Full Version : OpenGl context 03-31-2012, 03:36 AM I was
reading a tutorial programming in opengl version 4.1, the
tutorial talks about creating opengl contexts.My question is it
mandatory for using functions provided by opengl version 4.1 and
above . Currently I am using this code to set up my window and
its properties. int main(int argc,char** argv) Will the openGl
context do the above function of creating a window,setting the
size,etc I dont get the purpose of creating an opengl context
,can someone explain it to me? 03-31-2012, 05:42 AM An OpenGL
context is the data structure that collects all states needed by
server to render an image. It contains references to buffers,
textures, shaders, etc. OpenGL API doesn’t define how rendering
context is defined, it is up to the native window system; but
none of OpenGL commands can be executed until rendering context
is created and made current. A rendering context should be
compatible with a window it will render to. There can be several
contexts per applicat