Simulation 3D Actor Transform Set
Libraries:
Vehicle Dynamics Blockset /
Vehicle Scenarios /
Sim3D /
Sim3D Core
Aerospace Blockset /
Animation /
Simulation 3D
Description
Note
Simulating models with the Simulation 3D Actor Transform Set block requires Simulink^{®} 3D Animation™. If you had an Aerospace Blockset™ license prior to R2024a, you might be eligible to continue using Simulation 3D Actor Transform Set to simulate models in the 3D environment. For more information, see Opt-In Offer for Aerospace Blockset Unreal Engine Visualization Users.
The Simulation 3D Actor Transform Set block sets the actor translation, rotation, and scale in the 3D visualization environment.
The block uses a vehicle-fixed coordinate system that is initially aligned with the inertial world coordinate system.
Axis | Description |
---|---|
X | Forward direction of the vehicle Roll — Right-handed rotation about X-axis |
Y | Extends to the right of the vehicle, initially parallel to the ground plane Pitch — Right-handed rotation about Y-axis |
Z | Extends upwards Yaw — Left-handed rotation about Z-axis |
Actors are scene objects that support 3D translation, rotation, and scale. Parts are actor components. Components do not exist by themselves; they are associated with an actor.
Tip
Verify that the Simulation 3D Actor Transform Set block executes before the Simulation 3D Scene Configuration block. That way, Simulation 3D Actor Transform Set prepares the signal data before the Unreal Engine^{®} 3D visualization environment receives it. To check the block execution order, right-click the blocks and select Properties. On the General tab, confirm these Priority settings:
Simulation 3D Scene Configuration —
0
Simulation 3D Actor Transform Set —
-1
For more information about execution order, see Control and Display Execution Order.
Ports
Input
Translation — Actor translation
array
Actor translation, in m. Array dimensions are number of parts per
actor-by-3
.
Translation(1,1)
,Translation(1,2)
, andTranslation(1,3)
— Vehicle displacement along world X-, Y, and Z- axes, respectively.Translation(...,1)
,Translation(...,2)
, andTranslation(...,3)
— Actor displacement relative to vehicle, in vehicle-fixed coordinate system initially aligned with world X-, Y, and Z- axes, respectively.
For example, consider a vehicle actor with a vehicle body and four wheels. The
Translation
signal:
Dimensions are
[5x3]
.Contains translation information according to the axle and wheel locations, relative to vehicle.
$$Translation=\left[\begin{array}{ccc}{X}_{v}& {Y}_{v}& {Z}_{v}\\ {X}_{FL}& {Y}_{FL}& {Z}_{FL}\\ {X}_{FR}& {Y}_{FR}& {Z}_{FR}\\ {X}_{RL}& {Y}_{RL}& {Z}_{RL}\\ {X}_{RR}& {Y}_{RR}& {Z}_{RR}\end{array}\right]$$
Translation Array Element Vehicle, X_{v}
Translation(1,1)
Vehicle, Y_{v}
Translation(1,2)
Vehicle, Z_{v}
Translation(1,3)
Front left wheel, X_{FL}
Translation(2,1)
Front left wheel, Y_{FL}
Translation(2,2)
Front left wheel, Z_{FL}
Translation(2,3)
Front right wheel, X_{FR}
Translation(3,1)
Front right wheel, Y_{FR}
Translation(3,2)
Front right wheel, Z_{FR}
Translation(3,3)
Rear left wheel, X_{RL}
Translation(4,1)
Rear left wheel, Y_{RL}
Translation(4,2)
Rear left wheel, Z_{RL}
Translation(4,3)
Rear right wheel, X_{RR}
Translation(5,1)
Rear right wheel, Y_{RR}
Translation(5,2)
Rear right wheel, Z_{RR}
Translation(5,3)
Rotation — Actor rotation
array
Actor rotation across a [-pi/2, pi/2] range, in rad. Array dimensions are number of parts
per actor-by-3
.
Rotation(1,1)
,Rotation(1,2)
, andRotation(1,3)
— Vehicle rotation about vehicle-fixed pitch, roll, and yaw Y-, Z-, and X- axes, respectively.Rotation(...,1)
,Rotation(...,2)
, andRotation(...,3)
— Actor rotation about vehicle-fixed pitch, roll, and yaw Y-, X-, and Z- axes, respectively.
For example, consider a vehicle actor with a vehicle body and four wheels. The
Rotation
signal:
Dimensions are
[5x3]
.Contains rotation information according to the axle and wheel locations.
$$Rotation=\left[\begin{array}{ccc}Pitc{h}_{v}& Rol{l}_{v}& Ya{w}_{v}\\ Pitc{h}_{FL}& Rol{l}_{FL}& Ya{w}_{FL}\\ Pitc{h}_{FR}& Rol{l}_{FR}& Ya{w}_{FR}\\ Pitc{h}_{RL}& Rol{l}_{RL}& Ya{w}_{RL}\\ Pitc{h}_{RR}& Rol{l}_{RR}& Ya{w}_{RR}\end{array}\right]$$
Rotation Array Element Vehicle, Pitch_{v}
Rotation(1,1)
Vehicle, Roll_{v}
Rotation(1,2)
Vehicle, Yaw_{v}
Rotation(1,3)
Front left wheel, Pitch_{FL}
Rotation(2,1)
Front left wheel, Roll_{FL}
Rotation(2,2)
Front left wheel, Yaw_{FL}
Rotation(2,3)
Front right wheel, Pitch_{FR}
Rotation(3,1)
Front right wheel, Roll_{FR}
Rotation(3,2)
Front right wheel, Yaw_{FR}
Rotation(3,3)
Rear left wheel, Pitch_{RL}
Rotation(4,1)
Rear left wheel, Roll_{RL}
Rotation(4,2)
Rear left wheel, Yaw_{RL}
Rotation(4,3)
Rear right wheel, Pitch_{RR}
Rotation(5,1)
Rear right wheel, Roll_{RR}
Rotation(5,2)
Rear right wheel, Yaw_{RR}
Rotation(5,3)
Scale — Actor scale
array
Actor scale. Array dimensions are number of parts per actor-by-3
.
Scale(1,1)
,Scale(1,2)
, andScale(1,3)
— Vehicle scale along world X-, Y-, and Z- axes, respectively.Scale(...,1)
,Scale(...,2)
, andScale(...,3)
— Actor scale along world X-, Y-, and Z- axes, respectively.
For example, consider a vehicle actor with a vehicle body and four wheels. The
Scale
signal:
Dimensions are
[5x3]
.Contains scale information according to the axle and wheel locations.
$$Scale=\left[\begin{array}{ccc}{X}_{{V}_{scale}}& {Y}_{{V}_{scale}}& {Z}_{{V}_{scale}}\\ {X}_{F{L}_{scale}}& {Y}_{F{L}_{scale}}& {Z}_{F{L}_{scale}}\\ {X}_{F{R}_{scale}}& {Y}_{F{R}_{scale}}& {Z}_{F{R}_{scale}}\\ {X}_{R{L}_{scale}}& {Y}_{R{L}_{scale}}& {Z}_{R{L}_{scale}}\\ {X}_{R{R}_{scale}}& {Y}_{R{R}_{scale}}& {Z}_{R{R}_{scale}}\end{array}\right]$$
Scale Array Element Vehicle, X_{vscale}
Scale(1,1)
Vehicle, Y_{vscale}
Scale(1,2)
Vehicle, Z_{vscale}
Scale(1,3)
Front left wheel, X_{FLscale}
Scale(2,1)
Front left wheel, Y_{FLscale}
Scale(2,2)
Front left wheel, Z_{FLscale}
Scale(2,3)
Front right wheel, X_{FRscale}
Scale(3,1)
Front right wheel, Y_{FRscale}
Scale(3,2)
Front right wheel, Z_{FRscale}
Scale(3,3)
Rear left wheel, X_{RLscale}
Scale(4,1)
Rear left wheel, Y_{RLscale}
Scale(4,2)
Rear left wheel, Z_{RLscale}
Scale(4,3)
Rear right wheel, X_{RRscale}
Scale(5,1)
Rear right wheel, Y_{RRscale}
Scale(5,2)
Rear right wheel, Z_{RRscale}
Scale(5,3)
Parameters
Tag for actor in 3D scene, ActorTag — Name
SimulinkActor1
(default) | character vector
Actor name.
Actors are scene objects that support 3D translation, rotation, and scale. Parts are actor components. Components do not exist by themselves; they are associated with an actor.
The block does not support multiple instances of the same actor tag. To refer to the same scene actor when you use the 3D block pairs (e.g. Simulation 3D Actor Transform Get and Simulation 3D Actor Transform Set), specify the same Tag for actor in 3D scene, ActorTag parameter.
Number of parts per actor to set, NumberOfParts — Name
1
(default) | scalar
Number of parts per actor. Actors are scene objects that support 3D translation, rotation, and scale. Parts are actor components. Components do not exist by themselves; they are associated with an actor. Typically, a vehicle actor with a body and four wheels has 5 parts.
The block does not support multiple instances of the same actor tag. To refer to the same scene actor when you use the 3D block pairs (e.g. Simulation 3D Actor Transform Get and Simulation 3D Actor Transform Set), specify the same Tag for actor in 3D scene, ActorTag parameter.
Initial array values to translate actor per part, Translation — Actor initial position
[0 0 0]
(default) | array
Actor initial position, along world X-, Y-, and Z- axes, in m.
Array dimensions are number of parts per actor-by-3
.
Translation(1,1)
,Translation(1,2)
, andTranslation(1,3)
— Vehicle displacement along world X-, Y, and Z- axes, respectively.Translation(...,1)
,Translation(...,2)
, andTranslation(...,3)
— Actor displacement relative to vehicle, in vehicle-fixed coordinate system initially aligned with world X-, Y, and Z- axes, respectively.
For example, consider a vehicle actor with a vehicle body and four wheels. The parameter:
Dimensions are
[5x3]
.Contains translation information according to the axle and wheel locations, relative to vehicle.
$$Translation=\left[\begin{array}{ccc}{X}_{v}& {Y}_{v}& {Z}_{v}\\ {X}_{FL}& {Y}_{FL}& {Z}_{FL}\\ {X}_{FR}& {Y}_{FR}& {Z}_{FR}\\ {X}_{RL}& {Y}_{RL}& {Z}_{RL}\\ {X}_{RR}& {Y}_{RR}& {Z}_{RR}\end{array}\right]$$
Translation Array Element Vehicle, X_{v}
Translation(1,1)
Vehicle, Y_{v}
Translation(1,2)
Vehicle, Z_{v}
Translation(1,3)
Front left wheel, X_{FL}
Translation(2,1)
Front left wheel, Y_{FL}
Translation(2,2)
Front left wheel, Z_{FL}
Translation(2,3)
Front right wheel, X_{FR}
Translation(3,1)
Front right wheel, Y_{FR}
Translation(3,2)
Front right wheel, Z_{FR}
Translation(3,3)
Rear left wheel, X_{RL}
Translation(4,1)
Rear left wheel, Y_{RL}
Translation(4,2)
Rear left wheel, Z_{RL}
Translation(4,3)
Rear right wheel, X_{RR}
Translation(5,1)
Rear right wheel, Y_{RR}
Translation(5,2)
Rear right wheel, Z_{RR}
Translation(5,3)
Initial array values to rotate actor per part, Rotation — Actor initial rotation
[0 0 0]
(default) | array
Actor initial rotation about world X-, Y-, and Z- axes across a [-pi/2, pi/2] range, in rad.
Array dimensions are number of parts per actor-by-3
.
Rotation(1,1)
,Rotation(1,2)
, andRotation(1,3)
— Vehicle rotation about vehicle-fixed pitch, roll, and yaw Y-, Z-, and X- axes, respectively.Rotation(...,1)
,Rotation(...,2)
, andRotation(...,3)
— Actor rotation about vehicle-fixed pitch, roll, and yaw Y-, Z-, and X- axes, respectively.
For example, consider a vehicle actor with a vehicle body and four wheels. The parameter:
Dimensions are
[5x3]
.Contains rotation information according to the axle and wheel locations.
$$Rotation=\left[\begin{array}{ccc}Pitc{h}_{v}& Rol{l}_{v}& Ya{w}_{v}\\ Pitc{h}_{FL}& Rol{l}_{FL}& Ya{w}_{FL}\\ Pitc{h}_{FR}& Rol{l}_{FR}& Ya{w}_{FR}\\ Pitc{h}_{RL}& Rol{l}_{RL}& Ya{w}_{RL}\\ Pitc{h}_{RR}& Rol{l}_{RR}& Ya{w}_{RR}\end{array}\right]$$
Rotation Array Element Vehicle, Pitch_{v}
Rotation(1,1)
Vehicle, Roll_{v}
Rotation(1,2)
Vehicle, Yaw_{v}
Rotation(1,3)
Front left wheel, Pitch_{FL}
Rotation(2,1)
Front left wheel, Roll_{FL}
Rotation(2,2)
Front left wheel, Yaw_{FL}
Rotation(2,3)
Front right wheel, Pitch_{FR}
Rotation(3,1)
Front right wheel, Roll_{FR}
Rotation(3,2)
Front right wheel, Yaw_{FR}
Rotation(3,3)
Rear left wheel, Pitch_{RL}
Rotation(4,1)
Rear left wheel, Roll_{RL}
Rotation(4,2)
Rear left wheel, Yaw_{RL}
Rotation(4,3)
Rear right wheel, Pitch_{RR}
Rotation(5,1)
Rear right wheel, Roll_{RR}
Rotation(5,2)
Rear right wheel, Yaw_{RR}
Rotation(5,3)
Initial array values to scale actor per part, Scale — Actor initial scale
[1 1 1]
(default) | array
Actor initial scale.
Array dimensions are number of number of parts per actor-by-3
.
Scale(1,1)
,Scale(1,2)
, andScale(1,3)
— Vehicle scale along world X-, Y, and Z- axes, respectively.Scale(...,1)
,Scale(...,2)
, andScale(...,3)
— Actor scale along world X-, Y, and Z- axes, respectively.
For example, consider a vehicle actor with a vehicle body and four wheels. The parameter:
Dimensions are
[5x3]
.Contains scale information according to the axle and wheel locations.
$$Scale=\left[\begin{array}{ccc}{X}_{{V}_{scale}}& {Y}_{{V}_{scale}}& {Z}_{{V}_{scale}}\\ {X}_{F{L}_{scale}}& {Y}_{F{L}_{scale}}& {Z}_{F{L}_{scale}}\\ {X}_{F{R}_{scale}}& {Y}_{F{R}_{scale}}& {Z}_{F{R}_{scale}}\\ {X}_{R{L}_{scale}}& {Y}_{R{L}_{scale}}& {Z}_{R{L}_{scale}}\\ {X}_{R{R}_{scale}}& {Y}_{R{R}_{scale}}& {Z}_{R{R}_{scale}}\end{array}\right]$$
Scale Array Element Scale Axis Vehicle, X_{vscale}
Scale(1,1)
World X-axis Vehicle, Y_{vscale}
Scale(1,2)
World Y-axis Vehicle, Z_{vscale}
Scale(1,3)
World Z-axis Front left wheel, X_{FLscale}
Scale(2,1)
World X-axis Front left wheel, Y_{FLscale}
Scale(2,2)
World Y-axis Front left wheel, Z_{FLscale}
Scale(2,3)
World Z-axis Front right wheel, X_{FRscale}
Scale(3,1)
World X-axis Front right wheel, Y_{FRscale}
Scale(3,2)
World Y-axis Front right wheel, Z_{FRscale}
Scale(3,3)
World Z-axis Rear left wheel, X_{RLscale}
Scale(4,1)
World X-axis Rear left wheel, Y_{RLscale}
Scale(4,2)
World Y-axis Rear left wheel, Z_{RLscale}
Scale(4,3)
World Z-axis Rear right wheel, X_{RRscale}
Scale(5,1)
World X-axis Rear right wheel, Y_{RRscale}
Scale(5,2)
World Y-axis Rear right wheel, Z_{RRscale}
Scale(5,3)
World Z-axis
Sample time — Sample time
-1
(default) | scalar
Sample time, T_{s}. The graphics frame rate is the inverse of the sample time.
Version History
Introduced in R2021bR2024a: Requires Simulink 3D Animation
Simulating models with the Simulation 3D Actor Transform Set block requires Simulink 3D Animation. If you had an Aerospace Blockset license prior to R2024a, you might be eligible to continue using Simulation 3D Actor Transform Set to simulate models in the 3D environment. For more information, see Opt-In Offer for Aerospace Blockset Unreal Engine Visualization Users.
MATLAB 명령
다음 MATLAB 명령에 해당하는 링크를 클릭했습니다.
명령을 실행하려면 MATLAB 명령 창에 입력하십시오. 웹 브라우저는 MATLAB 명령을 지원하지 않습니다.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)