representation d'un buffer d'attribut. More...
#include <TPBuffer.h>
Public Member Functions | |
| GLAttributeBuffer (const unsigned int count, const unsigned int length, const void *data, const GLenum usage=GL_STATIC_DRAW) | |
| constructeur. | |
| ~GLAttributeBuffer () | |
| destructeur. | |
| int | clear () |
| efface le contenu du buffer. | |
| int | update (const unsigned long int offset, const unsigned long int length, const void *data) |
| remplace une partie de contenu du buffer. | |
| void * | map (const unsigned long int offset, const unsigned long int length, const GLbitfield access) |
| mappe une partie du buffer en memoire centrale. | |
| int | unmap () |
| termine le mapping du contenu du buffer en memoire centrale, les donnees modifiees sont transferees sur le gpu. | |
| int | flush (const unsigned long int offset, const unsigned long int length) |
| termine une partie du mapping du contenu du buffer en memoire centrale, les donnees modifiiees sont transferees sur le gpu. | |
| int | bindAsFeedbackAttribute (const ProgramFeedback &attribute) |
| utilise le buffer comme destination du feedback pour le varying 'index' declare dans le shader, cf glTransformFeedbackVaryings(). | |
| int | bindAsIndirect () |
| utilise le buffer comme tableau de draw calls, cf. opengl4 glDrawElementsIndirect(), glDrawArraysIndirect(). | |
| int | bindAsIndex () |
| utilise le contenu du buffer comme tableau d'index pour un affichage avec sommets partages. cf. glDrawElements(). | |
| int | createGLResource () |
| creation de la ressource openGL. | |
| int | releaseGLResource () |
| destruction de la ressource openGL. | |
| GLuint | name () const |
| renvoie le nom openGL (l'identifiant) du buffer. | |
| unsigned int | count () const |
| renvoie le nombre de vecteurs alloues (valeur passee au contructeur, cf GLBuffer()). | |
Static Public Member Functions | |
| static void | unbindIndex () |
| static void | unbindVertexAttribute (const ProgramAttribute &attribute) |
| static void | unbindInstanceAttribute (const ProgramAttribute &attribute) |
| static void | unbindFeedbackAttribute (const ProgramFeedback &attribute) |
| static void | unbindIndirect () |
Protected Member Functions | |
| int | clear (const int state) |
| efface le contenu du buffer. | |
| int | update (const int state, const unsigned long int offset, const unsigned long int length, const void *data) |
| modifie le contenu d'une partie du buffer. | |
| void * | map (const int state, const unsigned long int offset, const unsigned int length, const GLbitfield access) |
| mappe le contenu du buffer en memoire host | |
| int | unmap (const int state) |
| int | flush (const int state, const unsigned long int offset, const unsigned int length) |
Protected Attributes | |
| GLuint | m_name |
| GLenum | m_usage |
| unsigned int | m_length |
| unsigned int | m_count |
representation d'un buffer d'attribut.
| int gk::GLBuffer::update | ( | const int | state, | |
| const unsigned long int | offset, | |||
| const unsigned long int | length, | |||
| const void * | data | |||
| ) | [inline, protected, inherited] |
modifie le contenu d'une partie du buffer.
| offset | position du premier octet a modifier, | |
| length | nombre d'octets a modifier. |
1.6.3