| Support Forum Library Source SourceForge Page G3D Web Page |
Namespaces | |
| namespace | G3D |
| namespace | G3D::_internal |
Macros | |
| #define | DECLARE_GLFORMATOF(G3DType, GLType, _isIndex, _isNormalizedFixedPoint) |
| Macro to declare the underlying format (as will be returned by glFormatOf) of a type. | |
| #define | glCanBeIndexType(T) (G3D::_internal::_GLFormat<T>::canBeIndex()) |
| True if the C-type passed as an argument can be used by an OpenGL index buffer as the data type. | |
| #define | glFormatOf(T) (G3D::_internal::_GLFormat<T>::type()) |
| A macro that maps G3D types to OpenGL formats (e.g. | |
| #define | glIsNormalizedFixedPoint(T) (G3D::_internal::_GLFormat<T>::isNormalizedFixedPoint()) |
| True if the C-type passed as an argument is stored in OpenGL normalized fixed point format. | |
Copyright 2002-2012, Morgan McGuire. All rights reserved.
| #define DECLARE_GLFORMATOF | ( | G3DType, | |
| GLType, | |||
| _isIndex, | |||
| _isNormalizedFixedPoint | |||
| ) |
Macro to declare the underlying format (as will be returned by glFormatOf) of a type.
For example,
Use this so you can make vertex arrays of your own classes and not just the standard ones.
| _isIndex | True for types that can be used as indices. |
| #define glCanBeIndexType | ( | T | ) | (G3D::_internal::_GLFormat<T>::canBeIndex()) |
True if the C-type passed as an argument can be used by an OpenGL index buffer as the data type.
e.g., glCanBeIndexType(float) = false.
| #define glFormatOf | ( | T | ) | (G3D::_internal::_GLFormat<T>::type()) |
A macro that maps G3D types to OpenGL formats (e.g.
glFormat(Vector3) == GL_FLOAT).
Use DECLARE_GLFORMATOF(MyType, GLType, bool) at top-level to define glFormatOf values for your own classes.
Used by the vertex array infrastructure.
Referenced by G3D::AttributeArray::AttributeArray(), G3D::AttributeArray::createInterleaved(), G3D::AttributeArray::set(), and G3D::AttributeArray::update().
| #define glIsNormalizedFixedPoint | ( | T | ) | (G3D::_internal::_GLFormat<T>::isNormalizedFixedPoint()) |
True if the C-type passed as an argument is stored in OpenGL normalized fixed point format.
e.g., glIsNormalizedFixedPoint(Vector2unorm16) = true.
Referenced by G3D::AttributeArray::AttributeArray(), G3D::AttributeArray::createInterleaved(), G3D::AttributeArray::set(), and G3D::AttributeArray::update().
1.8.2