k3d::matrix4 Class Reference

A 4x4 matrix. More...

#include <algebra.h>

List of all members.

Public Member Functions

 matrix4 ()
 matrix4 (const vector4 &v0, const vector4 &v1, const vector4 &v2, const vector4 &v3)
 matrix4 (const double d)
 matrix4 (euler_angles Angles)
 matrix4 (const matrix4 &m)
 Copy constructor.
matrix4operator= (const matrix4 &m)
 Assignment of an matrix4.
matrix4operator= (const double d[16])
 Assignment of a C/C++ array.
matrix4operator+= (const matrix4 &m)
 Addition.
matrix4operator-= (const matrix4 &m)
 Subtraction.
matrix4operator*= (const double d)
 Multiplication by a constant.
matrix4operator/= (const double d)
 Division by a constant.
vector4operator[] (int i)
 Returns a vector by index.
const vector4operator[] (int i) const
 Returns a vector by index.
void CopyArray (float m[16]) const
 Copies the matrix contents into a C/C++ style array.
void CopyArray (double m[16]) const
 Copies the matrix contents into a C/C++ style array.
 operator double * ()
 Casts the matrix to a C/C++ style array.

Static Public Member Functions

template<typename IteratorT >
static matrix4 row_major (IteratorT Begin, IteratorT End)
 Creates a new matrix4 from values in row-major order.

Public Attributes

vector4 v [4]
 Stores the matrix elements.

Detailed Description

A 4x4 matrix.


Constructor & Destructor Documentation

k3d::matrix4::matrix4 (  )  [inline]
k3d::matrix4::matrix4 ( const vector4 v0,
const vector4 v1,
const vector4 v2,
const vector4 v3 
) [inline]
k3d::matrix4::matrix4 ( const double  d  )  [inline]
k3d::matrix4::matrix4 ( euler_angles  Angles  )  [inline]
k3d::matrix4::matrix4 ( const matrix4 m  )  [inline]

Copy constructor.

References v.


Member Function Documentation

void k3d::matrix4::CopyArray ( double  m[16]  )  const [inline]

Copies the matrix contents into a C/C++ style array.

References make-epydoc-docs::index.

void k3d::matrix4::CopyArray ( float  m[16]  )  const [inline]

Copies the matrix contents into a C/C++ style array.

References make-epydoc-docs::index.

Referenced by k3d::ngui::viewport::control::pick_edge(), k3d::ngui::viewport::control::pick_point(), and k3d::gl::push_matrix().

k3d::matrix4::operator double * (  )  [inline]

Casts the matrix to a C/C++ style array.

matrix4 & k3d::matrix4::operator*= ( const double  d  )  [inline]

Multiplication by a constant.

matrix4 & k3d::matrix4::operator+= ( const matrix4 m  )  [inline]

Addition.

References v.

matrix4 & k3d::matrix4::operator-= ( const matrix4 m  )  [inline]

Subtraction.

References v.

matrix4 & k3d::matrix4::operator/= ( const double  d  )  [inline]

Division by a constant.

References return_val_if_fail.

matrix4 & k3d::matrix4::operator= ( const double  d[16]  )  [inline]

Assignment of a C/C++ array.

matrix4 & k3d::matrix4::operator= ( const matrix4 m  )  [inline]

Assignment of an matrix4.

References v.

const vector4 & k3d::matrix4::operator[] ( int  i  )  const [inline]

Returns a vector by index.

vector4 & k3d::matrix4::operator[] ( int  i  )  [inline]

Returns a vector by index.

template<typename IteratorT >
static matrix4 k3d::matrix4::row_major ( IteratorT  Begin,
IteratorT  End 
) [inline, static]

Creates a new matrix4 from values in row-major order.

References k3d::python::utility::copy(), modifier::result, and v.


Member Data Documentation


The documentation for this class was generated from the following file:

Generated on Mon Mar 21 07:41:40 2011 for K-3D by doxygen 1.6.3