Class TMatrix
Last update: 16.07.2025Namespace: VM.Managed
Assembly: VMAppCore.dll
This class is to represent the matrix of transform.
public sealed class TMatrix : MatrixBase, IOMatrix
Inheritance
object ← MatrixBase ← TMatrix
Implements
Extension Methods
LinkPropertyItemCache.GetLinkProperties(object, LinkPropertyType),
LinkPropertyItemCache.GetLinkPropertiesAndValues(object, LinkPropertyType),
LinkPropertyItemCache.GetLinkedObjects
Constructors
TMatrix(double[])
Initializes a new instance of the
public TMatrix(double[] arr)
Parameters
arr double[]
The data of orientation.
TMatrix(Plane, VectorBase, VectorBase, VectorBase)
Initializes a new instance of the
public TMatrix(Plane type, VectorBase vecMaster, VectorBase vecSlave, VectorBase vecPos)
Parameters
type Plane
The type of plane.
vecMaster VectorBase
The vector for master.
vecSlave VectorBase
The vector for slave.
vecPos VectorBase
The position.
TMatrix(Plane, VectorBase, VectorBase)
Initializes a new instance of the
public TMatrix(Plane type, VectorBase vecMaster, VectorBase vecSlave)
Parameters
type Plane
The type of plane.
vecMaster VectorBase
The vector for master.
vecSlave VectorBase
The vector for slave.
TMatrix(TMatrix)
Initializes a new instance of the
public TMatrix(TMatrix mat)
Parameters
mat TMatrix
The matrix of transform
TMatrix()
Initializes a new instance of the
public TMatrix()
TMatrix(SerializationInfo, StreamingContext)
protected TMatrix(SerializationInfo info, StreamingContext context)
Parameters
info SerializationInfo
context StreamingContext
Properties
Array
Gets or sets the data of OMatrix.
public virtual double[] Array { get; set; }
Property Value
double[]
InverseTransformationMatrix
Gets the matrix of inverse transform.
public TMatrix InverseTransformationMatrix { get; }
Property Value
Orientation
Gets the matrix of orientation.
public OMatrix Orientation { get; }
Property Value
Position
Gets or sets the position of transform.
public VectorBase Position { get; set; }
Property Value
XVector
Gets the XVector.
public virtual VectorBase XVector { get; }
Property Value
YVector
Gets the YVector.
public virtual VectorBase YVector { get; }
Property Value
ZVector
Gets the ZVector.
public virtual VectorBase ZVector { get; }
Property Value
this[uint, uint]
public double this[uint r, uint c] { get; set; }
Property Value
this[Coordinate, Coordinate]
public double this[Coordinate r, Coordinate c] { get; set; }
Property Value
this[uint]
public VectorBase this[uint n] { get; set; }
Property Value
this[Coordinate]
public VectorBase this[Coordinate n] { get; set; }
Property Value
Methods
Clone()
public object Clone()
Returns
GetArray()
public double[] GetArray()
Returns
double[]
GetDirectionVector(uint)
Get the direction vector for axis.
public VectorBase GetDirectionVector(uint axis)
Parameters
axis uint
The type of axis.
Returns
The direction vector.
GetDirectionVector(Coordinate)
Get the direction vector for axis.
public VectorBase GetDirectionVector(Coordinate axis)
Parameters
axis Coordinate
The type of axis.
Returns
The direction vector.
GetObjectData(SerializationInfo, StreamingContext)
public void GetObjectData(SerializationInfo info, StreamingContext __unnamed001)
Parameters
info SerializationInfo
__unnamed001 StreamingContext
GetSchema()
public XmlSchema GetSchema()
Returns
Initialize()
Initializes a instance of OMatrix.
public void Initialize()
Normalize()
Nomalize a instance of OMatrix.
public void Normalize()
ReadXml(XmlReader)
public void ReadXml(XmlReader reader)
Parameters
reader XmlReader
RotateAxisDeg(VectorBase, double)
To rotate counterclockwise for axis.
public void RotateAxisDeg(VectorBase axis, double dAngle)
Parameters
axis VectorBase
The rotation axis.
dAngle double
The degree.
RotateAxisDeg(uint, double)
To rotate counterclockwise for coordinate.
public void RotateAxisDeg(uint nCoord, double dAngle)
Parameters
nCoord uint
The rotation coordinate.
dAngle double
The degree.
RotateAxisDeg(Coordinate, double)
To rotate counterclockwise for coordinate.
public void RotateAxisDeg(Coordinate c, double dAngle)
Parameters
c Coordinate
The rotation coordinate.
dAngle double
The degree.
RotateAxisRad(VectorBase, double)
To rotate counterclockwise for axis.
public void RotateAxisRad(VectorBase axis, double dAngle)
Parameters
axis VectorBase
The rotation axis.
dAngle double
The radian.
RotateAxisRad(uint, double)
To rotate counterclockwise for coordinate.
public void RotateAxisRad(uint nCoord, double dAngle)
Parameters
nCoord uint
The rotation coordinate.
dAngle double
The radian.
RotateAxisRad(Coordinate, double)
To rotate counterclockwise for coordinate.
public void RotateAxisRad(Coordinate c, double dAngle)
Parameters
c Coordinate
The rotation coordinate.
dAngle double
The radian.
RotateXDeg(double)
To rotate counterclockwise for x-axis.
public void RotateXDeg(double dAngle)
Parameters
dAngle double
The degree.
RotateXRad(double)
To rotate counterclockwise for x-axis.
public void RotateXRad(double dAngle)
Parameters
dAngle double
The radian.
RotateYDeg(double)
To rotate counterclockwise for y-axis.
public void RotateYDeg(double dAngle)
Parameters
dAngle double
The degree.
RotateYRad(double)
To rotate counterclockwise for y-axis.
public void RotateYRad(double dAngle)
Parameters
dAngle double
The radian.
RotateZDeg(double)
To rotate counterclockwise for z-axis.
public void RotateZDeg(double dAngle)
Parameters
dAngle double
The degree.
RotateZRad(double)
To rotate counterclockwise for z-axis.
public void RotateZRad(double dAngle)
Parameters
dAngle double
The radian.
Set(double[])
Set data of transform.
public void Set(double[] arr)
Parameters
arr double[]
The data of transform
Set(TMatrix)
Set Matrix of transform.
public void Set(TMatrix mat)
Parameters
mat TMatrix
The matrix of transform
SetOrientation(double[])
Set data of orientation.
public void SetOrientation(double[] arr)
Parameters
arr double[]
The data of orientation.
SetOrientation(OMatrix)
Set data of orientation.
public void SetOrientation(OMatrix mat)
Parameters
mat OMatrix
The matrix of orientation.
SetOrientation(Plane, VectorBase, VectorBase)
Set data of orientation.
public void SetOrientation(Plane type, VectorBase vecMaster, VectorBase vecSlave)
Parameters
type Plane
The type of plane.
vecMaster VectorBase
The vector for master.
vecSlave VectorBase
The vector for slave.
SetOrientationEADeg(RotationAxes, double, double, double)
Set data of orientation for euler angle. Unit is degree.
public void SetOrientationEADeg(RotationAxes ea, double dAlpha, double dBeta, double dGamma)
Parameters
ea RotationAxes
The type of euler angle.
dAlpha double
The alpha of euler angle.
dBeta double
The beta of euler angle.
dGamma double
The gamma of euler angle.
SetOrientationEARad(RotationAxes, double, double, double)
Set data of orientation for euler angle. Unit is radian.
public void SetOrientationEARad(RotationAxes ea, double dAlpha, double dBeta, double dGamma)
Parameters
ea RotationAxes
The type of euler angle.
dAlpha double
The alpha of euler angle.
dBeta double
The beta of euler angle.
dGamma double
The gamma of euler angle.
SetOrientationFixedAngleDeg(RotationAxes, double, double, double)
Set data of orientation for fixed angle. Unit is degree.
public void SetOrientationFixedAngleDeg(RotationAxes ea, double dAlpha, double dBeta, double dGamma)
Parameters
ea RotationAxes
The type of fixed angle.
dAlpha double
The alpha of fixed angle.
dBeta double
The beta of fixed angle.
dGamma double
The gamma of fixed angle.
SetOrientationFixedAngleRad(RotationAxes, double, double, double)
Set data of orientation for fixed angle. Unit is radian.
public void SetOrientationFixedAngleRad(RotationAxes ea, double dAlpha, double dBeta, double dGamma)
Parameters
ea RotationAxes
The type of fixed angle.
dAlpha double
The alpha of fixed angle.
dBeta double
The beta of fixed angle.
dGamma double
The gamma of fixed angle.
Translate(double, double, double)
To translate for position.
public void Translate(double dX, double dY, double dZ)
Parameters
dX double
The value of X
dY double
The value of y
dZ double
The value of z
Translate(VectorBase)
To translate for position.
public void Translate(VectorBase vec)
Parameters
vec VectorBase
The vector
TransposeOrientation()
Transposed rows and columns of the matrix.
public void TransposeOrientation()
WriteXml(XmlWriter)
public void WriteXml(XmlWriter writer)
Parameters
writer XmlWriter
op_MultiplicationAssignment(VectorBase, TMatrix)
public static VectorBase op_MultiplicationAssignment(VectorBase vec, TMatrix mat)
Parameters
vec VectorBase
mat TMatrix
Returns
op_MultiplicationAssignment(TMatrix, TMatrix)
public static TMatrix op_MultiplicationAssignment(TMatrix mat1, TMatrix mat2)
Parameters
mat1 TMatrix
mat2 TMatrix
Returns
Operators
operator ==(TMatrix, TMatrix)
public static bool operator ==(TMatrix mat1, TMatrix mat2)
Parameters
mat1 TMatrix
mat2 TMatrix
Returns
implicit operator TMatrix(TMatrix)
public static implicit operator TMatrix(TMatrix mat)
Parameters
mat TMatrix
Returns
TMatrix
implicit operator TMatrix(TMatrix)
public static implicit operator TMatrix(TMatrix mat)
Parameters
mat TMatrix
Returns
operator !=(TMatrix, TMatrix)
public static bool operator !=(TMatrix mat1, TMatrix mat2)
Parameters
mat1 TMatrix
mat2 TMatrix
Returns
operator *(VectorBase, TMatrix)
public static VectorBase operator *(VectorBase vec, TMatrix mat)
Parameters
vec VectorBase
mat TMatrix
Returns
operator *(TMatrix, TMatrix)
public static TMatrix operator *(TMatrix mat1, TMatrix mat2)
Parameters
mat1 TMatrix
mat2 TMatrix