cocos2d-x  3.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
VertexBuffer Class Reference

#include <CCVertexIndexBuffer.h>

Inheritance diagram for VertexBuffer:
Ref

Public Member Functions

int getSizePerVertex () const
 
int getVertexNumber () const
 
bool updateVertices (const void *verts, int count, int begin)
 
int getSize () const
 
GLuint getVBO () const
 
- Public Member Functions inherited from Ref
void retain ()
 Retains the ownership. More...
 
void release ()
 Releases the ownership immediately. More...
 
Refautorelease ()
 Releases the ownership sometime soon automatically. More...
 
unsigned int getReferenceCount () const
 Returns the Ref's current reference count. More...
 
virtual ~Ref ()
 NA NA More...
 

Static Public Member Functions

static VertexBuffercreate (int sizePerVertex, int vertexNumber)
 
static bool isShadowCopyEnabled ()
 
static void enableShadowCopy (bool enabled)
 

Protected Member Functions

 VertexBuffer ()
 
virtual ~VertexBuffer ()
 
bool init (int sizePerVertex, int vertexNumber)
 
void recreateVBO () const
 
- Protected Member Functions inherited from Ref
 Ref ()
 Constructor. More...
 

Protected Attributes

EventListenerCustom_recreateVBOEventListener
 
GLuint _vbo
 
int _sizePerVertex
 
int _vertexNumber
 
std::vector< unsigned char > _shadowCopy
 
- Protected Attributes inherited from Ref
unsigned int _referenceCount
 count of references More...
 

Static Protected Attributes

static bool _enableShadowCopy
 

Constructor & Destructor Documentation

VertexBuffer ( )
protected
virtual ~VertexBuffer ( )
protectedvirtual

Member Function Documentation

static VertexBuffer* create ( int  sizePerVertex,
int  vertexNumber 
)
static
static void enableShadowCopy ( bool  enabled)
inlinestatic
int getSize ( ) const
int getSizePerVertex ( ) const
GLuint getVBO ( ) const
int getVertexNumber ( ) const
bool init ( int  sizePerVertex,
int  vertexNumber 
)
protected
static bool isShadowCopyEnabled ( )
inlinestatic
void recreateVBO ( ) const
protected
bool updateVertices ( const void *  verts,
int  count,
int  begin 
)

Member Data Documentation

bool _enableShadowCopy
staticprotected
EventListenerCustom* _recreateVBOEventListener
protected
std::vector<unsigned char> _shadowCopy
protected
int _sizePerVertex
protected
GLuint _vbo
mutableprotected
int _vertexNumber
protected

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