class SG_EXPORT osg::Matrix


Inheritance:


Public Methods

[more] Matrix()
[more] Matrix( const Matrix& other)
[more]explicit Matrix( float const* const def )
[more] Matrix( float a00, float a01, float a02, float a03, float a10, float a11, float a12, float a13, float a20, float a21, float a22, float a23, float a30, float a31, float a32, float a33)
[more] ~Matrix()
[more]int compare(const Matrix& m) const
[more]bool operator < (const Matrix& m) const
[more]bool operator == (const Matrix& m) const
[more]bool operator != (const Matrix& m) const
[more]inline float& operator()(int row, int col)
[more]inline float operator()(int row, int col) const
[more]inline bool valid() const
[more]inline bool isNaN() const
[more]inline Matrix& operator = (const Matrix& other)
[more]inline void set(const Matrix& other)
[more]inline void set(float const* const ptr)
[more]void set( float a00, float a01, float a02, float a03, float a10, float a11, float a12, float a13, float a20, float a21, float a22, float a23, float a30, float a31, float a32, float a33)
[more]float* ptr() const
[more]void makeIdentity()
[more]void makeScale( const Vec3& )
[more]void makeScale( float, float, float )
[more]void makeTranslate( const Vec3& )
[more]void makeTranslate( float, float, float )
[more]void makeRotate( const Vec3& from, const Vec3& to )
[more]void makeRotate( float angle, const Vec3& axis )
[more]void makeRotate( float angle, float x, float y, float z )
[more]void makeRotate( const Quat& )
[more]void makeRotate( float angle1, const Vec3& axis1, float angle2, const Vec3& axis2, float angle3, const Vec3& axis3)
[more]void makeOrtho(double left, double right, double bottom, double top, double zNear, double zFar)
Set to a orthographic projection.
[more]void getOrtho(double& left, double& right, double& bottom, double& top, double& zNear, double& zFar)
Get the othorgraphic settings of the orthographic projection matrix.
[more]inline void makeOrtho2D(double left, double right, double bottom, double top)
Set to a 2D orthographic projection.
[more]void makeFrustum(double left, double right, double bottom, double top, double zNear, double zFar)
Set to a perspective projection.
[more]void getFrustum(double& left, double& right, double& bottom, double& top, double& zNear, double& zFar)
Get the frustum setting of a perspective projection matrix.
[more]void makePerspective(double fovy, double aspectRatio, double zNear, double zFar)
Set to a symmetrical perspective projection, See gluPerspective for further details.
[more]void makeLookAt(const Vec3& eye, const Vec3& center, const Vec3& up)
Set to the position and orientation modelview matrix, using the same convention as gluLookAt.
[more]void getLookAt(Vec3& eye, Vec3& center, Vec3& up, float lookDistance=1.0f)
Get to the position and orientation of a modelview matrix, using the same convention as gluLookAt.
[more]bool invert( const Matrix& )
[more]inline static Matrix identity( void )
[more]inline static Matrix scale( const Vec3& sv)
[more]inline static Matrix scale( float sx, float sy, float sz)
[more]inline static Matrix translate( const Vec3& dv)
[more]inline static Matrix translate( float x, float y, float z)
[more]inline static Matrix rotate( const Vec3& from, const Vec3& to)
[more]inline static Matrix rotate( float angle, float x, float y, float z)
[more]inline static Matrix rotate( float angle, const Vec3& axis)
[more]inline static Matrix rotate( float angle1, const Vec3& axis1, float angle2, const Vec3& axis2, float angle3, const Vec3& axis3)
[more]inline static Matrix rotate( const Quat& quat)
[more]inline static Matrix inverse( const Matrix& matrix)
[more]inline static Matrix ortho(double left, double right, double bottom, double top, double zNear, double zFar)
Create a orthographic projection.
[more]inline static Matrix ortho2D(double left, double right, double bottom, double top)
Create a 2D orthographic projection.
[more]inline static Matrix frustum(double left, double right, double bottom, double top, double zNear, double zFar)
Create a perspective projection.
[more]inline static Matrix perspective(double fovy, double aspectRatio, double zNear, double zFar)
Create a symmetrical perspective projection, See gluPerspective for further details.
[more]inline static Matrix lookAt(const Vec3& eye, const Vec3& center, const Vec3& up)
Create the position and orientation as per a camera, using the same convention as gluLookAt.
[more]void setTrans( float tx, float ty, float tz )
[more]void setTrans( const Vec3& v )
[more]inline Vec3 getTrans() const
[more]inline Vec3 getScale() const
[more]inline static Vec3 transform3x3(const Vec3& v, const Matrix& m)
apply apply an 3x3 transform of v*M[02,02]
[more]inline static Vec3 transform3x3(const Matrix& m, const Vec3& v)
apply apply an 3x3 transform of M[02,02]*v
[more]void mult( const Matrix&, const Matrix& )
[more]void preMult( const Matrix& )
[more]void postMult( const Matrix& )
[more]inline void operator *= ( const Matrix& other )
[more]inline Matrix operator * ( const Matrix &m ) const
[more]inline Matrix identity(void)
[more]inline Matrix scale(float sx, float sy, float sz)
[more]inline Matrix scale(const Vec3& v )
[more]inline Matrix translate(float tx, float ty, float tz)
[more]inline Matrix translate(const Vec3& v )
[more]inline Matrix rotate( const Quat& q )
[more]inline Matrix rotate(float angle, float x, float y, float z )
[more]inline Matrix rotate(float angle, const Vec3& axis )
[more]inline Matrix rotate( float angle1, const Vec3& axis1, float angle2, const Vec3& axis2, float angle3, const Vec3& axis3)
[more]inline Matrix rotate(const Vec3& from, const Vec3& to )
[more]inline Matrix inverse( const Matrix& matrix)
[more]inline Matrix ortho(double left, double right, double bottom, double top, double zNear, double zFar)
[more]inline Matrix ortho2D(double left, double right, double bottom, double top)
[more]inline Matrix frustum(double left, double right, double bottom, double top, double zNear, double zFar)
[more]inline Matrix perspective(double fovy, double aspectRatio, double zNear, double zFar)
[more]inline Matrix lookAt(const Vec3& eye, const Vec3& center, const Vec3& up)
[more]inline Vec3 postMult( const Vec3& v ) const
[more]inline Vec3 preMult( const Vec3& v ) const
[more]inline Vec4 postMult( const Vec4& v ) const
[more]inline Vec4 preMult( const Vec4& v ) const
[more]inline Vec3 transform3x3(const Vec3& v, const Matrix& m)
[more]inline Vec3 transform3x3(const Matrix& m, const Vec3& v)
[more]inline Vec3 operator* (const Vec3& v) const
[more]inline Vec4 operator* (const Vec4& v) const

