![]() |
Onsens
1.0
This is C++ game about bitwise logic.
|
Base class for classes that require an OpenGL context. More...
#include <GlResource.hpp>
Classes | |
class | TransientContextLock |
RAII helper class to temporarily lock an available context for use. More... | |
Protected Member Functions | |
GlResource () | |
Default constructor. More... | |
~GlResource () | |
Destructor. More... | |
Static Protected Member Functions | |
static void | registerContextDestroyCallback (ContextDestroyCallback callback, void *arg) |
Register a function to be called when a context is destroyed. More... | |
Base class for classes that require an OpenGL context.
This class is for internal use only, it must be the base of every class that requires a valid OpenGL context in order to work.
Definition at line 46 of file GlResource.hpp.
|
protected |
Default constructor.
|
protected |
Destructor.
|
staticprotected |
Register a function to be called when a context is destroyed.
This is used for internal purposes in order to properly clean up OpenGL resources that cannot be shared between contexts.
callback | Function to be called when a context is destroyed |
arg | Argument to pass when calling the function |