A class for creating OpenGL Buffer Objects.
More...
#include <BufferObject.h>
List of all members.
Public Member Functions |
| BufferObject () |
| Constructor.
|
| ~BufferObject () |
| Destructor.
|
GLuint | getHandle () const |
| Accessor for the buffer's handle.
|
GLenum | getTarget () const |
| Accessor for the buffer's active target.
|
void | bind (GLenum _target) |
| Binds the buffer to a selected buffer target.
|
void | unbind () |
| Unbinds the buffer from the current target.
|
void | loadData (GLsizeiptr _dataSize, const GLvoid *_data, GLenum _bufferUsage) |
| Loads data into the buffer object.
|
void | updateSubData (GLintptr _dataOffest, GLsizeiptr _dataSize, const GLvoid *_data) |
| Updates a subset of the buffer object's data.
|
void | getParameter (GLenum _value, GLint *_data) |
| Accessor for any OpenGL buffer object parameter.
|
Detailed Description
A class for creating OpenGL Buffer Objects.
- Author:
- Nikolaos Verigakis
- Version:
- 1.0
- Date:
- 26/07/11 Revision History : Initial Version 26/07/11
Member Function Documentation
void BufferObject::bind |
( |
GLenum |
_target | ) |
|
Binds the buffer to a selected buffer target.
- Parameters:
-
[in] | _target | the target to bind the buffer to |
void BufferObject::getParameter |
( |
GLenum |
_value, |
|
|
GLint * |
_data |
|
) |
| |
Accessor for any OpenGL buffer object parameter.
- Parameters:
-
[in] | _value | the symbolic name of a buffer object parameter |
[in] | _data | the data to return the the requested parameter |
void BufferObject::loadData |
( |
GLsizeiptr |
_dataSize, |
|
|
const GLvoid * |
_data, |
|
|
GLenum |
_bufferUsage |
|
) |
| |
Loads data into the buffer object.
- Parameters:
-
[in] | _dataSize | the data size in bytes |
[in] | _data | the data to load |
[in] | _bufferUsage | the expected usage pattern of the data store |
void BufferObject::updateSubData |
( |
GLintptr |
_dataOffest, |
|
|
GLsizeiptr |
_dataSize, |
|
|
const GLvoid * |
_data |
|
) |
| |
Updates a subset of the buffer object's data.
- Parameters:
-
[in] | _dataOffset | the offset into the buffer object's data |
[in] | _dataSize | the pixel data size in bytes |
[in] | _data | the pixel data to load |
The documentation for this class was generated from the following files: