SbMatrix3 Class Reference
[Basics]

3x3 matrix class. More...

#include <Inventor/SbMatrix.h>

List of all members.

Public Member Functions

 SbMatrix3 ()
 SbMatrix3 (float a11, float a12, float a13, float a21, float a22, float a23, float a31, float a32, float a33)
 SbMatrix3 (const SbMat3 &m)
void setValue (const SbMat3 &m)
void setValue (const float *pMat)
void makeIdentity ()
void setRotate (const SbRotation &q)
void setScale (float s)
void setScale (const SbVec3f &s)
void getValue (SbMat3 &m) const
const SbMat3getValue () const
SbMatrix3multRight (const SbMatrix3 &m)
SbMatrix3multLeft (const SbMatrix3 &m)
void multMatrixVec (const SbVec3f &src, SbVec3f &dst) const
void multVecMatrix (const SbVec3f &src, SbVec3f &dst) const
void print (FILE *fp) const
 operator float * ()
 operator SbMat3 & ()
float * operator[] (int i)
const float * operator[] (int i) const
SbVec3f operator* (const SbVec3f &v)
SbMatrix3operator= (const SbMat3 &m)
SbMatrix3operator= (const SbMatrix3 &m)
SbMatrix3operator= (const SbRotation &q)
SbMatrix3operator*= (const SbMatrix3 &m)

Static Public Member Functions

static SbMatrix3 identity ()

Friends

SbVec3f operator* (const SbVec3f &v, const SbMatrix3 &m)
SbMatrix3 operator* (const SbMatrix3 &m1, const SbMatrix3 &m2)
int operator== (const SbMatrix3 &m1, const SbMatrix3 &m2)
int operator!= (const SbMatrix3 &m1, const SbMatrix3 &m2)

Detailed Description

3x3 matrix class.

3x3 matrix class/datatype.

See SbMatrix for discussion of storage layout and usage of matrices.

SEE ALSO

SbMatrix, SbMatrixd, SbRotation, SbRotationd, SbVec2d, SbVec2f, SbVec2i32, SbVec2s, SbVec3d, SbVec3f, SbVec3i32, SbVec3s, SbVec4b, SbVec4d, SbVec4f, SbVec4i32, SbVec4s, SbVec4ub, SbVec4ui32, SbVec4us


Constructor & Destructor Documentation

SbMatrix3::SbMatrix3 (  )  [inline]

Default constructor.

The matrix is initialized with zeros.

SbMatrix3::SbMatrix3 ( float  a11,
float  a12,
float  a13,
float  a21,
float  a22,
float  a23,
float  a31,
float  a32,
float  a33 
)

Constructor.

SbMatrix3::SbMatrix3 ( const SbMat3 m  ) 

Constructor.


Member Function Documentation

const SbMat3& SbMatrix3::getValue (  )  const [inline]

Returns 3x3 array of elements.

void SbMatrix3::getValue ( SbMat3 m  )  const

Returns 3x3 array of elements.

static SbMatrix3 SbMatrix3::identity (  )  [static]

Returns an identity matrix.

void SbMatrix3::makeIdentity (  ) 

Sets matrix to be identity.

SbMatrix3& SbMatrix3::multLeft ( const SbMatrix3 m  ) 

Pre-multiplies matrix by the given matrix.

Matrix is replaced by the result.

void SbMatrix3::multMatrixVec ( const SbVec3f src,
SbVec3f dst 
) const

Post-multiplies matrix by the given column vector, giving a 3D vector result.

It is safe to let src and dst be the same instance of SbVec3f.

SbMatrix3& SbMatrix3::multRight ( const SbMatrix3 m  ) 

Post-multiplies the matrix by the given matrix.

Matrix is replaced by the result.

void SbMatrix3::multVecMatrix ( const SbVec3f src,
SbVec3f dst 
) const

Pre-multiplies matrix by the given row vector, giving a 3D vector result.

It is safe to let src and dst be the same instance of SbVec3f.

SbMatrix3::operator float * (  )  [inline]

Cast: returns pointer to storage of first element.

SbMatrix3::operator SbMat3 & (  )  [inline]

Cast: returns reference to 3x3 array.

SbVec3f SbMatrix3::operator* ( const SbVec3f v  ) 

Multiplies matrices by vector, returning a matrix result.

Return M*v

SbMatrix3& SbMatrix3::operator*= ( const SbMatrix3 m  )  [inline]

Post-multiplies the matrix by the given matrix (equivalent to multRight() method).

Matrix is replaced by the resulting matrix.

SbMatrix3& SbMatrix3::operator= ( const SbRotation q  )  [inline]

Set the matrix from an SbRotation.

SbMatrix3& SbMatrix3::operator= ( const SbMatrix3 m  ) 

Set the matrix from another SbMatrix3.

SbMatrix3& SbMatrix3::operator= ( const SbMat3 m  ) 

Sets value from 3x3 array of elements.

const float* SbMatrix3::operator[] ( int  i  )  const [inline]

Make it look like a usual matrix (so you can do m[2][2]).

float* SbMatrix3::operator[] ( int  i  )  [inline]

Make it look like a usual matrix (so you can do m[2][2]).

void SbMatrix3::print ( FILE *  fp  )  const

Prints a formatted version of the matrix to the given file pointer.

void SbMatrix3::setRotate ( const SbRotation q  ) 

Sets matrix to rotate by given rotation.

void SbMatrix3::setScale ( const SbVec3f s  ) 

Sets matrix to scale by given vector.

void SbMatrix3::setScale ( float  s  ) 

Sets matrix to scale by given uniform factor.

void SbMatrix3::setValue ( const float *  pMat  )  [inline]

Sets value from a 9 value float array.

void SbMatrix3::setValue ( const SbMat3 m  ) 

Sets value from 3x3 array of elements.


Friends And Related Function Documentation

int operator!= ( const SbMatrix3 m1,
const SbMatrix3 m2 
) [friend]

Inequality comparison operator.

SbMatrix3 operator* ( const SbMatrix3 m1,
const SbMatrix3 m2 
) [friend]

Multiplies two matrices, returning a matrix result.

SbVec3f operator* ( const SbVec3f v,
const SbMatrix3 m 
) [friend]

Multiplies matrices by vector, returning a vector result.

Return v*m.

int operator== ( const SbMatrix3 m1,
const SbMatrix3 m2 
) [friend]

Equality comparison operator.


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

Open Inventor Toolkit reference manual, generated on 15 Mar 2023
Copyright © Thermo Fisher Scientific All rights reserved.
http://www.openinventor.com/