Protected Fields

[more]float _mat[4][4]


Documentation

o Matrix()

o Matrix( const Matrix& other)

oexplicit Matrix( float const* const def )

o Matrix( float a00, float a01, float a02, float a03, float a10, float a11, float a12, float a13, float a20, float a21, float a22, float a23, float a30, float a31, float a32, float a33)

o ~Matrix()

oint compare(const Matrix& m) const

obool operator < (const Matrix& m) const

obool operator == (const Matrix& m) const

obool operator != (const Matrix& m) const

oinline float& operator()(int row, int col)

oinline float operator()(int row, int col) const

oinline bool valid() const

oinline bool isNaN() const

oinline Matrix& operator = (const Matrix& other)

oinline void set(const Matrix& other)

oinline void set(float const* const ptr)

ovoid set( float a00, float a01, float a02, float a03, float a10, float a11, float a12, float a13, float a20, float a21, float a22, float a23, float a30, float a31, float a32, float a33)

ofloat* ptr() const

ovoid makeIdentity()

ovoid makeScale( const Vec3& )

ovoid makeScale( float, float, float )

ovoid makeTranslate( const Vec3& )

ovoid makeTranslate( float, float, float )

ovoid makeRotate( const Vec3& from, const Vec3& to )

ovoid makeRotate( float angle, const Vec3& axis )

ovoid makeRotate( float angle, float x, float y, float z )

ovoid makeRotate( const Quat& )

ovoid makeRotate( float angle1, const Vec3& axis1, float angle2, const Vec3& axis2, float angle3, const Vec3& axis3)

ovoid makeOrtho(double left, double right, double bottom, double top, double zNear, double zFar)
Set to a orthographic projection. See glOrtho for further details.

ovoid getOrtho(double& left, double& right, double& bottom, double& top, double& zNear, double& zFar)
Get the othorgraphic settings of the orthographic projection matrix. Note, if matrix is not an orthographic matrix then invalid values will be returned.

oinline void makeOrtho2D(double left, double right, double bottom, double top)
Set to a 2D orthographic projection. See glOrtho2D for further details.

ovoid makeFrustum(double left, double right, double bottom, double top, double zNear, double zFar)
Set to a perspective projection. See glFrustum for further details.

