MATLAB ヘルプ センター
Get scenario or static attribute of actor
Since R2022a
staticAttr = get(actorSim,"ActorModel")
scenario = get(actorSim,"ScenarioSimulation")
staticAttr = get(actorSim,"ActorModel") gets the static attributes of the actor specified by actorSim.
staticAttr
actorSim
example
scenario = get(actorSim,"ScenarioSimulation") gets the scenario simulation containing the actor specified by actorSim.
scenario
collapse all
Create sim, a ScenarioSimulation object.
sim
ScenarioSimulation
rrApp = roadrunner("C:\Project\TestHighwayRoute"); openScenario(rrApp,"myScenario1"); sim = createSimulation(rrApp);
Start the simulation.
set(sim,"SimulationCommand","Start");
Pause the simulation.
set(sim,"SimulationCommand","Pause");
Retrieve all actors from the simulation.
actorsim = get(sim,"ActorSimulation");
Get the first actor in the list.
actorOne = actorsim{1};
Get the static specifications of actorOne.
actorOne
staticAttr = get(actorOne,"ActorModel")
Get the simulation containing actorOne.
scenario = get(actorOne,"ScenarioSimulation")
ActorSimulation
Actor, specified as an ActorSimulation object.
ActorModel
Static attributes of actor, returned as an ActorModel object.
Scenario simulation containing actor, returned as a ScenarioSimulation object.
Introduced in R2022a
ActorSimulation | ActorModel | ScenarioSimulation
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.
Web サイトの選択
Web サイトを選択すると、翻訳されたコンテンツにアクセスし、地域のイベントやサービスを確認できます。現在の位置情報に基づき、次のサイトの選択を推奨します:
また、以下のリストから Web サイトを選択することもできます。
最適なサイトパフォーマンスの取得方法
中国のサイト (中国語または英語) を選択することで、最適なサイトパフォーマンスが得られます。その他の国の MathWorks のサイトは、お客様の地域からのアクセスが最適化されていません。
南北アメリカ
ヨーロッパ
アジア太平洋地域
最寄りの営業オフィスへのお問い合わせ