HE_Mesh  5.1.0
geomerative.RMatrix Class Reference

Public Member Functions

 RMatrix (String transformationString)
 
void translate (float tx)
 
void rotate (float angle)
 
void scale (float sx, float sy)
 
void scale (float s)
 
void skewY (float angle)
 

Private Member Functions

void set (float m00, float m01, float m02, float m10, float m11, float m12)
 

Related Functions

(Note that these are not member functions.)

 RMatrix (float m00, float m01, float m02, float m10, float m11, float m12)
 
 RMatrix ()
 
 RMatrix (RMatrix src)
 
void apply (float n00, float n01, float n02, float n10, float n11, float n12)
 
void apply (RMatrix rhs)
 
void translate (float tx, float ty)
 
void translate (RPoint t)
 
void rotate (float angle, float vx, float vy)
 
void rotate (float angle, RPoint v)
 
void scale (float sx, float sy, float x, float y)
 
void scale (float s, float x, float y)
 
void scale (float sx, float sy, RPoint p)
 
void scale (float s, RPoint p)
 
void skewX (float angle)
 
void shear (float shx, float shy)
 

Detailed Description

RMatrix is a very simple interface for creating, holding 3x3 matrices with the most common 2D affine transformations such as translation, rotation, scaling and shearing. We only have access to the first to rows of the matrix the last row is considered a constant 0, 0, 1 in order to have better performance. RMatrix Geometry

Constructor & Destructor Documentation

geomerative.RMatrix.RMatrix ( String  transformationString)

Member Function Documentation

void geomerative.RMatrix.rotate ( float  angle)
void geomerative.RMatrix.scale ( float  sx,
float  sy 
)
void geomerative.RMatrix.scale ( float  s)
void geomerative.RMatrix.set ( float  m00,
float  m01,
float  m02,
float  m10,
float  m11,
float  m12 
)
private
void geomerative.RMatrix.skewY ( float  angle)
void geomerative.RMatrix.translate ( float  tx)

Friends And Related Function Documentation

void apply ( float  n00,
float  n01,
float  n02,
float  n10,
float  n11,
float  n12 
)
related

Multiply the matrix with another matrix. This is mostly use to chain transformations. RMatrix_apply

Parameters
n00coefficient 00 of the matrix to be applied
n01coefficient 01 of the matrix to be applied
n02coefficient 02 of the matrix to be applied
n10coefficient 10 of the matrix to be applied
n11coefficient 11 of the matrix to be applied
n12coefficient 12 of the matrix to be applied Geometry ( ) ( ) ( ) ( )
void apply ( RMatrix  rhs)
related

Multiply the matrix with another matrix. This is mostly use to chain transformations. RMatrix_apply

Parameters
rhsright hand side matrix Geometry ( ) ( ) ( ) ( )
RMatrix ( float  m00,
float  m01,
float  m02,
float  m10,
float  m11,
float  m12 
)
related

Create a new matrix given the coefficients. RMatrix

Parameters
m00coefficient 00 of the matrix
m01coefficient 01 of the matrix
m02coefficient 02 of the matrix
m10coefficient 10 of the matrix
m11coefficient 11 of the matrix
m12coefficient 12 of the matrix Geometry ( ) ( ) ( ) ( ) ( )
RMatrix ( )
related

Create a new identity matrix. RMatrix Geometry ( ) ( ) ( ) ( ) ( )

RMatrix ( RMatrix  src)
related

Copy a matrix. RMatrix

Parameters
srcsource matrix from where to copy the matrix Geometry ( ) ( ) ( ) ( ) ( )
void rotate ( float  angle,
float  vx,
float  vy 
)
related

Apply a rotation to the matrix, given an angle and optionally a rotation center. RPoint_rotate Geometry

Parameters
anglethe angle of rotation to be applied
vxthe x coordinate of the center of rotation
vythe y coordinate of the center of rotation ( ) ( ) ( )
void rotate ( float  angle,
RPoint  v 
)
related

Apply a rotation to the matrix, given an angle and optionally a rotation center. RPoint_rotate Geometry

Parameters
anglethe angle of rotation to be applied
vthe position vector of the center of rotation ( ) ( ) ( )
void scale ( float  sx,
float  sy,
float  x,
float  y 
)
related

Apply a scale to the matrix, given scaling factors and optionally a scaling center. RPoint_scale Geometry

Parameters
sxthe scaling coefficient over the x axis
sythe scaling coefficient over the y axis
xx coordinate of the position vector of the center of the scaling
yy coordinate of the position vector of the center of the scaling ( ) ( ) ( )
void scale ( float  s,
float  x,
float  y 
)
related

Apply a scale to the matrix, given scaling factors and optionally a scaling center. RPoint_scale Geometry

Parameters
sthe scaling coefficient for a uniform scaling
xx coordinate of the position vector of the center of the scaling
yy coordinate of the position vector of the center of the scaling ( ) ( ) ( )
void scale ( float  sx,
float  sy,
RPoint  p 
)
related

Apply a scale to the matrix, given scaling factors and optionally a scaling center. RPoint_scale Geometry

Parameters
sxthe scaling coefficient over the x axis
sythe scaling coefficient over the y axis
pthe position vector of the center of the scaling ( ) ( ) ( )
void scale ( float  s,
RPoint  p 
)
related

Apply a scale to the matrix, given scaling factors and optionally a scaling center. RPoint_scale Geometry

Parameters
sthe scaling coefficient for a uniform scaling
pthe position vector of the center of the scaling ( ) ( ) ( )
void shear ( float  shx,
float  shy 
)
related

Use this to apply a shearing to the matrix. RMatrix_translate

Parameters
shxx coordinate shearing
shyy coordinate shearing Geometry ( ) ( ) ( )
void skewX ( float  angle)
related

Use this to apply a skewing to the matrix. RMatrix_skewing

Parameters
angleskewing angle Geometry ( ) ( ) ( )
void translate ( float  tx,
float  ty 
)
related

Apply a translation to the matrix, given the coordinates. RMatrix_translate

Parameters
txx coordinate translation
tyy coordinate translation Geometry ( ) ( ) ( )
void translate ( RPoint  t)
related

Apply a translation to the matrix, given a point. RMatrix_translate

Parameters
tvector translation Geometry ( ) ( ) ( )

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