|
Unofficial OpenGL Software Development Kit
0.5.0
|
#include <VertexFormat.h>
Describes the storage for a single vertex attribute.
This object is used as part of the construction for a VertexFormat. It allows for "atomic" construction of VertexFormat objects, such that all attributes are added at once during construction.
Public Member Functions | |
| AttribDesc (unsigned int attribIndex, unsigned int numComponents, VertexDataType vertType, AttribDataType attribType) | |
| Creates a valid AttribDesc. More... | |
| unsigned int | GetAttribIndex () const |
| Get the attribute index to be passed to glVertexAttribPointer for this attribute. | |
| unsigned int | GetNumComponents () const |
| Get the number of components in the attribute's data. | |
| VertexDataType | GetVertexDataType () const |
| Get the C/C++ type of the attribute data. | |
| AttribDataType | GetAttribDataType () const |
| Get the interpretation of that attribute's type. | |
| size_t | ByteSize () const |
| Computes the size in bytes of this attribute. | |
| glmesh::AttribDesc::AttribDesc | ( | unsigned int | attribIndex, |
| unsigned int | numComponents, | ||
| VertexDataType | vertType, | ||
| AttribDataType | attribType | ||
| ) |
Creates a valid AttribDesc.
| AttributeDataUnsupportedException | If attribIndex is outside the implementation-defined allowed range of OpenGL attributes. |
| AttributeDataInvalidException | If vertType and attribType do not match, as defined in glmesh::AttribDataType. |
| AttributeDataInvalidException | If numComponents is not on the range [1, 4]. |
| AttributeDataUnsupportedException | If attribType is ADT_DOUBLE and the implementation doesn't support double-precision attributes. |
| AttributeDataUnsupportedException | If attribType is ADT_INTEGER and the implementation doesn't support integral attributes. |
| AttributeDataUnsupportedException | If vertType is VDT_HALF_FLOAT and the implementation doesn't support half-floating point attributes. |
1.8.3.1