These all operate component-wise.
More...
|
| template<typename genType > |
| genType | glm::pow (genType const &x, genType const &y) |
| | Returns x raised to the y power. More...
|
| |
| template<typename genType > |
| genType | glm::exp (genType const &x) |
| | Returns the natural exponentiation of x, i.e., e^x. More...
|
| |
| template<typename genType > |
| genType | glm::log (genType const &x) |
| | Returns the natural logarithm of x, i.e., returns the value y which satisfies the equation x = e^y. More...
|
| |
| template<typename genType > |
| genType | glm::exp2 (genType const &x) |
| | Returns 2 raised to the x power. More...
|
| |
| template<typename genType > |
| genType | glm::log2 (genType const &x) |
| | Returns the base 2 log of x, i.e., returns the value y, which satisfies the equation x = 2 ^ y. More...
|
| |
| template<typename genType > |
| genType | glm::sqrt (genType const &x) |
| | Returns the positive square root of x. More...
|
| |
| template<typename genType > |
| genType | glm::inversesqrt (genType const &x) |
| | Returns the reciprocal of the positive square root of x. More...
|
| |
These all operate component-wise.
The description is per component.
§ exp()
template<typename genType >
| genType glm::exp |
( |
genType const & |
x | ) |
|
§ exp2()
template<typename genType >
| genType glm::exp2 |
( |
genType const & |
x | ) |
|
§ inversesqrt()
template<typename genType >
| genType glm::inversesqrt |
( |
genType const & |
x | ) |
|
§ log()
template<typename genType >
| genType glm::log |
( |
genType const & |
x | ) |
|
Returns the natural logarithm of x, i.e., returns the value y which satisfies the equation x = e^y.
Results are undefined if x <= 0.
- Parameters
-
| x | log function is defined for input values of x defined in the range (0, inf+) in the limit of the type precision. |
- Template Parameters
-
| genType | Floating-point scalar or vector types. |
- See also
- GLSL log man page
-
GLSL 4.20.8 specification, section 8.2 Exponential Functions
§ log2()
template<typename genType >
| genType glm::log2 |
( |
genType const & |
x | ) |
|
§ pow()
template<typename genType >
| genType glm::pow |
( |
genType const & |
x, |
|
|
genType const & |
y |
|
) |
| |
§ sqrt()
template<typename genType >
| genType glm::sqrt |
( |
genType const & |
x | ) |
|