6#include "Math/UnrealMathUtility.h"
8#include "Math/Matrix.h"
15struct TInverseRotationMatrix
20
21
22
23
24 TInverseRotationMatrix(
const TRotator<T>& Rot);
28 explicit TInverseRotationMatrix(
const TInverseRotationMatrix<FArg>& From) : TMatrix<T>(From) {}
32FORCEINLINE TInverseRotationMatrix<T>::TInverseRotationMatrix(
const TRotator<T>& Rot)
35 TPlane<T>(+FMath::Cos(Rot.Yaw *
UE_PI / 180.f), -FMath::Sin(Rot.Yaw *
UE_PI / 180.f), 0.0f, 0.0f),
36 TPlane<T>(+FMath::Sin(Rot.Yaw *
UE_PI / 180.f), +FMath::Cos(Rot.Yaw *
UE_PI / 180.f), 0.0f, 0.0f),
37 TPlane<T>(0.0f, 0.0f, 1.0f, 0.0f),
38 TPlane<T>(0.0f, 0.0f, 0.0f, 1.0f)) *
40 TPlane<T>(+FMath::Cos(Rot.Pitch *
UE_PI / 180.f), 0.0f, -FMath::Sin(Rot.Pitch *
UE_PI / 180.f), 0.0f),
41 TPlane<T>(0.0f, 1.0f, 0.0f, 0.0f),
42 TPlane<T>(+FMath::Sin(Rot.Pitch *
UE_PI / 180.f), 0.0f, +FMath::Cos(Rot.Pitch *
UE_PI / 180.f), 0.0f),
43 TPlane<T>(0.0f, 0.0f, 0.0f, 1.0f)) *
45 TPlane<T>(1.0f, 0.0f, 0.0f, 0.0f),
46 TPlane<T>(0.0f, +FMath::Cos(Rot.Roll *
UE_PI / 180.f), +FMath::Sin(Rot.Roll *
UE_PI / 180.f), 0.0f),
47 TPlane<T>(0.0f, -FMath::Sin(Rot.Roll *
UE_PI / 180.f), +FMath::Cos(Rot.Roll *
UE_PI / 180.f), 0.0f),
48 TPlane<T>(0.0f, 0.0f, 0.0f, 1.0f))
57template<>
struct TIsUECoreVariant<FInverseRotationMatrix44f> {
enum { Value =
true }; };
58template<>
struct TIsUECoreVariant<FInverseRotationMatrix44d> {
enum { Value =
true }; };
#define UE_DECLARE_LWC_TYPE(...)
#define TEMPLATE_REQUIRES(...)