79 return static_cast<GLvoid *
>(
_data);
83 return static_cast<const GLvoid *
>(
_data);
101 glGenBuffers(1, &
_ibo);
102 glBindBuffer(GL_ELEMENT_ARRAY_BUFFER,
_ibo);
104 glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0);
110 glBindBuffer(GL_ELEMENT_ARRAY_BUFFER,
_ibo);
112 glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0);
118 glDeleteBuffers(1, &
_ibo);
GLvoid * getData()
Access buffer data.
void destroyGL()
Clear (destroy) GL resources associated with the buffer.
GLuint _ibo
"Index" Buffer Object.
void updateGL()
Update existing GL buffer object.
GLuint _hint
GL hint for static or dynamic data.
uint32 _count
Number of elements in buffer.
void initGL(GLuint hint=GL_STATIC_DRAW)
Initialise internal buffer object for GL handling.
GLenum getType() const
Get element type.
uint32 getCount() const
Get element count.
uint32 _size
Size of a buffer element in bytes.
Buffer containing indices data.
void setSize(uint32 indexCount, uint32 indexSize, GLenum indexType)
Change buffer size.
GLenum _type
Element type (GL_UNSIGNED_SHORT, GL_UNSIGNED_INT, ...).
IndexBuffer & operator=(const IndexBuffer &other)