Navigation
API > API/Runtime > API/Runtime/Core
| Name | TTransform |
| Type | struct |
| Header File | /Engine/Source/Runtime/Core/Public/Math/MathFwd.h |
| Include Path | #include "Math/MathFwd.h" |
| Source | /Engine/Source/Runtime/Core/Public/Math/TransformNonVectorized.h |
Syntax
template<typename T>
struct TTransform
Derived Classes
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
TTransform () |
Default constructor. | Math/TransformNonVectorized.h | |
TTransform
(
const TVector< T >& InTranslation |
Constructor with an initial translation | Math/TransformNonVectorized.h | |
TTransform
(
ENoInit |
Constructor with leaving uninitialized memory | Math/TransformNonVectorized.h | |
TTransform
(
const TQuat< T >& InRotation |
Constructor with an initial rotation | Math/TransformNonVectorized.h | |
TTransform
(
const TRotator< T >& InRotation |
Constructor with an initial rotation | Math/TransformNonVectorized.h | |
TTransform
(
const TMatrix< T >& InMatrix |
Constructor for converting a Matrix (including scale) into a TTransform |
Math/TransformNonVectorized.h | |
TTransform
(
const TTransform< FArg >& From |
Conversion to other type. | Math/TransformNonVectorized.h | |
TTransform
(
const TQuat< T >& InRotation, |
Constructor with all components initialized | Math/TransformNonVectorized.h | |
TTransform
(
const TRotator< T >& InRotation, |
Constructor with all components initialized, taking a TRotator |
Math/TransformNonVectorized.h | |
TTransform
(
const TVector< T >& InX, |
Constructor that takes basis axes and translation | Math/TransformNonVectorized.h |
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| FReal | T | Math/TransformNonVectorized.h | |
| TransformVectorRegister | TVectorRegisterType< T > | Math/TransformNonVectorized.h |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| Identity | const TTransform< T > | The identity transformation (Rotation = TQuat |
Math/TransformNonVectorized.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| Z_Construct_UScriptStruct_FTransform_Statics | friend | Math/TransformNonVectorized.h | ||
| Z_Construct_UScriptStruct_FTransform3d_Statics | friend | Math/TransformNonVectorized.h | ||
| Z_Construct_UScriptStruct_FTransform3f_Statics | friend | Math/TransformNonVectorized.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void Accumulate
(
const TTransform< T >& SourceAtom |
: Added template type function for Accumulate The template type isn't much useful yet, but it is with the plan to move forward to unify blending features with just type of additive or full pose Eventually it would be nice to just call blend and it all works depending on full pose or additive, but right now that is a lot more refactoring For now this types only defines the different functionality of accumulate Accumulates another transform with this one | Math/TransformNonVectorized.h | |
void Accumulate
(
const TTransform< T >& Atom, |
Accumulates another transform with this one, with a blending weight | Math/TransformNonVectorized.h | |
void AccumulateWithAdditiveScale
(
const TTransform< T >& Atom, |
Accumulates another transform with this one, with a blending weight | Math/TransformNonVectorized.h | |
void AccumulateWithShortestRotation
(
const TTransform< T >& DeltaAtom, |
Accumulates another transform with this one, with an optional blending weight | Math/TransformNonVectorized.h | |
void AddToTranslation
(
const TVector< T >& DeltaTranslation |
Adjusts the translation component of this transformation | Math/TransformNonVectorized.h | |
void Blend
(
const TTransform< T >& Atom1, |
Set this transform to the weighted blend of the supplied two transforms. | Math/TransformNonVectorized.h | |
void BlendWith
(
const TTransform< T >& OtherAtom, |
Set this Transform to the weighted blend of it and the supplied Transform. | Math/TransformNonVectorized.h | |
void ConcatenateRotation
(
const TQuat< T >& DeltaRotation |
Concatenates another rotation to this transformation | Math/TransformNonVectorized.h | |
bool ContainsNaN() |
Checks the components for non-finite values (NaN or Inf). | Math/TransformNonVectorized.h | |
void CopyRotation
(
const TTransform< T >& Other |
Copy rotation from another TTransform |
Math/TransformNonVectorized.h | |
void CopyRotationPart
(
const TTransform< T >& SrcBA |
Sets the Rotation and Scale3D of this transformation from another transform | Math/TransformNonVectorized.h | |
void CopyScale3D
(
const TTransform< T >& Other |
Copy scale from another TTransform |
Math/TransformNonVectorized.h | |
void CopyTranslation
(
const TTransform< T >& Other |
Copy translation from another TTransform |
Math/TransformNonVectorized.h | |
void CopyTranslationAndScale3D
(
const TTransform< T >& SrcBA |
Sets the Translation and Scale3D of this transformation from another transform | Math/TransformNonVectorized.h | |
bool DebugEqualMatrix
(
const TMatrix< T >& Matrix |
Debug purpose only | Math/TransformNonVectorized.h | |
void DebugPrint() |
Does a debugf of the contents of this Transform.Does a debugf of the contents of this BoneAtom. | Math/TransformNonVectorized.h | |
void DiagnosticCheck_IsValid() |
Math/TransformNonVectorized.h | ||
void DiagnosticCheckNaN_All() |
Math/TransformNonVectorized.h | ||
void DiagnosticCheckNaN_Rotate() |
Math/TransformNonVectorized.h | ||
void DiagnosticCheckNaN_Scale3D() |
Math/TransformNonVectorized.h | ||
void DiagnosticCheckNaN_Translate() |
Math/TransformNonVectorized.h | ||
bool Equals
(
const TTransform< T >& Other, |
Test if all components of the transforms are equal, within a tolerance. | Math/TransformNonVectorized.h | |
bool EqualsNoScale
(
const TTransform< T >& Other, |
Test if rotation and translation components of the transforms are equal, within a tolerance. | Math/TransformNonVectorized.h | |
FReal GetDeterminant() |
Calculate the determinant of this transformation | Math/TransformNonVectorized.h | |
TVector< T > GetLocation() |
Temp function for easy conversion | Math/TransformNonVectorized.h | |
T GetMaximumAxisScale() |
Same version of TMatrix |
Math/TransformNonVectorized.h | |
T GetMinimumAxisScale() |
Math/TransformNonVectorized.h | ||
TTransform< T > GetRelativeTransform
(
const TTransform< T >& Other |
Math/TransformNonVectorized.h | ||
TTransform< T > GetRelativeTransformReverse
(
const TTransform< T >& Other |
Math/TransformNonVectorized.h | ||
TQuat< T > GetRotation() |
Returns the rotation component | Math/TransformNonVectorized.h | |
TransformVectorRegister GetRotationRegister() |
Math/TransformNonVectorized.h | ||
TVector< T > GetScale3D() |
Returns the Scale3D component | Math/TransformNonVectorized.h | |
TTransform< T > GetScaled
(
T Scale |
Apply Scale to this transform | Math/TransformNonVectorized.h | |
TTransform< T > GetScaled
(
TVector< T > Scale |
Apply Scale to this transform | Math/TransformNonVectorized.h | |
TVector< T > GetScaledAxis
(
EAxis::Type InAxis |
X = 0, y = 1, z = 2 | Math/TransformNonVectorized.h | |
TVector< T > GetTranslation() |
Returns the translation component | Math/TransformNonVectorized.h | |
TransformVectorRegister GetTranslationRegister() |
For low-level VectorRegister programming. | Math/TransformNonVectorized.h | |
TVector< T > GetUnitAxis
(
EAxis::Type InAxis |
X = 0, y = 1, z = 2 | Math/TransformNonVectorized.h | |
bool Identical
(
const TTransform< T >* Other, |
Test if all components of the transform property are equal. | Math/TransformNonVectorized.h | |
bool InitFromString
(
const FString& InSourceString |
Acceptable form: "%f,%f,%f|%f,%f,%f|%f,%f,%f" | Math/TransformNonVectorized.h | |
TTransform< T > Inverse() |
Convert this Transform to inverse. | Math/TransformNonVectorized.h | |
TVector< T > InverseTransformPosition
(
const TVector< T >& V |
Do backward operation when inverse, translation -> rotation -> scale | Math/TransformNonVectorized.h | |
| Do backward operation when inverse, translation -> rotation | Math/TransformNonVectorized.h | ||
TQuat< T > InverseTransformRotation
(
const TQuat< T >& Q |
Inverse transform a rotation. | Math/TransformNonVectorized.h | |
TVector< T > InverseTransformVector
(
const TVector< T >& V |
Do backward operation when inverse, translation -> rotation -> scale | Math/TransformNonVectorized.h | |
| Do backward operation when inverse, translation -> rotation | Math/TransformNonVectorized.h | ||
bool IsRotationNormalized() |
Checks whether the rotation component is normalized or not | Math/TransformNonVectorized.h | |
bool IsValid() |
Math/TransformNonVectorized.h | ||
void LerpTranslationScale3D
(
const TTransform< T >& SourceAtom1, |
Set the translation and Scale3D components of this transform to a linearly interpolated combination of two other transforms | Math/TransformNonVectorized.h | |
void Mirror
(
EAxis::Type MirrorAxis, |
Math/TransformNonVectorized.h | ||
void MultiplyScale3D
(
const TVector< T >& Scale3DMultiplier |
Scales the Scale3D component by a new factor | Math/TransformNonVectorized.h | |
void NormalizeRotation() |
Normalize the rotation component of this transformation | Math/TransformNonVectorized.h | |
void RemoveScaling
(
FReal Tolerance |
This function is from matrix, and all it does is to normalize rotation portion | Math/TransformNonVectorized.h | |
bool RotationEquals
(
const TTransform< T >& Other, |
Test if this Transform's rotation equals another's rotation, within a tolerance. Preferred over "GetRotation().Equals(Other.GetRotation())" because it is faster on some platforms. | Math/TransformNonVectorized.h | |
TRotator< T > Rotator() |
Math/TransformNonVectorized.h | ||
bool Scale3DEquals
(
const TTransform< T >& Other, |
Test if this Transform's scale equals another's scale, within a tolerance. Preferred over "GetScale3D().Equals(Other.GetScale3D())" because it is faster on some platforms. | Math/TransformNonVectorized.h | |
void ScaleTranslation
(
const FReal& Scale |
Math/TransformNonVectorized.h | ||
void ScaleTranslation
(
const TVector< T >& InScale3D |
Scale the translation part of the Transform by the supplied vector. | Math/TransformNonVectorized.h | |
bool Serialize
(
FArchive& Ar |
Math/TransformNonVectorized.h | ||
| Math/TransformNonVectorized.h | |||
| Sets the components | Math/TransformNonVectorized.h | ||
void SetFromMatrix
(
const TMatrix< T >& InMatrix |
Math/TransformNonVectorized.h | ||
void SetIdentity() |
Sets the components to the identity transform: Rotation = (0,0,0,1) Translation = (0,0,0) Scale3D = (1,1,1) | Math/TransformNonVectorized.h | |
void SetIdentityZeroScale() |
Sets the components to the 'additive' identity transform: Rotation = (0,0,0,1) Translation = (0,0,0) Scale3D = (0,0,0) | Math/TransformNonVectorized.h | |
void SetLocation
(
const TVector< T >& Origin |
Set the translation of this transformation | Math/TransformNonVectorized.h | |
void SetRotation
(
const TQuat< T >& NewRotation |
Sets the rotation component | Math/TransformNonVectorized.h | |
void SetRotationRegister
(
TransformVectorRegister InRotation |
Math/TransformNonVectorized.h | ||
void SetScale3D
(
const TVector< T >& NewScale3D |
Sets the Scale3D component | Math/TransformNonVectorized.h | |
void SetToRelativeTransform
(
const TTransform< T >& ParentTransform |
Set current transform and the relative to ParentTransform. | Math/TransformNonVectorized.h | |
void SetTranslation
(
const TVector< T >& NewTranslation |
Sets the translation component | Math/TransformNonVectorized.h | |
| Sets both the translation and Scale3D components at the same time | Math/TransformNonVectorized.h | ||
void SetTranslationRegister
(
TransformVectorRegister InTranslation |
Math/TransformNonVectorized.h | ||
FString ToHumanReadableString() |
Convert TTransform |
Math/TransformNonVectorized.h | |
TMatrix< T > ToInverseMatrixWithScale() |
Convert this Transform to matrix with scaling and compute the inverse of that. | Math/TransformNonVectorized.h | |
TMatrix< T > ToMatrixNoScale() |
Convert this Transform to a transformation matrix, ignoring its scaling | Math/TransformNonVectorized.h | |
TMatrix< T > ToMatrixWithScale() |
Convert this Transform to a transformation matrix with scaling. | Math/TransformNonVectorized.h | |
FString ToString() |
Math/TransformNonVectorized.h | ||
| Transform TVector4 |
Math/TransformNonVectorized.h | ||
| Transform homogenous TVector4 |
Math/TransformNonVectorized.h | ||
| Math/TransformNonVectorized.h | |||
| Math/TransformNonVectorized.h | |||
TQuat< T > TransformRotation
(
const TQuat< T >& Q |
Transform a rotation. | Math/TransformNonVectorized.h | |
| Math/TransformNonVectorized.h | |||
| Math/TransformNonVectorized.h | |||
bool TranslationEquals
(
const TTransform< T >& Other, |
Test if this Transform's translation equals another's translation, within a tolerance. Preferred over "GetTranslation().Equals(Other.GetTranslation())" because it is faster on some platforms. | Math/TransformNonVectorized.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static TVector< T > AddTranslations
(
const TTransform< T >& A, |
Add the translations from two TTransform |
Math/TransformNonVectorized.h | |
| Math/TransformNonVectorized.h | |||
static bool AreRotationsEqual
(
const TTransform< T >& A, |
Test if A's rotation equals B's rotation, within a tolerance. Preferred over "A.GetRotation().Equals(B.GetRotation())" because it is faster on some platforms. | Math/TransformNonVectorized.h | |
static bool AreScale3DsEqual
(
const TTransform< T >& A, |
Test if A's scale equals B's scale, within a tolerance. Preferred over "A.GetScale3D().Equals(B.GetScale3D())" because it is faster on some platforms. | Math/TransformNonVectorized.h | |
static bool AreTranslationsEqual
(
const TTransform< T >& A, |
Test if A's translation equals B's translation, within a tolerance. Preferred over "A.GetTranslation().Equals(B.GetTranslation())" because it is faster on some platforms. | Math/TransformNonVectorized.h | |
static void BlendFromIdentityAndAccumulate
(
TTransform< T >& FinalAtom, |
Blends the Identity transform with a weighted source transform and accumulates that into a destination transform | Math/TransformNonVectorized.h | |
static void ConstructTransformFromMatrixWithDesiredScale
(
const TMatrix< T >& AMatrix, |
Create a new transform from multiplications of given to matrices (AMatrix*BMatrix) using desired scale This is used by MultiplyUsingMatrixWithScale and GetRelativeTransformUsingMatrixWithScale This is only used to handle negative scale | Math/TransformNonVectorized.h | |
static void GetRelativeTransformUsingMatrixWithScale
(
TTransform< T >* OutTransform, |
Create a new transform: OutTransform = Base * Relative(-1) using the matrix while keeping the scale that's given by Base and Relative Please note that this operation is a lot more expensive than normal GetRelativeTrnasform | Math/TransformNonVectorized.h | |
| Mathematically if you have 0 scale, it should be infinite, however, in practice if you have 0 scale, and relative transform doesn't make much sense anymore because you should be instead of showing gigantic infinite mesh also returning BIG_NUMBER causes sequential NaN issues by multiplying so we hardcode as 0 | Math/TransformNonVectorized.h | ||
static void Multiply
(
TTransform< T >* OutTransform, |
Create a new transform: OutTransform = A * B. | Math/TransformNonVectorized.h | |
static void MultiplyUsingMatrixWithScale
(
TTransform< T >* OutTransform, |
Create a new transform: OutTransform = A * B using the matrix while keeping the scale that's given by A and B Please note that this operation is a lot more expensive than normal Multiply | Math/TransformNonVectorized.h | |
static TVector< T > SubtractTranslations
(
const TTransform< T >& A, |
Subtract translations from two TTransform |
Math/TransformNonVectorized.h |
Operators
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
TTransform< T > operator*
(
const TTransform< T >& Other |
Return a transform that is the result of this multiplied by another transform. | Math/TransformNonVectorized.h | |
TTransform< T > operator*
(
const TQuat< T >& Other |
Return a transform that is the result of this multiplied by another transform (made only from a rotation). | Math/TransformNonVectorized.h | |
TTransform< T > operator*
(
T Mult |
Math/TransformNonVectorized.h | ||
TTransform< T > & operator*=
(
T Mult |
Math/TransformNonVectorized.h | ||
void operator*=
(
const TTransform< T >& Other |
Sets this transform to the result of this multiplied by another transform. | Math/TransformNonVectorized.h | |
void operator*=
(
const TQuat< T >& Other |
Sets this transform to the result of this multiplied by another transform (made only from a rotation). | Math/TransformNonVectorized.h | |
TTransform< T > operator+
(
const TTransform< T >& Atom |
Quaternion addition is wrong here. | Math/TransformNonVectorized.h | |
TTransform< T > & operator+=
(
const TTransform< T >& Atom |
Math/TransformNonVectorized.h |