Open Inventor Reference
SoGLVBOElement Class Reference

Manage the currently registered VBOs in the state (for coordinates, normals, colors and tex coords) (MeVis ONLY)

#include <Inventor/elements/SoGLVBOElement.h>

Inheritance diagram for SoGLVBOElement:
SoElement

List of all members.

Public Types

enum  VBOType {
  VERTEX_VBO = 0, NORMAL_VBO = 1, COLOR_VBO = 2, TEXCOORD_VBO = 3,
  MAX_VBO_TYPES = 4
}

Public Member Functions

virtual void init (SoState *state)
 Initializes element.
virtual void push (SoState *state)
 Pushes/pops element.
virtual void pop (SoState *state, const SoElement *childElt)
SoVBOgetVBO (VBOType type) const
 get a vbo
SbBool matches (const SoElement *elt) const
 Returns TRUE if the element matches another element (of the same class, presumably) with respect to cache validity.
SoElementcopyMatchInfo () const
 Create a copy that we can put in a cache used list and call matches() on later.

Static Public Member Functions

static const SoGLVBOElementgetInstance (SoState *state)
 get const instance
static void unsetVBO (SoState *state, VBOType type)
 remove the given VBO from element
static void unsetVBOIfEnabled (SoState *state, VBOType type)
 remove the given VBO from element if the element is enabled in state.
static void updateVBO (SoState *state, VBOType type, SoVBO **vbo, int numBytes=0, const void *data=NULL, uint32_t nodeId=0)
 creates or clear a VBO of given type.
static void initClass ()
 Initializes the SoGLVBOElement class.

Protected Member Functions

virtual ~SoGLVBOElement ()
 Destructor.

Detailed Description

Definition at line 48 of file SoGLVBOElement.h.


Member Enumeration Documentation

Enumerator:
VERTEX_VBO 
NORMAL_VBO 
COLOR_VBO 
TEXCOORD_VBO 
MAX_VBO_TYPES 

Definition at line 55 of file SoGLVBOElement.h.


Constructor & Destructor Documentation

virtual SoGLVBOElement::~SoGLVBOElement ( ) [protected, virtual]

Member Function Documentation

SoElement* SoGLVBOElement::copyMatchInfo ( ) const [virtual]

Implements SoElement.

static const SoGLVBOElement* SoGLVBOElement::getInstance ( SoState state) [static]
SoVBO* SoGLVBOElement::getVBO ( VBOType  type) const
virtual void SoGLVBOElement::init ( SoState state) [virtual]

Called for first element of its kind in stack. Default method does nothing.

Reimplemented from SoElement.

static void SoGLVBOElement::initClass ( ) [static]

Reimplemented from SoElement.

SbBool SoGLVBOElement::matches ( const SoElement elt) const [virtual]

If you write a matches() method, you must also write a copy() method.

Implements SoElement.

virtual void SoGLVBOElement::pop ( SoState state,
const SoElement childElt 
) [virtual]

Reimplemented from SoElement.

virtual void SoGLVBOElement::push ( SoState state) [virtual]

Allows for side effects to occur. Default methods do nothing.

Reimplemented from SoElement.

static void SoGLVBOElement::unsetVBO ( SoState state,
VBOType  type 
) [static]
static void SoGLVBOElement::unsetVBOIfEnabled ( SoState state,
VBOType  type 
) [static]
static void SoGLVBOElement::updateVBO ( SoState state,
VBOType  type,
SoVBO **  vbo,
int  numBytes = 0,
const void *  data = NULL,
uint32_t  nodeId = 0 
) [static]

Passing the data in is optional and may be done later on the allocated vbo. The ownership of the VBO is passed to the called.


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