36 void setData(
const std::vector<GLfloat>& data,
size_t valuesPerElement,GLenum usage=GL_STATIC_DRAW);
43 void setData(
const std::vector<GLuint>& data);
52 void setData(
const float data[],
size_t elemCount,
53 size_t valuesPerElement,GLenum usage=GL_STATIC_DRAW);
60 void setData(
const GLuint data[],
size_t elemCount);
75 size_t offset=0, GLuint divisor = 0)
const;
void setData(const std::vector< GLfloat > &data, size_t valuesPerElement, GLenum usage=GL_STATIC_DRAW)
Upload interleaved float data and define element stride.
void connectVertexAttrib(GLuint location, size_t elemCount, size_t offset=0, GLuint divisor=0) const
Describe a vertex attribute array for the current buffer contents.
Definition GLBuffer.cpp:57
void bind() const
Bind the buffer to its target with glBindBuffer(target, id).
Definition GLBuffer.cpp:69
~GLBuffer()
Destroy and delete the GL buffer name.
Definition GLBuffer.cpp:17
GLBuffer(GLenum target)
Create a buffer object for the given OpenGL target.
Definition GLBuffer.cpp:7