Right-Handed vs Left-Handed Coordinates

Right-Handed vs Left-Handed Coordinates

The Unity rendering system uses left-handed (LH) coordinates. The standard representation in physics is to use right-handed (RH) coordinates. If the direct physics values from a RH representation are rendered “as-is” in Unity the orbits will look wrong. Wrong how? That depends on where the camera is located. If the camera is located so that the XY plane is horizontal and we want the orbit evolution to move counter-clockwise then the camera needs to be located at a negative z value. The result is an orbit that looks about right BUT the an inclined orbit begins by moving to positive z values in physics space given a \(-z\) located camera will appear to be the descending node when it is in fact the ascending node.

This can be seen in the RightHandedvsLeftDisplay in the going further demo scene folder.

By contrast the GSDisplay with XZ Orbits selected maps the physics coordinates \((x, y, z)\) to display coordinates \((x, z, y)\). When rendered in the Unity left-handed coordinates (with the camera at +Y to be above the XZ orbit plane) the orbit now looks correct. Note that internally the GECore always uses RH coordinates. The XZ flip only occurs in the display code.

Right-Hand versus Left-Hand Orbits