UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
ClothingSimulationTeleportHelpers.h
Go to the documentation of this file.
1// Copyright Epic Games, Inc. All Rights Reserved.
2#pragma once
3
5
7
9{
11 {
12 // Threshold <= 0 disables check.
13 // Cos(0) = 1, so set to 1 for all negative values.
14 // CalculateClothingTeleport will use ClothTeleportCosineThreshold >= 1 to disable.
15 return ThresholdInDegrees > 0.f ? FMath::Cos(FMath::DegreesToRadians(ThresholdInDegrees)) : 1.f;
16 }
17
19 {
20 // Threshold <= 0 disables check.
22 }
23
25};
EClothingTeleportMode
Definition ClothingSystemRuntimeTypes.h:46
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
uint8_t uint8
Definition binka_ue_file_header.h:8
Definition ClothingSimulationTeleportHelpers.cpp:13
EClothingTeleportMode CalculateClothingTeleport(EClothingTeleportMode CurrentTeleportMode, const FMatrix &CurRootBoneMat, const FMatrix &PrevRootBoneMat, bool bResetAfterTeleport, float ClothTeleportDistThresholdSquared, float ClothTeleportCosineThresholdInRad)
Definition ClothingSimulationTeleportHelpers.cpp:14
float ComputeTeleportDistanceThresholdSquared(float ThresholdDistance)
Definition ClothingSimulationTeleportHelpers.h:18
float ComputeTeleportCosineRotationThreshold(float ThresholdInDegrees)
Definition ClothingSimulationTeleportHelpers.h:10
static constexpr UE_FORCEINLINE_HINT auto DegreesToRadians(T const &DegVal) -> decltype(DegVal *(UE_PI/180.f))
Definition UnrealMathUtility.h:871
static constexpr UE_FORCEINLINE_HINT T Square(const T A)
Definition UnrealMathUtility.h:578