2011-02-07 12:31:35 +00:00
|
|
|
/*!
|
|
|
|
\defgroup gtc GLM Core Extensions
|
2011-02-05 00:52:58 +00:00
|
|
|
|
|
|
|
\brief Functions and types that GLSL does not provide, but are useful to have.
|
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
Core extensions differ from \ref gtx "experimental extensions" in that core extensions
|
|
|
|
are fairly stable. The API for experimental extensions is expected to change
|
|
|
|
significantly between versions.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
|
|
|
You can bring all of the extensions, core or experimental, in by
|
|
|
|
including <glm/ext.hpp> Otherwise, you will have to include each extension
|
|
|
|
by including a specific file.
|
|
|
|
**/
|
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
/*!
|
|
|
|
\defgroup gtc_half_float Half Float Core Extension
|
|
|
|
\ingroup gtc
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
\brief Defines the half-float type, along with various typedefs for vectors and matrices.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
You must include <glm/glc/half_float.hpp> to get this functionality.
|
2011-02-05 00:52:58 +00:00
|
|
|
**/
|
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
/*!
|
|
|
|
\defgroup gtc_matrix_access Matrix Access Core Extension
|
|
|
|
\ingroup gtc
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
\brief Defines functions that allow you to access rows or columns of a matrix easily.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
You must include <glm/glc/matrix_access.hpp> to get this functionality.
|
2011-02-05 00:52:58 +00:00
|
|
|
**/
|
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
/*!
|
|
|
|
\defgroup gtc_matrix_integer Integer Matrix Core Extension
|
|
|
|
\ingroup gtc
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
\brief Defines a number of matrices with integer types.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
You must include <glm/glc/matrix_integer.hpp> to get this functionality.
|
2011-02-05 00:52:58 +00:00
|
|
|
**/
|
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
/*!
|
|
|
|
\defgroup gtc_matrix_inverse Matrix Inverse Core Extension
|
|
|
|
\ingroup gtc
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
\brief Defines additional matrix inverting functions.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
You must include <glm/glc/matrix_inverse.hpp> to get this functionality.
|
2011-02-05 00:52:58 +00:00
|
|
|
**/
|
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
/*!
|
|
|
|
\defgroup gtc_matrix_transform Matrix Transform Core Extension
|
|
|
|
\ingroup gtc
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
\brief Defines functions that generate common transformation matrices.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
The matrices generated by this extension use standard OpenGL fixed-function
|
|
|
|
conventions. For example, the lookAt function generates a transform from world
|
|
|
|
space into the specific eye space that the projective matrix functions (
|
|
|
|
perspective, ortho, etc) are designed to expect. The OpenGL compatibility
|
|
|
|
specifications defines the particular layout of this eye space.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
You must include <glm/glc/matrix_transform.hpp> to get this functionality.
|
2011-02-05 00:52:58 +00:00
|
|
|
**/
|
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
/*!
|
|
|
|
\defgroup gtc_quaternion Quaternion Core Extension
|
|
|
|
\ingroup gtc
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
\brief Defines a templated quaternion type and several quaternion operations.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
You must include <glm/glc/quaternion.hpp> to get this functionality.
|
2011-02-05 00:52:58 +00:00
|
|
|
**/
|
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
/*!
|
|
|
|
\defgroup gtc_type_precision Type Precision Core Extension
|
|
|
|
\ingroup gtc
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
\brief Defines specific C++-based precision types.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
\ref core_precision defines types based on GLSL's precision qualifiers. This
|
|
|
|
extension defines types based on explicitly-sized C++ data types.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
You must include the file <glm/glc/type_precision.hpp> to get this functionality.
|
2011-02-05 00:52:58 +00:00
|
|
|
**/
|
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
/*!
|
|
|
|
\defgroup gtc_type_ptr Pointer Access Core Extension
|
|
|
|
\ingroup gtc
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
\brief Used to get a pointer to the memory layout of a basic type.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
This extension defines an overloaded function, glm::value_ptr, which
|
|
|
|
takes any of the \ref core_template "core template types". It returns
|
|
|
|
a pointer to the memory layout of the object. Matrix types store their values
|
|
|
|
in row-major order.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
This is useful for uploading data to matrices or copying data to buffer objects.
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
Example:
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
\code
|
|
|
|
#include <glm/glm.hpp>
|
|
|
|
#include <glm/glc/type_ptr.hpp>
|
|
|
|
glm::vec3 aVector(3);
|
|
|
|
glm::mat4 someMatrix(1.0);
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
glUniform3fv(uniformLoc, 1, glm::value_ptr(aVector));
|
|
|
|
glUniformMatrix4fv(uniformMatrixLoc, 1, GL_FALSE, glm::value_ptr(someMatrix));
|
|
|
|
\endcode
|
2011-02-05 00:52:58 +00:00
|
|
|
|
2011-02-07 12:31:35 +00:00
|
|
|
You must include the file <glm/glc/type_ptr.hpp> to get this functionality.
|
2011-02-05 00:52:58 +00:00
|
|
|
**/
|
|
|
|
|