GlContextSave Class Reference

A class for saving and restoring the current OpenGL context. More...

#include <GlContextSave.h>

List of all members.

Public Member Functions

 GlContextSave ()
 GlContextSave (QGLWidget *pWidget)
 GlContextSave (QGLContext *pContext)
 ~GlContextSave ()


Detailed Description

A class for saving and restoring the current OpenGL context.

When created, the GlContextSave object records the current OpenGL context. When destroyed, it makes the recorded context current again, regardless of changes that have occurred while the GlContextSave object existed.

Definition at line 22 of file GlContextSave.h.


Constructor & Destructor Documentation

GlContextSave::GlContextSave (  ) 

Records the current OpenGL context.

GlContextSave::GlContextSave ( QGLWidget *  pWidget  ) 

Records the current OpenGL context and makes the specified context current.

Parameters:
pWidget The widget containing the context to make current. If NULL is specified, the current context will not be changed.

GlContextSave::GlContextSave ( QGLContext *  pContext  ) 

Records the current OpenGL context and makes the specified context current.

Parameters:
pContext The context to make current. If NULL is specified, the current context will not be changed.

GlContextSave::~GlContextSave (  ) 

Restores the current OpenGL context to the one that the constructor recorded.


Software Development Kit - Opticks 4.9.0 Build 16218