mirror of
https://github.com/recp/cglm.git
synced 2025-12-26 02:25:02 +00:00
mat4: helper for row * matrix * column
This commit is contained in:
@@ -45,6 +45,7 @@ Functions:
|
||||
#. :c:func:`glm_mat4_inv_fast`
|
||||
#. :c:func:`glm_mat4_swap_col`
|
||||
#. :c:func:`glm_mat4_swap_row`
|
||||
#. :c:func:`glm_mat4_rmc`
|
||||
|
||||
Functions documentation
|
||||
~~~~~~~~~~~~~~~~~~~~~~~
|
||||
@@ -270,3 +271,20 @@ Functions documentation
|
||||
| *[in, out]* **mat** matrix
|
||||
| *[in]* **row1** row1
|
||||
| *[in]* **row2** row2
|
||||
|
||||
.. c:function:: float glm_mat4_rmc(vec4 r, mat4 m, vec4 c)
|
||||
|
||||
| **rmc** stands for **Row** * **Matrix** * **Column**
|
||||
|
||||
| helper for R (row vector) * M (matrix) * C (column vector)
|
||||
|
||||
| the result is scalar because S * M = Matrix1x4 (row vector),
|
||||
| then Matrix1x4 * Vec4 (column vector) = Matrix1x1 (Scalar)
|
||||
|
||||
Parameters:
|
||||
| *[in]* **r** row vector or matrix1x4
|
||||
| *[in]* **m** matrix4x4
|
||||
| *[in]* **c** column vector or matrix4x1
|
||||
|
||||
Returns:
|
||||
scalar value e.g. Matrix1x1
|
||||
|
||||
@@ -58,11 +58,7 @@ Functions:
|
||||
#. :c:func:`glm_vec4_minv`
|
||||
#. :c:func:`glm_vec4_clamp`
|
||||
#. :c:func:`glm_vec4_lerp`
|
||||
#. :c:func:`glm_vec4_isnan`
|
||||
#. :c:func:`glm_vec4_isinf`
|
||||
#. :c:func:`glm_vec4_isvalid`
|
||||
#. :c:func:`glm_vec4_sign`
|
||||
#. :c:func:`glm_vec4_sqrt`
|
||||
#. :c:func:`glm_vec4_cubic`
|
||||
|
||||
Functions documentation
|
||||
~~~~~~~~~~~~~~~~~~~~~~~
|
||||
@@ -401,3 +397,11 @@ Functions documentation
|
||||
| *[in]* **to** to value
|
||||
| *[in]* **t** interpolant (amount) clamped between 0 and 1
|
||||
| *[out]* **dest** destination
|
||||
|
||||
.. c:function:: void glm_vec4_cubic(float s, vec4 dest)
|
||||
|
||||
helper to fill vec4 as [S^3, S^2, S, 1]
|
||||
|
||||
Parameters:
|
||||
| *[in]* **s** parameter
|
||||
| *[out]* **dest** destination
|
||||
|
||||
Reference in New Issue
Block a user