Classes | Public Member Functions | Public Attributes | Protected Types | Protected Member Functions | Protected Attributes | List of all members
osg::GLBufferObject Class Reference
Inheritance diagram for osg::GLBufferObject:
Inheritance graph


struct  BufferEntry

Public Member Functions

 GLBufferObject (unsigned int contextID, BufferObject *bufferObject, unsigned int glObjectID=0)
void setProfile (const BufferObjectProfile &profile)
const BufferObjectProfilegetProfile () const
void setBufferObject (BufferObject *bufferObject)
BufferObjectgetBufferObject ()
unsigned int getContextID () const
GLuint & getGLObjectID ()
GLuint getGLObjectID () const
GLsizeiptr getOffset (unsigned int i) const
void bindBuffer ()
void unbindBuffer ()
void release ()
 release GLBufferObject to the orphan list to be reused or deleted. More...
bool isDirty () const
void dirty ()
void clear ()
void compileBuffer ()
void deleteGLObject ()
void assign (BufferObject *bufferObject)
bool isPBOSupported () const
bool hasAllBufferDataBeenRead () const
void setBufferDataHasBeenRead (const osg::BufferData *bd)
void downloadBuffer (unsigned int entryidx)
void commitDMA (unsigned int entryidx)
- Public Member Functions inherited from osg::GraphicsObject
 GraphicsObject ()
- Public Member Functions inherited from osg::Referenced
 Referenced ()
 Referenced (bool threadSafeRefUnref)
 Deprecated, Referenced is now always uses thread safe ref/unref, use default Referenced() constructor instead. More...
 Referenced (const Referenced &)
Referencedoperator= (const Referenced &)
virtual void setThreadSafeRefUnref (bool)
 Deprecated, Referenced is always theadsafe so there method now has no effect and does not need to be called. More...
bool getThreadSafeRefUnref () const
 Get whether a mutex is used to ensure ref() and unref() are thread safe. More...
OpenThreads::MutexgetRefMutex () const
 Get the mutex used to ensure thread safety of ref()/unref(). More...
int ref () const
 Increment the reference count by one, indicating that this object has another pointer which is referencing it. More...
int unref () const
 Decrement the reference count by one, indicating that a pointer to this object is no longer referencing it. More...
int unref_nodelete () const
 Decrement the reference count by one, indicating that a pointer to this object is no longer referencing it. More...
int referenceCount () const
 Return the number of pointers currently referencing this object. More...
ObserverSetgetObserverSet () const
 Get the ObserverSet if one is attached, otherwise return NULL. More...
ObserverSetgetOrCreateObserverSet () const
 Get the ObserverSet if one is attached, otherwise create an ObserverSet, attach it, then return this newly created ObserverSet. More...
void addObserver (Observer *observer) const
 Add a Observer that is observing this object, notify the Observer when this object gets deleted. More...
void removeObserver (Observer *observer) const
 Remove Observer that is observing this object. More...

Public Attributes

unsigned int _frameLastUsed
GLvoid * _persistentDMA

Protected Types

typedef std::vector< BufferEntryBufferEntries

Protected Member Functions

virtual ~GLBufferObject ()
unsigned int computeBufferAlignment (unsigned int pos, unsigned int bufferAlignment) const
- Protected Member Functions inherited from osg::GraphicsObject
virtual ~GraphicsObject ()
- Protected Member Functions inherited from osg::Referenced
virtual ~Referenced ()
void signalObserversAndDelete (bool signalDelete, bool doDelete) const
void deleteUsingDeleteHandler () const

Protected Attributes

unsigned int _contextID
GLuint _glObjectID
BufferObjectProfile _profile
unsigned int _allocatedSize
bool _dirty
BufferEntries _bufferEntries
- Protected Attributes inherited from osg::Referenced
OpenThreads::AtomicPtr _observerSet
OpenThreads::Atomic _refCount

Additional Inherited Members

- Static Public Member Functions inherited from osg::Referenced
static OpenThreads::MutexgetGlobalReferencedMutex ()
 Get the optional global Referenced mutex, this can be shared between all osg::Referenced. More...
