Abstract base class for device context managment
More...
#include <Inventor/devices/SoDeviceContext.h>
Inheritance diagram for SoDeviceContext:Public Member Functions | |
| SoDeviceContext () | |
| Default constructor. | |
| virtual void | bind ()=0 |
| Bind this context to the current thread. | |
| virtual void | unbind ()=0 |
| Unbind this context from the current thread. | |
| virtual bool | isCompatible (SoDeviceContext *) const =0 |
| Returns true if two contexts are compatible. | |
| virtual bool | isCurrent () const =0 |
| Returns true if the context is valid and currently active. | |
| void | setSharable (bool sharable) |
| Sets the sharable property. | |
| bool | isSharable () const |
| Returns the sharable status of this context. | |
| virtual bool | setSharedWith (SoDeviceContext *sourceCtx) |
| Share this context. | |
| virtual bool | isSharedWith (const SoDeviceContext *context) const |
| Returns the current sharing state with passed context. | |
| virtual int | getSharedId () const |
| Returns an id common to all compatible/shared contexts. | |
| SoDeviceContextSharedGroup * | getSharedGroup () const |
| Returns the current shared group. | |
| bool | setSharedGroup (SoDeviceContextSharedGroup *sharedGroup) |
| Explicitly change the sharedGroup. | |
| virtual bool | isValid () const |
| Returns true if this context is valid. | |
Public Member Functions inherited from SoRefCounter | |
| void | ref () const |
| Adds a reference to an instance. | |
| void | unref () const |
| Removes a reference from an instance. | |
| void | unrefNoDelete () const |
| unrefNoDelete() should be called when it is desired to decrement the reference count, but not delete the instance if this brings the reference count to zero. | |
| int | getRefCount () const |
| Returns current reference count. | |
| void | lock () const |
| lock this instance. | |
| void | unlock () const |
| unlock this instance. | |
Friends | |
| class | SoGLContext_qtcontext_OIV_875_Stub |
Abstract base class for device context managment
This class provides generic functions to manage or get data about specific device contexts.
Reference counting:
Definition at line 61 of file SoDeviceContext.h.
| SoDeviceContext::SoDeviceContext | ( | ) |
Default constructor.
|
pure virtual |
Bind this context to the current thread.
Implemented in SoCpuContext, and SoGLContext.
| SoDeviceContextSharedGroup * SoDeviceContext::getSharedGroup | ( | ) | const |
Returns the current shared group.
|
virtual |
Returns an id common to all compatible/shared contexts.
|
pure virtual |
Returns true if two contexts are compatible.
Compatible means that using a buffer from one of these contexts inside the other will not require copying the data.
Implemented in SoCpuContext, and SoGLContext.
|
pure virtual |
Returns true if the context is valid and currently active.
Implemented in SoCpuContext, and SoGLContext.
| bool SoDeviceContext::isSharable | ( | ) | const |
Returns the sharable status of this context.
By default, a context is sharable.
|
virtual |
Returns the current sharing state with passed context.
Reimplemented in SoGLContext.
|
virtual |
Returns true if this context is valid.
Reimplemented in SoGLContext.
| void SoDeviceContext::setSharable | ( | bool | sharable | ) |
Sets the sharable property.
| bool SoDeviceContext::setSharedGroup | ( | SoDeviceContextSharedGroup * | sharedGroup | ) |
Explicitly change the sharedGroup.
|
virtual |
Share this context.
|
pure virtual |
Unbind this context from the current thread.
Implemented in SoCpuContext, and SoGLContext.
|
friend |
Definition at line 148 of file SoDeviceContext.h.