MCPcopy Create free account
hub / github.com/PCGEx/PCGExtendedToolkit / MakeDirection

Function MakeDirection

Source/PCGExtendedToolkit/Private/PCGExMath.cpp:172–190  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

170 }
171
172 FQuat MakeDirection(const EPCGExAxis Dir, const FVector& InForward)
173 {
174 switch (Dir)
175 {
176 default:
177 case EPCGExAxis::Forward:
178 return FRotationMatrix::MakeFromX(InForward * -1).ToQuat();
179 case EPCGExAxis::Backward:
180 return FRotationMatrix::MakeFromX(InForward).ToQuat();
181 case EPCGExAxis::Right:
182 return FRotationMatrix::MakeFromY(InForward * -1).ToQuat();
183 case EPCGExAxis::Left:
184 return FRotationMatrix::MakeFromY(InForward).ToQuat();
185 case EPCGExAxis::Up:
186 return FRotationMatrix::MakeFromZ(InForward * -1).ToQuat();
187 case EPCGExAxis::Down:
188 return FRotationMatrix::MakeFromZ(InForward).ToQuat();
189 }
190 }
191
192 FQuat MakeDirection(const EPCGExAxis Dir, const FVector& InForward, const FVector& InUp)
193 {

Callers 10

CollapseCrossingMethod · 0.85
ProcessSinglePointMethod · 0.85
PrepareSinglePointMethod · 0.85
PrepareSinglePointMethod · 0.85
AdvanceMethod · 0.85
ComputeOrientationMethod · 0.85
LookAtAxisMethod · 0.85
LookAtDirectionMethod · 0.85
LookAtPositionMethod · 0.85
ComputeOrientationMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected