Struct MeshTransform
- Namespace
- RvtIO.Meshes
- Assembly
- RvtIO.dll
A transform from the frame of a family to the coordinates of the document: a point p maps to
Origin + BasisX * p.X + BasisY * p.Y + BasisZ * p.Z. The basis vectors are the images of the family axes.
A negative RvtIO.Meshes.MeshTransform.Determinant is a mirror image: a renderer that culls back faces reverses the winding of the
symbol's triangles for it.
public readonly record struct MeshTransform : IEquatable<MeshTransform>Implements
Inherited Members
Remarks
A RvtIO.Model.GeoInstance.Transform t holds the 3x3 matrix row by row and then the translation, so the
basis vectors are its columns: BasisX = (t[0], t[3], t[6]), BasisY = (t[1], t[4], t[7]), BasisZ = (t[2], t[5], t[8]) and
Origin = (t[9], t[10], t[11]) (see RvtIO.Meshes.MeshTransform.FromRowMajor(System.Collections.Generic.IReadOnlyList{System.Double})).
Constructors
MeshTransform(MeshVector, MeshVector, MeshVector, MeshVector)
A transform from the frame of a family to the coordinates of the document: a point p maps to
Origin + BasisX * p.X + BasisY * p.Y + BasisZ * p.Z. The basis vectors are the images of the family axes.
A negative RvtIO.Meshes.MeshTransform.Determinant is a mirror image: a renderer that culls back faces reverses the winding of the
symbol's triangles for it.
public MeshTransform(MeshVector Origin, MeshVector BasisX, MeshVector BasisY, MeshVector BasisZ)Parameters
OriginMeshVector-
The image of the family origin, in feet: (t[9], t[10], t[11]).
BasisXMeshVector-
The image of the family X axis: the column (t[0], t[3], t[6]).
BasisYMeshVector-
The image of the family Y axis: the column (t[1], t[4], t[7]).
BasisZMeshVector-
The image of the family Z axis: the column (t[2], t[5], t[8]).
Remarks
A RvtIO.Model.GeoInstance.Transform t holds the 3x3 matrix row by row and then the translation, so the
basis vectors are its columns: BasisX = (t[0], t[3], t[6]), BasisY = (t[1], t[4], t[7]), BasisZ = (t[2], t[5], t[8]) and
Origin = (t[9], t[10], t[11]) (see RvtIO.Meshes.MeshTransform.FromRowMajor(System.Collections.Generic.IReadOnlyList{System.Double})).
Properties
BasisX
The image of the family X axis: the column (t[0], t[3], t[6]).
public MeshVector BasisX { get; init; }Property Value
BasisY
The image of the family Y axis: the column (t[1], t[4], t[7]).
public MeshVector BasisY { get; init; }Property Value
BasisZ
The image of the family Z axis: the column (t[2], t[5], t[8]).
public MeshVector BasisZ { get; init; }Property Value
Determinant
The determinant of the basis: 1 for a rotation, -1 for a mirror image.
public double Determinant { get; }Property Value
Origin
The image of the family origin, in feet: (t[9], t[10], t[11]).
public MeshVector Origin { get; init; }Property Value
Methods
Apply(MeshVector)
The image of a point of the family frame.
public MeshVector Apply(MeshVector point)Parameters
pointMeshVector
Returns
FromRowMajor(IReadOnlyList<double>)
The transform of the 12 values of a RvtIO.Model.GeoInstance.Transform.
public static MeshTransform FromRowMajor(IReadOnlyList<double> transform)Parameters
transformIReadOnlyList<double>
Returns
Exceptions
- ArgumentException
-
Fewer than 12 values.