Main Content

Coordinate Systems for Unreal Engine Simulation in UAV Toolbox

UAV Toolbox enables you to simulate your UAV scenario in a virtual environment that uses the Unreal Engine® from Epic Games®.

Note

Simulating models in the 3D visualization environment requires Simulink® 3D Animation™.

UAV Toolbox uses these coordinate systems to position objects in the Unreal Engine visualization environment.

Unreal Engine World Coordinate System

The simulation environment uses a right-handed Cartesian world coordinate system. In this coordinate system:

  • When facing the positive X-axis, the positive Y-axis points to the left.

  • The positive Z-axis points upward from the ground.

  • Yaw, pitch, and roll angles have clockwise-positive directions when looking in the positive directions of the Z-, Y-, and X-axes, respectively.

Note

The Unreal Editor uses a left-handed world Cartesian coordinate system in which the positive Y-axis points right with respect to the positive X-axis. If you are converting from the Unreal Editor coordinate system to the coordinate system of the 3D environment, you must reverse the signs of the Y-axis, pitch angle, and yaw angle.

World coordinate system is fixed and centered on the Unreal Engine scene origin.

This figure illustrates how the Simulation 3D UAV Vehicle block uses this coordinate system to determine the UAV location and orientation in the US City Block scene. The Translation inputs specifies the position of each UAV relative to the scene origin, and the Rotation input specifies the orientation of the vehicle frame of each UAV relative to the world coordinate system.

Red, green, and blue UAVs placed in the unreal world scene. The red UAV has translation coordinates of [150, 25, 30], The green UAV has translation coordinates of [-50 100 30], and the blue UAV has translation coordinates of [-150 --50 30].

Vehicle Coordinate System

The vehicle coordinate system is based on the world coordinate system, and is fixed to the UAV. In this coordinate system:

  • The X-axis points forward from the vehicle.

  • The Y-axis points to the left of the vehicle.

  • The Z-axis points up from the ground.

  • Roll, pitch, and yaw are clockwise-positive when looking in the forward direction of the X-, Y-, and Z-axes, respectively.

UAV Toolbox uses the frame rotation angles between the world and vehicle frame in a ZYX (yaw-pitch-roll) rotation sequence to determine the orientation of the UAV.

The vehicle coordinate system also defines the relative translation for sensor mounting. For example, a relative translation of [1 0 2] places the sensor 1 meter ahead of, and 2 meters above the origin of the UAV.

This figure illustrates the vehicle coordinate system of a Quadrotor vehicle.

X-, Y-, and Z-axes of a UAV, and the respective roll, pitch, and yaw rotations around them.

See Also

|

Topics