sim3d.person.Pedestrian
Description
Use the sim3d.person.Pedestrian object to create a pedestrian that follows
      ground in the 3D environment. After you create a sim3d.person.Pedestrian object, you
      can modify aspects of the pedestrian actor by setting property values.
Creation
Description
person = sim3d.person.Pedestrian()
person = sim3d.person.Pedestrian(Name=Value)Translation to [1 2
            0].
Name-Value Arguments
Specify optional pairs of arguments as
      Name1=Value1,...,NameN=ValueN, where Name is
      the argument name and Value is the corresponding value.
      Name-value arguments must appear after other arguments, but the order of the
      pairs does not matter.
    
Example: person =
            sim3d.person.Pedestrian(ActorName="Pedestrian",PedestrianType="male_02")
Name of actor, specified as a character array or string. If you do not specify an actor name,
                                    then the software assigns the actor an autogenerated name. Use
                                    this argument to set the name of the
                                                sim3d.person.Pedestrian object.
Note
If you specify the same name as an actor that already exists, then the software appends actor name you specify with a unique identifier.
Type of pedestrian, specified as one of these options:
- "male_01"
- "male_02"
- "male_03"
- "female_01"
- "female_02"
- "female_03"
- "child"
Example: PedestrianType="male_02"
Data Types: string
Semantic segmentation map of object class identifiers, specified as real positive scalar. For a complete list of actor IDs and their corresponding object descriptions, see Labels.
Since R2025a
Coordinate system that the actor uses for translation and rotation in the 3D environment, specified as one of these listed values:
- 'Default'– World coordinate system
- 'MATLAB'– MATLAB® coordinate system
- 'ISO8855'– ISO 8855 standard coordinate system
- 'AERO'– SAE coordinate system
- 'VRML'– X3D ISO standard coordinate system
- 'SAE'– SAE coordinate system
For more details on the different coordinate systems, see Coordinate Systems in Simulink 3D Animation.
Data Types: string
Relative translation
                  (x,y,z) of the actor
                object to its parent actor, specified as a real 1-by-3 vector, in m. Use this
                argument to set the initial translation of the pedestrian in the 3D environment
                along the X, Y, and Z
                axes. The CoordinateSystem value specifies how
                  Translation is applied. When you add an actor to the 3D
                environment, the default parent actor is the Scene Origin at
                  (0,0,0).
Example: Translation=[3 4 3]
Note
The sim3d.person.Pedestrian object implements an actor that follows the ground. Use
            X, Y, and Yaw properties
        to move the actor in the 3D environment. The actor object then determines the corresponding
        elevation, pitch, and roll by sensing the ground terrain.
Data Types: double
Relative rotation (roll,
                  pitch, yaw) of the actor object to its
                parent actor, specified as a real 1-by-3 vector, in rad. Use this argument to set
                the initial rotation of the pedestrian in the 3D environment along the
                  X, Y, and Z axes.
                The CoordinateSystem value specifies how
                  Rotation is applied.
Example: Rotation=[0 0 pi/4]
Note
The sim3d.person.Pedestrian object implements an actor that follows the ground. Use
            X, Y, and Yaw properties
        to move the actor in the 3D environment. The actor object then determines the corresponding
        elevation, pitch, and roll by sensing the ground terrain.
Data Types: double
Output Arguments
Actor object, returned as a sim3d.person.Pedestrian object.
Properties
All the properties are run-time configurable.
Parent of actor, specified as a handle to the parent actor object. After you add an actor to
            the sim3d.World object, the default parent actor is the
                Scene Origin at (0,0,0). Use this property to
            set any actor in the 3D environment as the parent actor of a
                sim3d.person.Pedestrian object.
This property is read-only.
Children of actor, specified as a structure.
                                                  Each field of the structure contains a handle to
                                                  the child of a sim3d.person.Pedestrian
                                                  object.
Parent world, specified as a handle to the parent sim3d.World
            object. You can use this property only if the sim3d.person.Pedestrian object is
            added to the parent sim3d.World object.
Type of pedestrian, specified as one of these options:
- "male_01"
- "male_02"
- "male_03"
- "female_01"
- "female_02"
- "female_03"
- "child"
Example: PedestrianType="male_02"
Dependencies
This property is not run-time configurable.
Data Types: string
Since R2025a
Coordinate system that the actor uses for translation and rotation in the 3D environment, specified as one of these listed values:
- 'Default'– World coordinate system
- 'MATLAB'– MATLAB coordinate system
- 'ISO8855'– ISO 8855 standard coordinate system
- 'AERO'– SAE coordinate system
- 'VRML'– X3D ISO standard coordinate system
- 'SAE'– SAE coordinate system
For more details on the different coordinate systems, see Coordinate Systems in Simulink 3D Animation.
Data Types: string
Longitudinal position of the actor along the X-axis of the scene,
            specified as scalar, in m. Use this property to move the actor along the
                X-axis of the scene. The CoordinateSystem
            value specifies how X is applied.
Lateral position of the actor along the Y-axis of the scene, specified as
            scalar, in m. Use this property to move the actor along the Y-axis
            of the scene. The CoordinateSystem value specifies how
                Y is applied.
Yaw orientation angle of the actor along the Z-axis of the scene,
            specified as scalar, in rad. Use this property to rotate the actor along the
                Z-axis of the scene. The CoordinateSystem
            value specifies how Yaw is applied.
Examples
Since R2025a
Create a pedestrian in the 3D environment using the sim3d.person.Pedestrian object.
Create a 3D environment and set up communication with the Unreal Engine simulation environment using the output function OutputImpl. The sim3d.World object can send data about the 3D environment to the Unreal Engine at each simulation step using output function. Before the Unreal Engine simulates, MATLAB calls the output function and sends data to the Unreal Engine. Then, the Unreal Engine executes at each time step and sends data to MATLAB.
If the scene is not available, install the scene as described in the Scene name parameter of the Simulation 3D Scene Configuration block and then set the Scene argument.
world = sim3d.World(Scene="Curved road",Output=@OutputImpl);Create a pedestrian using sim3d.person.Pedestrian object and add the pedestrian to the world.
person = sim3d.person.Pedestrian(ActorName="Pedestrian");
add(world,person);Run the co-simulation.
sampletime = 0.02; stoptime = 10; run(world,sampletime,stoptime);
Output Function
The output function sends data about the actor to the Unreal Engine environment at each simulation step. For this example, the function moves the Pedestrian along X-axis by updating the X property of the Pedestrian at each simulation step.
function OutputImpl(world) world.Actors.Pedestrian.X = world.Actors.Pedestrian.X + 0.005; end
Version History
Introduced in R2024bSet the CoordinateSystem argument and
    property of the sim3d.person.Pedestrian object to represent the coordinate system for actor
    transformation in the 3D environment.
See Also
sim3d.World | sim3d.Actor | add | run | Simulation 3D
        Pedestrian
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
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)