MCPcopy Create free account
hub / github.com/URLab-Sim/UnrealRoboticsLab / MjToUEPosition

Method MjToUEPosition

Source/URLab/Private/MuJoCo/Utils/MjUtils.cpp:29–37  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

27#include "XmlNode.h"
28
29FVector MjUtils::MjToUEPosition(const double* pos)
30{
31 // MuJoCo (Right-handed, Z-up) -> UE (Left-handed, Z-up)
32 // scale: 1 unit -> 100 cm
33 // Axis: X->X, Y->-Y, Z->Z
34 if (!pos)
35 return FVector::ZeroVector;
36 return FVector(pos[0] * 100.0, pos[1] * -100.0, pos[2] * 100.0);
37}
38
39FVector MjUtils::MjToUEPosition(const float* pos)
40{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected