The Vertices class represents a vertex buffer, which is a block of memory on the GPU that stores vertex attributes data for rendering. More...
#include <vertices.h>
Public Member Functions | |
| Vertices (std::shared_ptr< ArrayBuffer > buffer, int offset=0, unsigned int stride=0, unsigned int divisor=0) | |
Public Member Functions inherited from cil::Object | |
| Object () | |
| virtual | ~Object () |
Public Attributes | |
| std::shared_ptr< ArrayBuffer > | buffer |
| This member holds a shared pointer to a ArrayBuffer class. It represents an array of 32-bit floating point numbers that represent the actual vertex attributes, like postition, normals, color, etc.. | |
| int | offset |
| This memeber stores an integer value representing an offset(in bytes) from the beginning of the buffer. | |
| unsigned int | stride |
| This member stores an integer value representing the gap(in bytes) between consecutive vertices in the buffer. This value specifies how many bytes to jump to move from the attribute of one vertex to the next vertex in the buffer. | |
| unsigned int | divisor |
| This member stores an integer value used for instanced rendering. In instanced rendering, the same vertex attribute can be reused to draw multiple objects with different transformations. | |
The Vertices class represents a vertex buffer, which is a block of memory on the GPU that stores vertex attributes data for rendering.
| cil::Vertices::Vertices | ( | std::shared_ptr< ArrayBuffer > | buffer, |
| int | offset = 0, | ||
| unsigned int | stride = 0, | ||
| unsigned int | divisor = 0 ) |
| std::shared_ptr<ArrayBuffer> cil::Vertices::buffer |
This member holds a shared pointer to a ArrayBuffer class. It represents an array of 32-bit floating point numbers that represent the actual vertex attributes, like postition, normals, color, etc..
| unsigned int cil::Vertices::divisor |
This member stores an integer value used for instanced rendering. In instanced rendering, the same vertex attribute can be reused to draw multiple objects with different transformations.
| int cil::Vertices::offset |
This memeber stores an integer value representing an offset(in bytes) from the beginning of the buffer.
| unsigned int cil::Vertices::stride |
This member stores an integer value representing the gap(in bytes) between consecutive vertices in the buffer. This value specifies how many bytes to jump to move from the attribute of one vertex to the next vertex in the buffer.