Navigation
API > API/Runtime > API/Runtime/GeometryCore
References
| Module | GeometryCore |
| Header | /Engine/Source/Runtime/GeometryCore/Public/TransformTypes.h |
| Include | #include "TransformTypes.h" |
Syntax
template<typename RealType>
class TTransformSRT3
Remarks
TTransformSRT3 is a variant of the standard UE FTransform/TTransform that uses the UE::Geometry::TQuaternion instead of the UE::Math::TQuat.
Transform order is Scale, then Rotate, then Translate. So mathematically (T * R * S) * v , assuming traditional matrix-vector multiplication order (note that the UE::Math library uses the opposite vector*Matrix ordering for TMatrix!)
Implicit constructors/casts are defined to/from FTransform3d and FTransform3f. This will likely be revised in future so that conversions that lose precision are explicit.
Variables
| Type | Name | Description | |
|---|---|---|---|
| TQuaternion< RealType > | Rotation | ||
| TVector< RealType > | Scale3D | ||
| TVector< RealType > | Translation |
Constructors
| Type | Name | Description | |
|---|---|---|---|
TTransformSRT3
(
const UE::Math::TVector< RealType >& TranslationIn |
|||
TTransformSRT3
(
const FTransform3f& Transform |
|||
TTransformSRT3
(
const FTransform3d& Transform |
|||
TTransformSRT3
(
const TQuaternion< RealType >& RotationIn, |
|||
TTransformSRT3
(
const TQuaternion< RealType >& RotationIn, |
Functions
| Type | Name | Description | |
|---|---|---|---|
| bool | CanRepresentInverse
(
RealType Tolerance |
Reports wheth the inverse is representable with a single TTransformSRT3. | |
| void | ClampMinimumScale
(
RealType MinimumScale |
Clamp all scale components to a minimum value. | |
| RealType | |||
| const TQuaternion< RealType > & | GetRotation () |
||
| FRotator | GetRotator () |
||
| TVector< RealType > | GetSafeScaleReciprocal
(
const TVector< RealType >& InScale, |
||
| const TVector< RealType > & | GetScale () |
||
| const TVector< RealType > & | GetScale3D () |
||
| const TVector< RealType > & | |||
| bool | HasNonUniformScale
(
RealType Tolerance |
||
| TTransformSRT3< RealType > | Identity () |
||
| TVector< RealType2 > | InverseTransformNormal
(
const UE::Math::TVector< RealType2 >& Normal |
Surface Normals are special, their inverse transform is InverseRotate( Normalize(Scale * Normal) ) ) | |
| TVector< RealType2 > | InverseTransformPosition
(
const UE::Math::TVector< RealType2 >& P |
||
| UE::Math::TRay< RealType > | InverseTransformRay
(
const UE::Math::TRay< RealType >& Ray |
||
| TVector< RealType2 > | InverseTransformVector
(
const UE::Math::TVector< RealType2 >& V |
||
| TVector< RealType2 > | InverseTransformVectorNoScale
(
const UE::Math::TVector< RealType2 >& V |
||
| TTransformSRT3< RealType > | InverseUnsafe
(
RealType Tolerance |
Attempts to return an inverse, but will give an incorrect result if the transform has both non-uniform scaling and rotation, because TTransformSRT3 |
|
| void | SetRotation
(
const TQuaternion< RealType >& RotationIn |
Set Rotation portion of Transform | |
| void | SetScale
(
const UE::Math::TVector< RealType >& ScaleIn |
Set Scale portion of transform | |
| void | SetTranslation
(
const UE::Math::TVector< RealType >& TranslationIn |
Set Translation portion of transform | |
| TVector< RealType2 > | TransformNormal
(
const UE::Math::TVector< RealType2 >& Normal |
Surface Normals are special, their transform is Rotate( Normalize( (1/Scale) * Normal) ) ). However 1/Scale requires special handling in case any component is near-zero. | |
| TVector< RealType2 > | TransformPosition
(
const TVector< RealType2 >& P |
The following templates perform vector-type-conversion variants. | |
| UE::Math::TRay< RealType > | TransformRay
(
const UE::Math::TRay< RealType >& Ray |
||
| TVector< RealType2 > | TransformVector
(
const UE::Math::TVector< RealType2 >& V |
||
| TVector< RealType2 > | TransformVectorNoScale
(
const UE::Math::TVector< RealType2 >& V |
Operators
| Type | Name | Description | |
|---|---|---|---|