![]() |
SH4ZAM! 0.7.0
Fast math library for the Sega Dreamcast's SH4 CPU
|


Public Member Functions | |
| mat4x4 (const mat4x4 &other) noexcept | |
| mat4x4 (const shz_mat4x4_t &other) noexcept | |
| mat4x4 & | operator= (const shz_mat4x4_t &other) noexcept |
Initialization | |
Routines for fully initializing a matrix. | |
| void | init_identity () noexcept |
| void | init_identity_safe () noexcept |
| void | init_zero () noexcept |
| void | init_one () noexcept |
| void | init_fill (float value) noexcept |
| void | init_translation (float x, float y, float z) noexcept |
| void | init_translation (const vec3 &v) noexcept |
| void | init_scale (float x, float y, float z) noexcept |
| void | init_scale (const vec3 &v) noexcept |
| void | init_rotation_x (float angle) noexcept |
| void | init_rotation_y (float angle) noexcept |
| void | init_rotation_z (float angle) noexcept |
| void | init_rotation_xyz (float xAngle, float yAngle, float zAngle) noexcept |
| void | init_rotation_zyx (float zAngle, float yAngle, float xAngle) noexcept |
| void | init_rotation_zxy (float zAngle, float xAngle, float yAngle) noexcept |
| void | init_rotation_yxz (float yAngle, float xAngle, float zAngle) noexcept |
| void | init_rotation (float angle, float x, float y, float z) noexcept |
| void | init_rotation (float angle, const vec3 &axis) noexcept |
| void | init_rotation (const quat &q) noexcept |
| void | init_diagonal (float x, float y, float z, float w) noexcept |
| void | init_diagonal (const vec4 &v) noexcept |
| void | init_upper_triangular (float col1, const vec2 &col2, const vec3 &col3, const vec4 &col4) noexcept |
| void | init_lower_triangular (const vec4 &col1, const vec3 &col2, const vec2 &col3, float col4) noexcept |
| void | init_symmetric_skew (float x, float y, float z) noexcept |
| void | init_symmetric_skew (const vec3 &v) noexcept |
| void | init_outer_product (const vec4 &v1, const vec4 &v2) noexcept |
| void | init_permutation_wxyz () noexcept |
| void | init_permutation_yzwx () noexcept |
| void | init_screen (float width, float height) noexcept |
| void | init_lookat (const vec3 &eye, const vec3 ¢er, const vec3 &up) noexcept |
| void | init_ortho (float left, float right, float bottom, float top, float znear, float zfar) noexcept |
| void | init_frustum (float left, float right, float bottom, float top, float znear, float zfar) noexcept |
| void | init_perspective (float fov, float aspect, float znear) noexcept |
Getting | |
Routines for getting specific values within a matrix | |
| vec4 | row (size_t index) const noexcept |
| vec4 | col (size_t index) const noexcept |
| vec3 | get_translation () const noexcept |
Setting | |
Routines for setting specific values within a matrix | |
| void | set_row (size_t index, vec4 values) noexcept |
| void | set_col (size_t index, vec4 values) noexcept |
| void | swap_rows (size_t row1, size_t row2) noexcept |
| void | swap_cols (size_t col1, size_t col2) noexcept |
| void | set_translation (float x, float y, float z) noexcept |
| void | set_translation (const vec3 &v) noexcept |
| void | set_scale (float x, float y, float z) noexcept |
| void | set_scale (const vec3 &v) noexcept |
| void | set_rotation (const quat &rot) noexcept |
| void | set_diagonal (float x, float y, float z, float w) noexcept |
| void | set_diagonal (const vec4 &v) noexcept |
Applying | |
Routines for multiplying and accumulating onto the given matrix. | |
| void | apply (const shz_mat4x4_t &mat) noexcept |
| void | apply (const float mat[16]) noexcept |
| void | apply_transpose (const shz_mat4x4_t &mat) noexcept |
| void | apply_transpose (const float mat[16]) noexcept |
| void | apply_scale (float x, float y, float z) noexcept |
| void | apply_scale (const vec3 &v) noexcept |
| void | apply_translation (float x, float y, float z) noexcept |
| void | apply_translation (const vec3 &v) noexcept |
| void | apply_rotation_x (float angle) noexcept |
| void | apply_rotation_y (float angle) noexcept |
| void | apply_rotation_z (float angle) noexcept |
| void | apply_rotation_xyz (float xAngle, float yAngle, float zAngle) noexcept |
| void | apply_rotation_zyx (float zAngle, float yAngle, float xAngle) noexcept |
| void | apply_rotation_zxy (float zAngle, float xAngle, float yAngle) noexcept |
| void | apply_rotation_yxz (float yAngle, float xAngle, float zAngle) noexcept |
| void | apply_rotation (float angle, float x, float y, float z) noexcept |
| void | apply_rotation (float angle, vec3 axis) noexcept |
| void | apply_rotation (const quat &q) noexcept |
| void | apply_lookat (vec3 pos, vec3 target, vec3 up) noexcept |
| void | apply_ortho (float left, float right, float bottom, float top, float znear, float zfar) noexcept |
| void | apply_frustum (float left, float right, float bottom, float top, float znear, float zfar) noexcept |
| void | apply_perspective (float fov, float aspect, float znear) noexcept |
| void | apply_screen (float width, float height) noexcept |
| void | apply_symmetric_skew (float x, float y, float z) noexcept |
| void | apply_permutation_wxyz () noexcept |
| void | apply_permutation_yzwx () noexcept |
| void | apply_self () noexcept |
GL Transformations | |
OpenGL-style 4x4 matrix transforms. | |
| void | translate (float x, float y, float z) noexcept |
| void | translate (vec3 v) noexcept |
| void | scale (float x, float y, float z) noexcept |
| void | scale (vec3 v) noexcept |
| void | rotate_x (float radians) noexcept |
| void | rotate_y (float radians) noexcept |
| void | rotate_z (float radians) noexcept |
| void | rotate_xyz (float xRadians, float yRadians, float zRadians) noexcept |
| void | rotate_zyx (float zRadians, float yRadians, float xRadians) noexcept |
| void | rotate_zxy (float zRadians, float xRadians, float yRadians) noexcept |
| void | rotate_yxz (float yRadians, float xRadians, float zRadians) noexcept |
| void | rotate (float radians, float xAxis, float yAxis, float zAxis) noexcept |
| void | rotate (float radians, vec3 axis) noexcept |
Transforming | |
Routines for transforming vectors and points by a matrix. | |
| vec2 | transform (const vec2 &in) const noexcept |
| vec3 | transform (const vec3 &in) const noexcept |
| vec4 | transform (const vec4 &in) const noexcept |
| vec2 | transform_point (const vec2 &pt) const noexcept |
| vec3 | transform_point (const vec3 &pt) const noexcept |
| vec2 | transform_transpose (const vec2 &in) const noexcept |
| vec3 | transform_transpose (const vec3 &in) const noexcept |
| vec4 | transform_transpose (const vec4 &in) const noexcept |
| vec2 | transform_point_transpose (const vec2 &pt) const noexcept |
| vec3 | transform_point_transpose (const vec3 &pt) const noexcept |
Static Public Member Functions | |
Multiplication | |
Routines for multiplying two matrices and storing the result in a third. | |
| static void | mult (shz_mat4x4_t *dst, const shz_mat4x4_t &lhs, const shz_mat4x4_t &rhs) noexcept |
| static void | mult (shz_mat4x4_t *dst, const shz_mat4x4_t &lhs, const float rhs[16]) noexcept |
| static void | mult_transpose (shz_mat4x4_t *dst, const shz_mat4x4_t &lhs, const shz_mat4x4_t &rhs) noexcept |
| static void | mult_transpose (shz_mat4x4_t *dst, const shz_mat4x4_t &lhs, const float rhs[16]) noexcept |
Static Public Attributes | |
| static constexpr size_t | Rows |
| static constexpr size_t | Cols |
Friends | |
| bool | operator== (const mat4x4 &lhs, const mat4x4 &rhs) noexcept |
Miscellaneous | |
Other matrix-related operations and routines | |
| quat | to_quat () const noexcept |
| float | determinant () const noexcept |
| float | trace () const noexcept |
| void | inverse (mat4x4 *out) const noexcept |
| void | inverse_block_triangular (mat4x4 *out) const noexcept |
| void | decompose (vec3 *translation, quat *rotation, vec3 *scale) const noexcept |
| void | swap (shz_mat4x4_t &matA, shz_mat4x4_t &matB) noexcept |
| static void | copy (shz_mat4x4_t *lhs, const shz_mat4x4_t &rhs) noexcept |
| static void | copy (shz_mat4x4_t *lhs, const float rhs[16]) noexcept |
Additional Inherited Members | ||
Data Fields inherited from shz_mat4x4_t | ||
| union { | ||
| float elem [16] | ||
| float elem2D [4][4] | ||
| shz_vec4_t col [4] | ||
| struct { | ||
| shz_vec4_t left | ||
| shz_vec4_t up | ||
| shz_vec4_t forward | ||
| shz_vec4_t pos | ||
| } | ||
| }; | ||
Definition at line 27 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 33 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 37 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 79 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 89 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 93 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 97 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 101 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 105 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 109 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 113 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 117 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 121 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 125 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 129 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 133 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 137 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 141 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 145 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 149 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 153 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 157 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 161 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 165 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 169 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 173 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 177 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 181 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 185 of file shz_matrix.hpp.
Definition at line 189 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 193 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 197 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 201 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 205 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 209 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 213 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 217 of file shz_matrix.hpp.
|
inlinenoexcept |
C++ wrapper for shz_mat4x4_row().
Definition at line 229 of file shz_matrix.hpp.
|
inlinenoexcept |
C++ wrapper for shz_mat4x4_col().
Definition at line 234 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 238 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 249 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 253 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 257 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 261 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 265 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 269 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 273 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 277 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 281 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 285 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 289 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 300 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 304 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 308 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 312 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 316 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 320 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 324 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 328 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 332 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 336 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 340 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 344 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 348 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 352 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 356 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 360 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 364 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 368 of file shz_matrix.hpp.
Definition at line 372 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 376 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 380 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 384 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 388 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 392 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 396 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 400 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 404 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 415 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 419 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 423 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 427 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 431 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 435 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 439 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 443 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 447 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 451 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 455 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 459 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 463 of file shz_matrix.hpp.
|
inlinestaticnoexcept |
Definition at line 474 of file shz_matrix.hpp.
|
inlinestaticnoexcept |
Definition at line 478 of file shz_matrix.hpp.
|
inlinestaticnoexcept |
Definition at line 482 of file shz_matrix.hpp.
|
inlinestaticnoexcept |
Definition at line 486 of file shz_matrix.hpp.
Definition at line 497 of file shz_matrix.hpp.
Definition at line 501 of file shz_matrix.hpp.
Definition at line 505 of file shz_matrix.hpp.
Definition at line 509 of file shz_matrix.hpp.
Definition at line 513 of file shz_matrix.hpp.
Definition at line 517 of file shz_matrix.hpp.
Definition at line 521 of file shz_matrix.hpp.
Definition at line 525 of file shz_matrix.hpp.
Definition at line 529 of file shz_matrix.hpp.
Definition at line 533 of file shz_matrix.hpp.
|
inlinestaticnoexcept |
Definition at line 544 of file shz_matrix.hpp.
|
inlinestaticnoexcept |
Definition at line 548 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 556 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 560 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 564 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 568 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 572 of file shz_matrix.hpp.
|
inlinenoexcept |
Definition at line 576 of file shz_matrix.hpp.
Overloaded equality operator, for comparing vectors.
Definition at line 75 of file shz_matrix.hpp.
|
friend |
Definition at line 552 of file shz_matrix.hpp.
|
staticconstexpr |
Number of rows.
Definition at line 28 of file shz_matrix.hpp.
|
staticconstexpr |
Number of columns.
Definition at line 29 of file shz_matrix.hpp.