ovoid getFrustum(double& left, double& right, double& bottom, double& top, double& zNear, double& zFar)
Get the frustum setting of a perspective projection matrix. Note, if matrix is not an perspective matrix then invalid values will be returned.

ovoid makePerspective(double fovy, double aspectRatio, double zNear, double zFar)
Set to a symmetrical perspective projection, See gluPerspective for further details. Aspect ratio is defined as width/height.

ovoid makeLookAt(const Vec3& eye, const Vec3& center, const Vec3& up)
Set to the position and orientation modelview matrix, using the same convention as gluLookAt.

ovoid getLookAt(Vec3& eye, Vec3& center, Vec3& up, float lookDistance=1.0f)
Get to the position and orientation of a modelview matrix, using the same convention as gluLookAt.

obool invert( const Matrix& )

oinline static Matrix identity( void )

oinline static Matrix scale( const Vec3& sv)

oinline static Matrix scale( float sx, float sy, float sz)

oinline static Matrix translate( const Vec3& dv)

oinline static Matrix translate( float x, float y, float z)

oinline static Matrix rotate( const Vec3& from, const Vec3& to)

oinline static Matrix rotate( float angle, float x, float y, float z)

oinline static Matrix rotate( float angle, const Vec3& axis)

oinline static Matrix rotate( float angle1, const Vec3& axis1, float angle2, const Vec3& axis2, float angle3, const Vec3& axis3)

oinline static Matrix rotate( const Quat& quat)

oinline static Matrix inverse( const Matrix& matrix)

oinline static Matrix ortho(double left, double right, double bottom, double top, double zNear, double zFar)
Create a orthographic projection. See glOrtho for further details.

oinline static Matrix ortho2D(double left, double right, double bottom, double top)
Create a 2D orthographic projection. See glOrtho for further details.

oinline static Matrix frustum(double left, double right, double bottom, double top, double zNear, double zFar)
Create a perspective projection. See glFrustum for further details.

oinline static Matrix perspective(double fovy, double aspectRatio, double zNear, double zFar)
Create a symmetrical perspective projection, See gluPerspective for further details. Aspect ratio is defined as width/height.

oinline static Matrix lookAt(const Vec3& eye, const Vec3& center, const Vec3& up)
Create the position and orientation as per a camera, using the same convention as gluLookAt.

ovoid setTrans( float tx, float ty, float tz )

ovoid setTrans( const Vec3& v )

oinline Vec3 getTrans() const

oinline Vec3 getScale() const

oinline static Vec3 transform3x3(const Vec3& v, const Matrix& m)
apply apply an 3x3 transform of v*M[02,02]

oinline static Vec3 transform3x3(const Matrix& m, const Vec3& v)
apply apply an 3x3 transform of M[02,02]*v

ovoid mult( const Matrix&, const Matrix& )

ovoid preMult( const Matrix& )

ovoid postMult( const Matrix& )

oinline void operator *= ( const Matrix& other )

oinline Matrix operator * ( const Matrix &m ) const

ofloat _mat[4][4]

oinline Matrix identity(void)

oinline Matrix scale(float sx, float sy, float sz)

oinline Matrix scale(const Vec3& v )

oinline Matrix translate(float tx, float ty, float tz)

oinline Matrix translate(const Vec3& v )

oinline Matrix rotate( const Quat& q )

oinline Matrix rotate(float angle, float x, float y, float z )

oinline Matrix rotate(float angle, const Vec3& axis )

oinline Matrix rotate( float angle1, const Vec3& axis1, float angle2, const Vec3& axis2, float angle3, const Vec3& axis3)

oinline Matrix rotate(const Vec3& from, const Vec3& to )

oinline Matrix inverse( const Matrix& matrix)

oinline Matrix ortho(double left, double right, double bottom, double top, double zNear, double zFar)

oinline Matrix ortho2D(double left, double right, double bottom, double top)

oinline Matrix frustum(double left, double right, double bottom, double top, double zNear, double zFar)

oinline Matrix perspective(double fovy, double aspectRatio, double zNear, double zFar)

oinline Matrix lookAt(const Vec3& eye, const Vec3& center, const Vec3& up)

oinline Vec3 postMult( const Vec3& v ) const

oinline Vec3 preMult( const Vec3& v ) const

oinline Vec4 postMult( const Vec4& v ) const

oinline Vec4 preMult( const Vec4& v ) const

oinline Vec3 transform3x3(const Vec3& v, const Matrix& m)

oinline Vec3 transform3x3(const Matrix& m, const Vec3& v)

oinline Vec3 operator* (const Vec3& v) const

oinline Vec4 operator* (const Vec4& v) const


Direct child classes:
RefMatrix

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.