static void setDeleteHandler (DeleteHandler *handler)
 Set a DeleteHandler to which deletion of all referenced counted objects will be delegated. More...
static DeleteHandlergetDeleteHandler ()
 Get a DeleteHandler. More...

Member Typedef Documentation

◆ BufferEntries

typedef std::vector<BufferEntry> osg::GLBufferObject::BufferEntries

Constructor & Destructor Documentation

◆ GLBufferObject()

osg::GLBufferObject::GLBufferObject ( unsigned int  contextID,
BufferObject bufferObject,
unsigned int  glObjectID = 0 

◆ ~GLBufferObject()

virtual osg::GLBufferObject::~GLBufferObject ( )

Member Function Documentation

◆ assign()

void osg::GLBufferObject::assign ( BufferObject bufferObject)

◆ bindBuffer()

void osg::GLBufferObject::bindBuffer ( )

◆ clear()

void osg::GLBufferObject::clear ( )

◆ commitDMA()

void osg::GLBufferObject::commitDMA ( unsigned int  entryidx)

◆ compileBuffer()

void osg::GLBufferObject::compileBuffer ( )

◆ computeBufferAlignment()

unsigned int osg::GLBufferObject::computeBufferAlignment ( unsigned int  pos,
unsigned int  bufferAlignment 
) const

◆ deleteGLObject()

void osg::GLBufferObject::deleteGLObject ( )

◆ dirty()

void osg::GLBufferObject::dirty ( )

◆ downloadBuffer()

void osg::GLBufferObject::downloadBuffer ( unsigned int  entryidx)

◆ getBufferObject()

BufferObject* osg::GLBufferObject::getBufferObject ( )

◆ getContextID()

unsigned int osg::GLBufferObject::getContextID ( ) const

◆ getGLObjectID() [1/2]

GLuint& osg::GLBufferObject::getGLObjectID ( )

◆ getGLObjectID() [2/2]

GLuint osg::GLBufferObject::getGLObjectID ( ) const

◆ getOffset()

GLsizeiptr osg::GLBufferObject::getOffset ( unsigned int  i) const

◆ getProfile()

const BufferObjectProfile& osg::GLBufferObject::getProfile ( ) const

◆ hasAllBufferDataBeenRead()

bool osg::GLBufferObject::hasAllBufferDataBeenRead ( ) const

◆ isDirty()

bool osg::GLBufferObject::isDirty ( ) const

◆ isPBOSupported()

bool osg::GLBufferObject::isPBOSupported ( ) const

◆ release()

void osg::GLBufferObject::release ( )

release GLBufferObject to the orphan list to be reused or deleted.

◆ setBufferDataHasBeenRead()

void osg::GLBufferObject::setBufferDataHasBeenRead ( const osg::BufferData bd)

◆ setBufferObject()

void osg::GLBufferObject::setBufferObject ( BufferObject bufferObject)

◆ setProfile()

void osg::GLBufferObject::setProfile ( const BufferObjectProfile profile)

◆ unbindBuffer()

void osg::GLBufferObject::unbindBuffer ( )

Member Data Documentation

◆ _allocatedSize

unsigned int osg::GLBufferObject::_allocatedSize

◆ _bufferEntries

BufferEntries osg::GLBufferObject::_bufferEntries

◆ _bufferObject

BufferObject* osg::GLBufferObject::_bufferObject

◆ _contextID

unsigned int osg::GLBufferObject::_contextID

◆ _dirty

bool osg::GLBufferObject::_dirty

◆ _extensions

GLExtensions* osg::GLBufferObject::_extensions

◆ _frameLastUsed

unsigned int osg::GLBufferObject::_frameLastUsed

◆ _glObjectID

GLuint osg::GLBufferObject::_glObjectID

◆ _next

GLBufferObject* osg::GLBufferObject::_next

◆ _persistentDMA

GLvoid* osg::GLBufferObject::_persistentDMA

◆ _previous

GLBufferObject* osg::GLBufferObject::_previous

◆ _profile

BufferObjectProfile osg::GLBufferObject::_profile

◆ _set

GLBufferObjectSet* osg::GLBufferObject::_set

The documentation for this class was generated from the following file: