This is a convenience class to check if an OpenGL context is currently active and available.
More...
#include <ocean/GLvish/MetaGLViewerCreator.hpp>
|
| virtual const void * | CurrentGLContextID () const =0 |
| | Get a an OpenGL context ID, which is useful to check if at this point of the code calling OpenGL functions is allowed.
|
| |
| auto | getObjectCountID () const noexcept |
| | Get a unique ID for this object in the given domain.
|
| |
|
bool | isIdentical (const WeakPtr< GLContextChecker, GLContextChecker > &PossibleSelf) const noexcept |
| | Check if this object is identical to the one used by the given pointer.
|
| |
| void | mkAutoDestructive () |
| | Marks this object as being automatically destructed, e.g.
|
| |
|
refcount_t | refcount () const noexcept |
| | The strong reference count.
|
| |
|
| ReferenceBase (GLContextChecker *that) noexcept |
| | Constructor, initializes reference counter to zero.
|
| |
| const auto & | self () const |
| | Return weak pointer to the object self.
|
| |
|
refcount_t | wrefcount () const noexcept |
| | The weak reference count.
|
| |
|
|
using | reference_domain_t = GLContextChecker |
| | The type of the base class.
|
| |
|
using | SelfPtr_t = WeakPtr< GLContextChecker, GLContextChecker > |
| | Type for a pointer to this object itself.
|
| |
| virtual void | extremeUnction () |
| | A virtual function that will be called just before the object is destroyed.
|
| |
| ReferenceBase & | operator= (const ReferenceBase &R) |
| | Protected assignment operator (should not be called).
|
| |
|
void | suicide () |
| | Delete this.
|
| |
|
virtual | ~ReferenceBase () |
| | Virtual destructor.
|
| |
This is a convenience class to check if an OpenGL context is currently active and available.
{
not good... no OpenGL context...
}
static int invalidContext()
Definition MetaGLViewerCreator.cpp:59
◆ CurrentGLContextID()
| virtual const void * Wizt::GLContextChecker::CurrentGLContextID |
( |
| ) |
const |
|
pure virtual |
Get a an OpenGL context ID, which is useful to check if at this point of the code calling OpenGL functions is allowed.
This is especcially useful for destructors of objects that clean up OpenGL objects. No explicit OpenGL context object is available then, but this function allows to check for validity. Such object may only be destroyed if there is a current OpenGL context, otherwise it will lead to runtime errors.
◆ invalidContext()
| int Wizt::GLContextChecker::invalidContext |
( |
| ) |
|
|
static |