0.9.9 API documenation
Functions
Matrix functions

For each of the following built-in matrix functions, there is both a single-qualifier floating point version, where all arguments and return values are single qualifier, and a double-qualifier floating version, where all arguments and return values are double qualifier. More...

Functions

template<typename T , qualifier P, template< typename, qualifier > class matType>
GLM_FUNC_DECL T determinant (matType< T, P > const &m)
 Return the determinant of a squared matrix. More...
 
template<typename T , qualifier P, template< typename, qualifier > class matType>
GLM_FUNC_DECL matType< T, P > inverse (matType< T, P > const &m)
 Return the inverse of a squared matrix. More...
 
template<typename T , qualifier P, template< typename, qualifier > class matType>
GLM_FUNC_DECL matType< T, P > matrixCompMult (matType< T, P > const &x, matType< T, P > const &y)
 Multiply matrix x by matrix y component-wise, i.e., result[i][j] is the scalar product of x[i][j] and y[i][j]. More...
 
template<length_t DA, length_t DB, typename T , qualifier P>
GLM_FUNC_DECL detail::outerProduct_trait< DA, DB, T, P >::type outerProduct (vec< DA, T, P > const &c, vec< DB, T, P > const &r)
 Treats the first parameter c as a column vector and the second parameter r as a row vector and does a linear algebraic matrix multiply c * r. More...
 
template<typename T , qualifier P, template< typename, qualifier > class matType>
GLM_FUNC_DECL matType< T, P >::transpose_type transpose (matType< T, P > const &x)
 Returns the transposed matrix of x. More...
 

Detailed Description

For each of the following built-in matrix functions, there is both a single-qualifier floating point version, where all arguments and return values are single qualifier, and a double-qualifier floating version, where all arguments and return values are double qualifier.

Only the single-qualifier floating point version is shown.

Function Documentation

GLM_FUNC_DECL T glm::determinant ( matType< T, P > const &  m)

Return the determinant of a squared matrix.

Template Parameters
TFloating-point scalar types.
See also
GLSL determinant man page
GLSL 4.20.8 specification, section 8.6 Matrix Functions
GLM_FUNC_DECL matType< T, P > inverse ( matType< T, P > const &  m)

Return the inverse of a squared matrix.

Template Parameters
TFloating-point scalar types.
See also
GLSL inverse man page
GLSL 4.20.8 specification, section 8.6 Matrix Functions
GLM_FUNC_DECL matType<T, P> glm::matrixCompMult ( matType< T, P > const &  x,
matType< T, P > const &  y 
)

Multiply matrix x by matrix y component-wise, i.e., result[i][j] is the scalar product of x[i][j] and y[i][j].

Template Parameters
matTypeFloating-point matrix types.
See also
GLSL matrixCompMult man page
GLSL 4.20.8 specification, section 8.6 Matrix Functions
GLM_FUNC_DECL detail::outerProduct_trait<DA, DB, T, P>::type glm::outerProduct ( vec< DA, T, P > const &  c,
vec< DB, T, P > const &  r 
)

Treats the first parameter c as a column vector and the second parameter r as a row vector and does a linear algebraic matrix multiply c * r.

See also
GLSL outerProduct man page
GLSL 4.20.8 specification, section 8.6 Matrix Functions
GLM_FUNC_DECL matType<T, P>::transpose_type glm::transpose ( matType< T, P > const &  x)

Returns the transposed matrix of x.

Template Parameters
matTypeFloating-point matrix types.
See also
GLSL transpose man page
GLSL 4.20.8 specification, section 8.6 Matrix Functions