41 #include <ACG/GL/acg_glew.hh> 42 #include "StatusNodesT.hh" 54 StatusNodesBase::StatusNodesBase() : heVBO_(0),
63 void StatusNodesBase::createHEVBO()
67 glGenBuffers(1, &heVBO_);
72 void StatusNodesBase::createIBO(GLuint& _name)
76 glGenBuffers(1, &_name);
80 StatusNodesBase::~StatusNodesBase()
83 glDeleteBuffers(1,&heVBO_);
85 glDeleteBuffers(1,&eIBO_);
87 glDeleteBuffers(1,&fIBO_);
89 glDeleteBuffers(1,&vIBO_);
91 glDeleteBuffers(1,&pIBO_);
94 void StatusNodesBase::bindHEVBO()
96 glGetIntegerv(GL_ARRAY_BUFFER_BINDING,&prevBuffer);
99 glBindBuffer(GL_ARRAY_BUFFER, heVBO_);
102 void StatusNodesBase::bindIBO(GLuint& _name)
104 glGetIntegerv(GL_ELEMENT_ARRAY_BUFFER_BINDING,&prevBuffer);
107 glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, _name);
110 void StatusNodesBase::unbindHEVBO()
112 glBindBuffer(GL_ARRAY_BUFFER, prevBuffer);
115 void StatusNodesBase::unbindIBO()
117 glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, prevBuffer);
120 void StatusNodesBase::updateHEVBOPoints(
size_t numberOfElements_,
size_t sizeOfElements_,
void* data_)
123 glBufferData(GL_ARRAY_BUFFER,numberOfElements_ * sizeOfElements_, data_, GL_STATIC_DRAW);
127 void StatusNodesBase::updateIBOData(GLuint& bufferName_,
size_t numberOfElements_,
size_t sizeOfElements_,
void* data_)
129 bindIBO(bufferName_);
130 glBufferData(GL_ELEMENT_ARRAY_BUFFER,numberOfElements_ * sizeOfElements_, data_, GL_STATIC_DRAW);
Namespace providing different geometric functions concerning angles.