Open 3D Engine ROS2 Gem API Reference
24.09
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
|
#include <SimulationTimeSource.h>
Inherits ROS2::ITimeSource.
Public Member Functions | |
virtual void | Activate () override |
virtual void | Deactivate () override |
virtual builtin_interfaces::msg::Time | GetROSTimestamp () const override |
The SimulationTimeSource provides timestamps calculated using updates from the physics engine. Simulation paces the clock with stable steps, and as a result, this time source eliminates data jitter. The simulated time can be faster or slower than the real-time, according to the configuration of the physics engine. SimulationTimeSource is used as the default time source for the projects. The simulated clock is incremented with delta times that were simulated by physics. The time source registers and observes AZ::PhysicsScene and when the simulation starts, it attaches and starts counting the updates. It is recommended to use it with high-frequency sensors such as odometry and IMUs.
|
overridevirtual |
Get ROS 2 time as ROS2 message.
Implements ROS2::ITimeSource.