Graphite
Version 3
An experimental 3D geometry processing program
|
A buffer used by GLUP in immediate mode. More...
#include <geogram_gfx/GLUP/GLUP_context.h>
Public Member Functions | |
ImmediateBuffer () | |
~ImmediateBuffer () | |
void | initialize (index_t dim) |
void | enable () |
Enables this ImmediateBuffer. | |
void | disable () |
Disables this ImmediateBuffer. | |
bool | is_enabled () const |
Tests whether this ImmediateBuffer is enabled. More... | |
void | set_current (GLfloat x, GLfloat y, GLfloat z, GLfloat w) |
Sets the current attribute value. More... | |
void | copy_current_to (index_t v) |
Copies the current attribute value to a specified vertex in this buffer. More... | |
void | copy (index_t to, index_t from) |
Copies this attribute from a vertex to another one. More... | |
void | copy (index_t to, ImmediateBuffer &from_buffer, index_t from) |
Copies this attribute from another attribute. More... | |
index_t | dimension () const |
Gets the dimension of the attribute. More... | |
size_t | size_in_bytes () const |
Gets the size of the memory used by the buffer. More... | |
GLfloat * | element_ptr (index_t v) |
Gets a pointer to one attribute value by index. More... | |
GLfloat * | data () |
Gets a pointer to the data. More... | |
GLuint & | VBO () |
Gets the Vertex Buffer Object. More... | |
ImmediateBuffer (const ImmediateBuffer &rhs) | |
ImmediateBuffer copy constructor. More... | |
A buffer used by GLUP in immediate mode.
Definition at line 358 of file GLUP_context.h.
|
inline |
ImmediateBuffer constructor.
Definition at line 365 of file GLUP_context.h.
|
inline |
ImmediateBuffer destructor.
Definition at line 375 of file GLUP_context.h.
|
inline |
ImmediateBuffer copy constructor.
[in] | rhs | the ImmediateBuffer to be copied |
Should be only called with uninitialized ImmediateBuffer (else triggers an assertion failure).
Definition at line 519 of file GLUP_context.h.
|
inline |
Copies this attribute from another attribute.
[in] | to | index of the destination vertex |
[in] | from_buffer | the source buffer |
[in] | from | index of the source vertex |
Definition at line 459 of file GLUP_context.h.
Copies this attribute from a vertex to another one.
[in] | to | index of the destination vertex |
[in] | from | index of the source vertex |
Definition at line 444 of file GLUP_context.h.
|
inline |
Copies the current attribute value to a specified vertex in this buffer.
[in] | v | the vertex index |
Definition at line 431 of file GLUP_context.h.
|
inline |
Gets a pointer to the data.
Definition at line 500 of file GLUP_context.h.
|
inline |
Gets the dimension of the attribute.
Definition at line 472 of file GLUP_context.h.
|
inline |
Gets a pointer to one attribute value by index.
[in] | v | index of the vertex |
dimension()
GLfloats Definition at line 490 of file GLUP_context.h.
|
inline |
Tests whether this ImmediateBuffer is enabled.
true | if this ImmediateBuffer is enabled |
false | otherwise |
Definition at line 408 of file GLUP_context.h.
|
inline |
Sets the current attribute value.
[in] | x,y,z,w | the component of the current attribute |
Components past the dimension of the attribute are ignored (e.g., if dimension is 2, z and w are ignored).
Definition at line 418 of file GLUP_context.h.
|
inline |
Gets the size of the memory used by the buffer.
Definition at line 480 of file GLUP_context.h.
|
inline |
Gets the Vertex Buffer Object.
Definition at line 509 of file GLUP_context.h.