|
|
|
This is a 4-by-4 transform matrix.
More...
#include "lmatrix.h"
List of all members.
Classes |
| class | CRow |
| class | Row |
Public Types |
|
typedef const float * | const_iterator |
|
typedef const float * | iterator |
Public Member Functions |
|
| LMatrix4f (const LMatrix4f &other) |
|
| LMatrix4f (const LMatrix3f &upper3) |
|
| LMatrix4f (const LMatrix3f &upper3, const LVecBase3f &trans) |
|
| LMatrix4f (const EMatrix4 &m) |
|
| LMatrix4f (const UnalignedLMatrix4f &other) |
|
| LMatrix4f (float e00, float e01, float e02, float e03, float e10, float e11, float e12, float e13, float e20, float e21, float e22, float e23, float e30, float e31, float e32, float e33) |
| void | accumulate (const LMatrix4f &other, float weight) |
| | Computes (*this) += other * weight.
|
| size_t | add_hash (size_t hash) const |
| | Adds the vector into the running hash.
|
| size_t | add_hash (size_t hash, float threshold) const |
| | Adds the vector into the running hash.
|
| bool | almost_equal (const LMatrix4f &other, float threshold) const |
| | Returns true if two matrices are memberwise equal within a specified tolerance.
|
| bool | almost_equal (const LMatrix4f &other) const |
| | Returns true if two matrices are memberwise equal within a default tolerance based on the numeric type.
|
| iterator | begin () |
| | Returns an iterator that may be used to traverse the elements of the matrix, STL-style.
|
| const_iterator | begin () const |
| | Returns an iterator that may be used to traverse the elements of the matrix, STL-style.
|
| int | compare_to (const LMatrix4f &other) const |
| | This flavor of compare_to uses a default threshold value based on the numeric type.
|
| int | compare_to (const LMatrix4f &other, float threshold) const |
| | Sorts matrices lexicographically, componentwise.
|
| iterator | end () |
| | Returns an iterator that may be used to traverse the elements of the matrix, STL-style.
|
| const_iterator | end () const |
| | Returns an iterator that may be used to traverse the elements of the matrix, STL-style.
|
| void | fill (float fill_value) |
| | Sets each element of the matrix to the indicated fill_value.
|
| void | generate_hash (ChecksumHashGenerator &hashgen) const |
| | Adds the vector to the indicated hash generator.
|
| void | generate_hash (ChecksumHashGenerator &hashgen, float scale) const |
| | Adds the vector to the indicated hash generator.
|
| float | get_cell (int row, int col) const |
| | Returns a particular element of the matrix.
|
| LVecBase4f | get_col (int col) const |
| | Retrieves the indicated column of the matrix as a 4-component vector.
|
| LVecBase3f | get_col3 (int col) const |
| | Retrieves the indicated column of the matrix as a 3-component vector, ignoring the last row.
|
| const float * | get_data () const |
| | Returns the address of the first of the nine data elements in the matrix.
|
| size_t | get_hash () const |
| | Returns a suitable hash for phash_map.
|
| size_t | get_hash (float threshold) const |
| | Returns a suitable hash for phash_map.
|
| int | get_num_components () const |
| | Returns the number of elements in the matrix, 16.
|
| LVecBase4f | get_row (int row) const |
| | Retrieves the indicated row of the matrix as a 4-component vector.
|
| void | get_row (LVecBase4f &result_vec, int row) const |
| | Stores the indicated row of the matrix as a 4-component vector.
|
| LVecBase3f | get_row3 (int row) const |
| | Retrieves the row column of the matrix as a 3-component vector, ignoring the last column.
|
| void | get_row3 (LVecBase3f &result_vec, int row) const |
| | Stores the row column of the matrix as a 3-component vector, ignoring the last column.
|
| LMatrix3f | get_upper_3 () const |
| | Retrieves the upper 3x3 submatrix.
|
| bool | invert_affine_from (const LMatrix4f &other) |
| | Performs an invert of the indicated matrix, storing the result in this matrix.
|
| bool | invert_from (const LMatrix4f &other) |
| | Computes the inverse of the other matrix, and stores the result in this matrix.
|
| bool | invert_in_place () |
| | Inverts the current matrix.
|
| bool | is_nan () const |
| | Returns true if any component of the matrix is not-a-number, false otherwise.
|
|
typedef | LINMATH_MATRIX (float, 4, 4) EMatrix4 |
|
| MAKE_SEQ (get_rows, size, get_row) |
|
| MAKE_SEQ (get_cols, size, get_col) |
|
| MAKE_SEQ (get_row3s, size, get_row3) |
|
void | multiply (const LMatrix4f &other1, const LMatrix4f &other2) |
|
bool | operator!= (const LMatrix4f &other) const |
|
float & | operator() (int row, int col) |
|
float | operator() (int row, int col) const |
|
LMatrix4f | operator* (float scalar) const |
|
LMatrix4f | operator* (const LMatrix4f &other) const |
|
LMatrix4f & | operator*= (float scalar) |
|
LMatrix4f & | operator*= (const LMatrix4f &other) |
| LMatrix4f & | operator+= (const LMatrix4f &other) |
| | Performs a memberwise addition between two matrices.
|
| LMatrix4f & | operator-= (const LMatrix4f &other) |
| | Performs a memberwise addition between two matrices.
|
|
LMatrix4f | operator/ (float scalar) const |
|
LMatrix4f & | operator/= (float scalar) |
| bool | operator< (const LMatrix4f &other) const |
| | This performs a lexicographical comparison.
|
|
LMatrix4f & | operator= (const UnalignedLMatrix4f &other) |
|
LMatrix4f & | operator= (const LMatrix4f &other) |
|
LMatrix4f & | operator= (float fill_value) |
|
bool | operator== (const LMatrix4f &other) const |
|
CRow | operator[] (int i) const |
|
Row | operator[] (int i) |
|
void | output (ostream &out) const |
| void | read_datagram (DatagramIterator &source) |
| | Reads the matrix from the Datagram using get_stdfloat().
|
| void | read_datagram_fixed (DatagramIterator &scan) |
| | Reads the matrix from the Datagram using get_float32() or get_float64().
|
|
void | set (float e00, float e01, float e02, float e03, float e10, float e11, float e12, float e13, float e20, float e21, float e22, float e23, float e30, float e31, float e32, float e33) |
| void | set_cell (int row, int col, float value) |
| | Changes a particular element of the matrix.
|
| void | set_col (int col, const LVecBase3f &v) |
| | Replaces the indicated column of the matrix with the indicated 3-component vector, ignoring the last row.
|
| void | set_col (int col, const LVecBase4f &v) |
| | Replaces the indicated column of the matrix.
|
| void | set_rotate_mat (float angle, const LVecBase3f &axis, CoordinateSystem cs=CS_default) |
| | Sets mat to a matrix that rotates by the given angle in degrees counterclockwise about the indicated vector.
|
| void | set_rotate_mat_normaxis (float angle, const LVecBase3f &axis, CoordinateSystem cs=CS_default) |
| | Fills mat with a matrix that rotates by the given angle in degrees counterclockwise about the indicated vector.
|
| void | set_row (int row, const LVecBase4f &v) |
| | Replaces the indicated row of the matrix.
|
| void | set_row (int row, const LVecBase3f &v) |
| | Replaces the indicated row of the matrix with the indicated 3-component vector, ignoring the last column.
|
| void | set_scale_mat (const LVecBase3f &scale) |
| | Fills mat with a matrix that applies the indicated scale in each of the three axes.
|
| void | set_scale_shear_mat (const LVecBase3f &scale, const LVecBase3f &shear, CoordinateSystem cs=CS_default) |
| | Fills mat with a matrix that applies the indicated scale and shear.
|
| void | set_shear_mat (const LVecBase3f &shear, CoordinateSystem cs=CS_default) |
| | Fills mat with a matrix that applies the indicated shear in each of the three planes.
|
| void | set_translate_mat (const LVecBase3f &trans) |
| | Fills mat with a matrix that applies the indicated translation.
|
| void | set_upper_3 (const LMatrix3f &upper3) |
| | Sets the upper 3x3 submatrix.
|
|
void | transpose_from (const LMatrix4f &other) |
|
void | transpose_in_place () |
|
void | write (ostream &out, int indent_level=0) const |
| void | write_datagram (Datagram &destination) const |
| | Writes the matrix to the Datagram using add_stdfloat().
|
| void | write_datagram_fixed (Datagram &destination) const |
| | Writes the matrix to the Datagram using add_float32() or add_float64(), depending on the type of floats in the matrix, regardless of the setting of Datagram::set_stdfloat_double().
|
| LVecBase4f | xform (const LVecBase4f &v) const |
| | 4-component vector or point times matrix.
|
| void | xform_in_place (LVecBase4f &v) const |
| | 4-component vector or point times matrix.
|
| LVecBase3f | xform_point (const LVecBase3f &v) const |
| | The matrix transforms a 3-component point (including translation component) and returns the result.
|
| void | xform_point_in_place (LVecBase3f &v) const |
| | The matrix transforms a 3-component point (including translation component).
|
| LVecBase3f | xform_vec (const LVecBase3f &v) const |
| | The matrix transforms a 3-component vector (without translation component) and returns the result.
|
| LVecBase3f | xform_vec_general (const LVecBase3f &v) const |
| | The matrix transforms a 3-component vector (without translation component) and returns the result, as a fully general operation.
|
| void | xform_vec_general_in_place (LVecBase3f &v) const |
| | The matrix transforms a 3-component vector (without translation component), as a fully general operation.
|
| void | xform_vec_in_place (LVecBase3f &v) const |
| | The matrix transforms a 3-component vector (without translation component).
|
Static Public Member Functions |
| static const LMatrix4f & | convert_mat (CoordinateSystem from, CoordinateSystem to) |
| | Returns a matrix that transforms from the indicated coordinate system to the indicated coordinate system.
|
|
static TypeHandle | get_class_type () |
| static const LMatrix4f & | ident_mat () |
| | Returns an identity matrix.
|
|
static void | init_type () |
| static const LMatrix4f & | ones_mat () |
| | Returns an matrix filled with ones.
|
| static LMatrix4f | rotate_mat (float angle, const LVecBase3f &axis, CoordinateSystem cs=CS_default) |
| | Returns a matrix that rotates by the given angle in degrees counterclockwise about the indicated vector.
|
| static LMatrix4f | rotate_mat_normaxis (float angle, const LVecBase3f &axis, CoordinateSystem cs=CS_default) |
| | Returns a matrix that rotates by the given angle in degrees counterclockwise about the indicated vector.
|
| static LMatrix4f | scale_mat (const LVecBase3f &scale) |
| | Returns a matrix that applies the indicated scale in each of the three axes.
|
| static LMatrix4f | scale_mat (float sx, float sy, float sz) |
| | Returns a matrix that applies the indicated scale in each of the three axes.
|
| static LMatrix4f | scale_mat (float scale) |
| | Returns a matrix that applies the indicated uniform scale.
|
| static LMatrix4f | scale_shear_mat (const LVecBase3f &scale, const LVecBase3f &shear, CoordinateSystem cs=CS_default) |
| | Returns a matrix that applies the indicated scale and shear.
|
| static LMatrix4f | scale_shear_mat (float sx, float sy, float sz, float shxy, float shxz, float shyz, CoordinateSystem cs=CS_default) |
| | Returns a matrix that applies the indicated scale and shear.
|
| static LMatrix4f | shear_mat (float shxy, float shxz, float shyz, CoordinateSystem cs=CS_default) |
| | Returns a matrix that applies the indicated shear in each of the three planes.
|
| static LMatrix4f | shear_mat (const LVecBase3f &shear, CoordinateSystem cs=CS_default) |
| | Returns a matrix that applies the indicated shear in each of the three planes.
|
| static int | size () |
| | Returns 4: the number of rows of a LMatrix4.
|
| static LMatrix4f | translate_mat (float tx, float ty, float tz) |
| | Returns a matrix that applies the indicated translation.
|
| static LMatrix4f | translate_mat (const LVecBase3f &trans) |
| | Returns a matrix that applies the indicated translation.
|
| static const LMatrix4f & | y_to_z_up_mat () |
| | Returns a matrix that transforms from the Y-up coordinate system to the Z-up coordinate system.
|
| static const LMatrix4f & | z_to_y_up_mat () |
| | Returns a matrix that transforms from the Y-up coordinate system to the Z-up coordinate system.
|
| static const LMatrix4f & | zeros_mat () |
| | Returns an matrix filled with zeros.
|
Public Attributes |
|
EMatrix4 | _m |
Detailed Description
This is a 4-by-4 transform matrix.
Definition at line 437 of file lmatrix.h.
Member Function Documentation
| void LMatrix4f::accumulate |
( |
const LMatrix4f & |
other, |
|
|
float |
weight |
|
) |
| [inline] |
| size_t LMatrix4f::add_hash |
( |
size_t |
hash | ) |
const [inline] |
Adds the vector into the running hash.
Definition at line 1553 of file lmatrix.h.
| size_t LMatrix4f::add_hash |
( |
size_t |
hash, |
|
|
float |
threshold |
|
) |
| const [inline] |
Adds the vector into the running hash.
Definition at line 1563 of file lmatrix.h.
| bool LMatrix4f::almost_equal |
( |
const LMatrix4f & |
other, |
|
|
float |
threshold |
|
) |
| const |
| bool LMatrix4f::almost_equal |
( |
const LMatrix4f & |
other | ) |
const [inline] |
Returns true if two matrices are memberwise equal within a default tolerance based on the numeric type.
Definition at line 2471 of file lmatrix.h.
| LMatrix4f::const_iterator LMatrix4f::begin |
( |
| ) |
const [inline] |
Returns an iterator that may be used to traverse the elements of the matrix, STL-style.
Definition at line 1467 of file lmatrix.h.
| LMatrix4f::iterator LMatrix4f::begin |
( |
| ) |
[inline] |
Returns an iterator that may be used to traverse the elements of the matrix, STL-style.
Definition at line 1445 of file lmatrix.h.
| int LMatrix4f::compare_to |
( |
const LMatrix4f & |
other | ) |
const [inline] |
| int LMatrix4f::compare_to |
( |
const LMatrix4f & |
other, |
|
|
float |
threshold |
|
) |
| const |
Sorts matrices lexicographically, componentwise.
Returns a number less than 0 if this matrix sorts before the other one, greater than zero if it sorts after, 0 if they are equivalent (within the indicated tolerance).
Definition at line 717 of file lmatrix.cxx.
| const LMatrix4f & LMatrix4f::convert_mat |
( |
CoordinateSystem |
from, |
|
|
CoordinateSystem |
to |
|
) |
| [static] |
| LMatrix4f::const_iterator LMatrix4f::end |
( |
| ) |
const [inline] |
Returns an iterator that may be used to traverse the elements of the matrix, STL-style.
Definition at line 1478 of file lmatrix.h.
| LMatrix4f::iterator LMatrix4f::end |
( |
| ) |
[inline] |
Returns an iterator that may be used to traverse the elements of the matrix, STL-style.
Definition at line 1456 of file lmatrix.h.
| void LMatrix4f::fill |
( |
float |
fill_value | ) |
[inline] |
Sets each element of the matrix to the indicated fill_value.
This is of questionable value, but is sometimes useful when initializing to zero.
Definition at line 1061 of file lmatrix.h.
Adds the vector to the indicated hash generator.
Definition at line 2481 of file lmatrix.h.
Adds the vector to the indicated hash generator.
Definition at line 961 of file lmatrix.cxx.
| float LMatrix4f::get_cell |
( |
int |
row, |
|
|
int |
col |
|
) |
| const [inline] |
Returns a particular element of the matrix.
Definition at line 1400 of file lmatrix.h.
| LVecBase4f LMatrix4f::get_col |
( |
int |
col | ) |
const [inline] |
| LVecBase3f LMatrix4f::get_col3 |
( |
int |
col | ) |
const [inline] |
Retrieves the indicated column of the matrix as a 3-component vector, ignoring the last row.
Definition at line 1314 of file lmatrix.h.
| const float * LMatrix4f::get_data |
( |
| ) |
const [inline] |
| size_t LMatrix4f::get_hash |
( |
| ) |
const [inline] |
Returns a suitable hash for phash_map.
Definition at line 1533 of file lmatrix.h.
| size_t LMatrix4f::get_hash |
( |
float |
threshold | ) |
const [inline] |
Returns a suitable hash for phash_map.
Definition at line 1543 of file lmatrix.h.
| int LMatrix4f::get_num_components |
( |
| ) |
const [inline] |
Returns the number of elements in the matrix, 16.
Definition at line 1434 of file lmatrix.h.
| void LMatrix4f::get_row |
( |
LVecBase4f & |
result_vec, |
|
|
int |
row |
|
) |
| const [inline] |
Stores the indicated row of the matrix as a 4-component vector.
Definition at line 1244 of file lmatrix.h.
| LVecBase4f LMatrix4f::get_row |
( |
int |
row | ) |
const [inline] |
| void LMatrix4f::get_row3 |
( |
LVecBase3f & |
result_vec, |
|
|
int |
row |
|
) |
| const [inline] |
Stores the row column of the matrix as a 3-component vector, ignoring the last column.
Definition at line 1297 of file lmatrix.h.
| LVecBase3f LMatrix4f::get_row3 |
( |
int |
row | ) |
const [inline] |
Retrieves the row column of the matrix as a 3-component vector, ignoring the last column.
Definition at line 1280 of file lmatrix.h.
Referenced by NodePath::do_billboard_axis(), NodePath::do_billboard_point_eye(), NodePath::do_billboard_point_world(), GraphicsStateGuardian::fetch_specified_value(), Lens::get_nodal_point(), Trackball::get_origin(), PhysxManager::mat4_to_nxMat34(), Lens::set_frustum_from_corners(), PGFrameStyle::xform(), and LODNode::xform().
| LMatrix3f LMatrix4f::get_upper_3 |
( |
| ) |
const [inline] |
| const LMatrix4f & LMatrix4f::ident_mat |
( |
| ) |
[inline, static] |
Returns an identity matrix.
This function definition must appear first, since some inline functions below take advantage of it.
Definition at line 871 of file lmatrix.h.
Referenced by GeomTransformer::apply_texture_colors(), Geom::calc_tight_bounds(), RopeNode::clear_matrix(), Lens::clear_view_mat(), Lens::do_compute_lens_mat(), PerspectiveLens::do_compute_projection_mat(), OrthographicLens::do_compute_projection_mat(), Lens::do_compute_projection_mat(), GraphicsStateGuardian::fetch_specified_part(), GraphicsStateGuardian::fetch_specified_value(), NurbsBasisVector::get_basis(), PhysicsObject::get_inertial_tensor(), TransformState::get_mat(), NodePath::get_mat(), Trackball::reset(), Lens::set_frustum_from_corners(), TextNode::TextNode(), CollisionNode::xform(), and PartBundleNode::xform().
| bool LMatrix4f::invert_affine_from |
( |
const LMatrix4f & |
other | ) |
[inline] |
Performs an invert of the indicated matrix, storing the result in this matrix.
The calculation is only correct of the other matrix represents an affine transform.
The other matrix must be a different object than this matrix. However, if you need to invert a matrix in place, see invert_in_place.
The return value is true if the matrix was successfully inverted, false if there was a singularity.
Definition at line 2141 of file lmatrix.h.
Referenced by Lens::set_frustum_from_corners().
| bool LMatrix4f::invert_from |
( |
const LMatrix4f & |
other | ) |
[inline] |
| bool LMatrix4f::invert_in_place |
( |
| ) |
[inline] |
| bool LMatrix4f::is_nan |
( |
| ) |
const [inline] |
| const LMatrix4f & LMatrix4f::ones_mat |
( |
| ) |
[inline, static] |
Performs a memberwise addition between two matrices.
Definition at line 1862 of file lmatrix.h.
Performs a memberwise addition between two matrices.
Definition at line 1898 of file lmatrix.h.
| bool LMatrix4f::operator< |
( |
const LMatrix4f & |
other | ) |
const [inline] |
This performs a lexicographical comparison.
It's of questionable mathematical meaning, but sometimes has a practical purpose for sorting unique vectors, especially in an STL container. Also see compare_to().
Definition at line 1492 of file lmatrix.h.
| LMatrix4f LMatrix4f::rotate_mat |
( |
float |
angle, |
|
|
const LVecBase3f & |
axis, |
|
|
CoordinateSystem |
cs = CS_default |
|
) |
| [inline, static] |
| LMatrix4f LMatrix4f::rotate_mat_normaxis |
( |
float |
angle, |
|
|
const LVecBase3f & |
axis, |
|
|
CoordinateSystem |
cs = CS_default |
|
) |
| [inline, static] |
Returns a matrix that rotates by the given angle in degrees counterclockwise about the indicated vector.
Assumes axis has been prenormalized.
Definition at line 2332 of file lmatrix.h.
| LMatrix4f LMatrix4f::scale_mat |
( |
float |
sx, |
|
|
float |
sy, |
|
|
float |
sz |
|
) |
| [inline, static] |
Returns a matrix that applies the indicated scale in each of the three axes.
Definition at line 2363 of file lmatrix.h.
| LMatrix4f LMatrix4f::scale_mat |
( |
float |
scale | ) |
[inline, static] |
Returns a matrix that applies the indicated uniform scale.
Definition at line 2377 of file lmatrix.h.
| LMatrix4f LMatrix4f::scale_shear_mat |
( |
float |
sx, |
|
|
float |
sy, |
|
|
float |
sz, |
|
|
float |
shxy, |
|
|
float |
shxz, |
|
|
float |
shyz, |
|
|
CoordinateSystem |
cs = CS_default |
|
) |
| [inline, static] |
Returns a matrix that applies the indicated scale and shear.
Definition at line 2433 of file lmatrix.h.
| void LMatrix4f::set_cell |
( |
int |
row, |
|
|
int |
col, |
|
|
float |
value |
|
) |
| [inline] |
Changes a particular element of the matrix.
Definition at line 1411 of file lmatrix.h.
| void LMatrix4f::set_col |
( |
int |
col, |
|
|
const LVecBase4f & |
v |
|
) |
| [inline] |
| void LMatrix4f::set_col |
( |
int |
col, |
|
|
const LVecBase3f & |
v |
|
) |
| [inline] |
Replaces the indicated column of the matrix with the indicated 3-component vector, ignoring the last row.
Definition at line 1209 of file lmatrix.h.
| void LMatrix4f::set_rotate_mat |
( |
float |
angle, |
|
|
const LVecBase3f & |
axis, |
|
|
CoordinateSystem |
cs = CS_default |
|
) |
| |
Sets mat to a matrix that rotates by the given angle in degrees counterclockwise about the indicated vector.
Definition at line 739 of file lmatrix.cxx.
| void LMatrix4f::set_rotate_mat_normaxis |
( |
float |
angle, |
|
|
const LVecBase3f & |
axis, |
|
|
CoordinateSystem |
cs = CS_default |
|
) |
| |
Fills mat with a matrix that rotates by the given angle in degrees counterclockwise about the indicated vector.
Assumes axis has been prenormalized.
Definition at line 810 of file lmatrix.cxx.
| void LMatrix4f::set_row |
( |
int |
row, |
|
|
const LVecBase4f & |
v |
|
) |
| [inline] |
| void LMatrix4f::set_row |
( |
int |
row, |
|
|
const LVecBase3f & |
v |
|
) |
| [inline] |
Replaces the indicated row of the matrix with the indicated 3-component vector, ignoring the last column.
Definition at line 1191 of file lmatrix.h.
| void LMatrix4f::set_scale_mat |
( |
const LVecBase3f & |
scale | ) |
[inline] |
Fills mat with a matrix that applies the indicated scale in each of the three axes.
Definition at line 2239 of file lmatrix.h.
| void LMatrix4f::set_scale_shear_mat |
( |
const LVecBase3f & |
scale, |
|
|
const LVecBase3f & |
shear, |
|
|
CoordinateSystem |
cs = CS_default |
|
) |
| [inline] |
Fills mat with a matrix that applies the indicated scale and shear.
Definition at line 2265 of file lmatrix.h.
| void LMatrix4f::set_shear_mat |
( |
const LVecBase3f & |
shear, |
|
|
CoordinateSystem |
cs = CS_default |
|
) |
| [inline] |
Fills mat with a matrix that applies the indicated shear in each of the three planes.
Definition at line 2253 of file lmatrix.h.
| void LMatrix4f::set_translate_mat |
( |
const LVecBase3f & |
trans | ) |
[inline] |
Fills mat with a matrix that applies the indicated translation.
Definition at line 2225 of file lmatrix.h.
| void LMatrix4f::set_upper_3 |
( |
const LMatrix3f & |
upper3 | ) |
[inline] |
Sets the upper 3x3 submatrix.
Definition at line 1112 of file lmatrix.h.
| LMatrix4f LMatrix4f::shear_mat |
( |
const LVecBase3f & |
shear, |
|
|
CoordinateSystem |
cs = CS_default |
|
) |
| [inline, static] |
Returns a matrix that applies the indicated shear in each of the three planes.
Definition at line 2391 of file lmatrix.h.
| LMatrix4f LMatrix4f::shear_mat |
( |
float |
shxy, |
|
|
float |
shxz, |
|
|
float |
shyz, |
|
|
CoordinateSystem |
cs = CS_default |
|
) |
| [inline, static] |
Returns a matrix that applies the indicated shear in each of the three planes.
Definition at line 2404 of file lmatrix.h.
| int LMatrix4f::size |
( |
| ) |
[inline, static] |
Returns 4: the number of rows of a LMatrix4.
Definition at line 1374 of file lmatrix.h.
| LMatrix4f LMatrix4f::translate_mat |
( |
float |
tx, |
|
|
float |
ty, |
|
|
float |
tz |
|
) |
| [inline, static] |
Returns a matrix that applies the indicated translation.
Definition at line 2303 of file lmatrix.h.
| void LMatrix4f::write_datagram |
( |
Datagram & |
destination | ) |
const |
| void LMatrix4f::write_datagram_fixed |
( |
Datagram & |
destination | ) |
const |
Writes the matrix to the Datagram using add_float32() or add_float64(), depending on the type of floats in the matrix, regardless of the setting of Datagram::set_stdfloat_double().
This is appropriate when you want to write a fixed-width value to the datagram, especially when you are not writing a bam file.
Definition at line 1096 of file lmatrix.cxx.
| void LMatrix4f::xform_in_place |
( |
LVecBase4f & |
v | ) |
const [inline] |
4-component vector or point times matrix.
This is a fully general operation.
Definition at line 1692 of file lmatrix.h.
| void LMatrix4f::xform_point_in_place |
( |
LVecBase3f & |
v | ) |
const [inline] |
The matrix transforms a 3-component point (including translation component).
This assumes the matrix is an affine transform.
Definition at line 1710 of file lmatrix.h.
The matrix transforms a 3-component vector (without translation component) and returns the result, as a fully general operation.
Definition at line 1673 of file lmatrix.h.
| void LMatrix4f::xform_vec_general_in_place |
( |
LVecBase3f & |
v | ) |
const [inline] |
The matrix transforms a 3-component vector (without translation component), as a fully general operation.
Definition at line 1747 of file lmatrix.h.
| void LMatrix4f::xform_vec_in_place |
( |
LVecBase3f & |
v | ) |
const [inline] |
The matrix transforms a 3-component vector (without translation component).
This assumes the matrix is an orthonormal transform.
Definition at line 1729 of file lmatrix.h.
| const LMatrix4f & LMatrix4f::y_to_z_up_mat |
( |
| ) |
[inline, static] |
| const LMatrix4f & LMatrix4f::z_to_y_up_mat |
( |
| ) |
[inline, static] |
Returns a matrix that transforms from the Y-up coordinate system to the Z-up coordinate system.
Definition at line 2460 of file lmatrix.h.
| const LMatrix4f & LMatrix4f::zeros_mat |
( |
| ) |
[inline, static] |
The documentation for this class was generated from the following files:
| | |