Table of Contents

Class GeneralTransform

Namespace
Hi.Mech.Topo
Assembly
HiMech.dll

Represents a general transformation that combines scaling, rotation, and translation.

public class GeneralTransform : IStaticTransformer, ITransformer, IMakeXmlSource, IGetInverseTransformer
Inheritance
GeneralTransform
Implements
Inherited Members
Extension Methods

Constructors

GeneralTransform()

Initializes a new instance of the GeneralTransform class.

public GeneralTransform()

GeneralTransform(Mat4d)

Initializes a new instance of the GeneralTransform class from a 4x4 transformation matrix.

public GeneralTransform(Mat4d mat)

Parameters

mat Mat4d

The transformation matrix.

GeneralTransform(double, StaticRotation, StaticTranslation)

Initializes a new instance of the GeneralTransform class with specified scale, rotation, and translation.

public GeneralTransform(double scale, StaticRotation rotation, StaticTranslation translation)

Parameters

scale double

The scaling factor.

rotation StaticRotation

The rotation transformation.

translation StaticTranslation

The translation transformation.

GeneralTransform(XElement)

Ctor.

public GeneralTransform(XElement src)

Parameters

src XElement

XML

Properties

Rotation

2th transform.

public StaticRotation Rotation { get; }

Property Value

StaticRotation

Scale

1th transform.

public double Scale { get; set; }

Property Value

double

Translation

3th transform.

public StaticTranslation Translation { get; }

Property Value

StaticTranslation

XName

Static name.

public static string XName { get; }

Property Value

string

Methods

Clone()

Clones this instance.

public ITransformer Clone()

Returns

ITransformer

clone

GetInverseTransformer()

Gets the inverse transformer of this transformer.

public ITransformer GetInverseTransformer()

Returns

ITransformer

The inverse transformer.

GetMat()

Gets the transform matrix.

public Mat4d GetMat()

Returns

Mat4d

The transform matrix.

GetMatInv()

Gets the inverse transform matrix.

public Mat4d GetMatInv()

Returns

Mat4d

The inverse transform matrix.

MakeXmlSource(string, string)

Creates an XML representation of the object. This method may also generate additional resources such as related files.

public virtual XElement MakeXmlSource(string baseDirectory, string relFile)

Parameters

baseDirectory string

The base directory for resolving relative paths

relFile string

The relative file path for the XML source

Returns

XElement

An XML element representing the object's state