esp::sim::Simulator class

Constructors, destructors, conversion operators

Simulator(const SimulatorConfiguration& cfg) explicit
~Simulator() virtual
Simulator() protected

Public functions

void close() virtual
Closes the simulator and frees all loaded assets and GPU contexts.
void reconfigure(const SimulatorConfiguration& cfg) virtual
void reset() virtual
void seed(uint32_t newSeed) virtual
auto getRenderer() -> std::shared_ptr<gfx::Renderer>
auto getSemanticScene() -> std::shared_ptr<scene::SemanticScene>
auto getActiveSceneGraph() -> scene::SceneGraph&
auto getActiveSemanticSceneGraph() -> scene::SceneGraph&
void saveFrame(const std::string& filename)
auto gpuDevice() const -> int
The ID of the CUDA device of the OpenGL context owned by the simulator. This will only be nonzero if the simulator is built in –headless mode on linux.
auto getAssetAttributesManager() const -> const AttrMgrs::AssetAttributesManager::ptr
Return manager for construction and access to asset attributes.
auto getObjectAttributesManager() const -> const AttrMgrs::ObjectAttributesManager::ptr
Return manager for construction and access to object attributes.
auto getPhysicsAttributesManager() const -> const AttrMgrs::PhysicsAttributesManager::ptr
Return manager for construction and access to physics world attributes.
auto getSceneAttributesManager() const -> const AttrMgrs::SceneAttributesManager::ptr
Return manager for construction and access to scene attributes.
auto getPhysicsSimulationLibrary() const -> const esp::physics::PhysicsManager::PhysicsSimulationLibrary&
Return the library implementation type for the simulator currently in use. Use to check for a particular implementation.
auto addObject(int objectLibIndex, scene::SceneNode* attachmentNode = nullptr, const std::string& lightSetupKey = assets::ResourceManager::DEFAULT_LIGHTING_KEY, int sceneID = 0) -> int
Instance an object from a template index in esp::assets::ResourceManager::physicsObjectLibrary_. See esp::physics::PhysicsManager::addObject().
auto addObjectByHandle(const std::string& objectLibHandle, scene::SceneNode* attachmentNode = nullptr, const std::string& lightSetupKey = assets::ResourceManager::DEFAULT_LIGHTING_KEY, int sceneID = 0) -> int
Instance an object from a template index in esp::assets::ResourceManager::physicsObjectLibrary_. See esp::physics::PhysicsManager::addObject().
auto getObjectInitializationTemplate(int objectId, const int sceneID = 0) const -> const assets::PhysicsObjectAttributes::cptr
Get a static view of a physics object's template when the object was instanced.
void removeObject(const int objectID, bool deleteObjectNode = true, bool deleteVisualNode = true, const int sceneID = 0)
Remove an instanced object by ID. See esp::physics::PhysicsManager::removeObject().
auto getExistingObjectIDs(const int sceneID = 0) -> std::vector<int>
Get the IDs of the physics objects instanced in a physical scene. See esp::physics::PhysicsManager::getExistingObjectIDs.
auto getObjectMotionType(const int objectID, const int sceneID = 0) -> esp::physics::MotionType
Get the esp::physics::MotionType of an object. See esp::physics::PhysicsManager::getExistingObjectIDs.
auto setObjectMotionType(const esp::physics::MotionType& motionType, const int objectID, const int sceneID = 0) -> bool
Set the esp::physics::MotionType of an object. See esp::physics::PhysicsManager::getExistingObjectIDs.
auto getObjectVelocityControl(const int objectID, const int sceneID = 0) const -> physics::VelocityControl::ptr
Retrieves a shared pointer to the VelocityControl struct for this object.
void applyTorque(const Magnum::Vector3& tau, const int objectID, const int sceneID = 0)
Apply torque to an object. See esp::physics::PhysicsManager::applyTorque.
void applyForce(const Magnum::Vector3& force, const Magnum::Vector3& relPos, const int objectID, const int sceneID = 0)
Apply force to an object. See esp::physics::PhysicsManager::applyForce.
auto getObjectSceneNode(const int objectID, const int sceneID = 0) -> scene::SceneNode*
Get a reference to the object's scene node or nullptr if failed.
auto getObjectVisualSceneNodes(const int objectID, const int sceneID = 0) -> std::vector<scene::SceneNode*>
Get references to the object's visual scene nodes or empty if failed.
auto getTransformation(const int objectID, const int sceneID = 0) -> Magnum::Matrix4
Get the current 4x4 transformation matrix of an object. See esp::physics::PhysicsManager::getTransformation.
void setTransformation(const Magnum::Matrix4& transform, const int objectID, const int sceneID = 0)
Set the 4x4 transformation matrix of an object kinematically. See esp::physics::PhysicsManager::setTransformation.
auto getRigidState(const int objectID, const int sceneID = 0) const -> esp::core::RigidState
Get the current esp::core::RigidState of an object.
void setRigidState(const esp::core::RigidState& rigidState, const int objectID, const int sceneID = 0)
Set the esp::core::RigidState of an object kinematically.
void setTranslation(const Magnum::Vector3& translation, const int objectID, const int sceneID = 0)
Set the 3D position of an object kinematically. See esp::physics::PhysicsManager::setTranslation.
auto getTranslation(const int objectID, const int sceneID = 0) -> Magnum::Vector3
Get the current 3D position of an object. See esp::physics::PhysicsManager::getTranslation.
void setRotation(const Magnum::Quaternion& rotation, const int objectID, const int sceneID = 0)
Set the orientation of an object kinematically. See esp::physics::PhysicsManager::setRotation.
auto getRotation(const int objectID, const int sceneID = 0) -> Magnum::Quaternion
Get the current orientation of an object. See esp::physics::PhysicsManager::getRotation.
void setLinearVelocity(const Magnum::Vector3& linVel, const int objectID, const int sceneID = 0)
Set the Linear Velocity of object. See esp::phyics::PhysicsManager::setLinearVelocity.
auto getLinearVelocity(const int objectID, const int sceneID = 0) -> Magnum::Vector3
Get the Linear Velocity of object. See esp::physics::PhysicsManager::getLinearVelocity.
void setAngularVelocity(const Magnum::Vector3& angVel, const int objectID, const int sceneID = 0)
Set the Angular Velocity of object. See esp::phyics::PhysicsManager::setAngularVelocity.
auto getAngularVelocity(const int objectID, const int sceneID = 0) -> Magnum::Vector3
Get the Angular Velocity of object. See esp::physics::PhysicsManager::getAngularVelocity.
void setObjectBBDraw(bool drawBB, const int objectID, const int sceneID = 0)
Turn on/off rendering for the bounding box of the object's visual component.
void setObjectSemanticId(uint32_t semanticId, int objectID, int sceneID = 0)
Set the esp::scene:SceneNode::semanticId_ for all visual nodes belonging to an object.
auto contactTest(const int objectID, const int sceneID = 0) -> bool
Discrete collision check for contact between an object and the collision world.
auto castRay(const esp::geo::Ray& ray, float maxDistance = 100.0, const int sceneID = 0) -> esp::physics::RaycastResults
Raycast into the collision world of a scene.
auto stepWorld(const double dt = 1.0/60.0) -> double
the physical world has a notion of time which passes during animation/simulation/action/etc... Step the physical world forward in time by a desired duration. Note that the actual duration of time passed by this step will depend on simulation time stepping mode (todo). See esp::physics::PhysicsManager::stepPhysics.
auto getWorldTime() -> double
Get the current time in the simulated world. This is always 0 if no esp::physics::PhysicsManager is initialized. See stepWorld. See esp::physics::PhysicsManager::getWorldTime.
void setGravity(const Magnum::Vector3& gravity, const int sceneID = 0)
Set the gravity in a physical scene.
auto getGravity(const int sceneID = 0) const -> Magnum::Vector3
Get the gravity in a physical scene.
auto recomputeNavMesh(nav::PathFinder& pathfinder, const nav::NavMeshSettings& navMeshSettings, bool includeStaticObjects = false) -> bool
Compute the navmesh for the simulator's current active scene and assign it to the referenced nav::PathFinder.
auto setNavMeshVisualization(bool visualize) -> bool
Set visualization of the current NavMesh pathfinder_ on or off.
auto isNavMeshVisualizationActive() -> bool
Query active state of the current NavMesh pathfinder_ visualization.
auto getAgent(int agentId) -> agent::Agent::ptr
auto addAgent(const agent::AgentConfiguration& agentConfig, scene::SceneNode& agentParentNode) -> agent::Agent::ptr
auto addAgent(const agent::AgentConfiguration& agentConfig) -> agent::Agent::ptr
auto displayObservation(int agentId, const std::string& sensorId) -> bool
Displays observations on default frame buffer for a particular sensor of an agent.
auto getAgentObservation(int agentId, const std::string& sensorId, sensor::Observation& observation) -> bool
auto getAgentObservations(int agentId, std::map<std::string, sensor::Observation>& observations) -> int
auto getAgentObservationSpace(int agentId, const std::string& sensorId, sensor::ObservationSpace& space) -> bool
auto getAgentObservationSpaces(int agentId, std::map<std::string, sensor::ObservationSpace>& spaces) -> int
auto getPathFinder() -> nav::PathFinder::ptr
void setPathFinder(nav::PathFinder::ptr pf)
void setFrustumCullingEnabled(bool val)
Enable or disable frustum culling (enabled by default)
auto isFrustumCullingEnabled() -> bool
Get status, whether frustum culling is enabled or not.
auto getLightSetup(const std::string& key = assets::ResourceManager::DEFAULT_LIGHTING_KEY) -> gfx::LightSetup
Get a named LightSetup.
void setLightSetup(gfx::LightSetup lightSetup, const std::string& key = assets::ResourceManager::DEFAULT_LIGHTING_KEY)
Set a named LightSetup.
void setObjectLightSetup(int objectID, const std::string& lightSetupKey, int sceneID = 0)
Set the light setup of an object.
auto random() -> core::Random::ptr
Getter for PRNG.

Protected functions

void sampleRandomAgentState(agent::AgentState& agentState)
sample a random valid AgentState in passed agentState
auto isValidScene(int sceneID) const -> bool
auto sceneHasPhysics(int sceneID) const -> bool

Protected variables

gfx::WindowlessContext::uptr context_
std::shared_ptr<gfx::Renderer> renderer_
std::unique_ptr<assets::ResourceManager> resourceManager_
scene::SceneManager::uptr sceneManager_
int activeSceneID_
int activeSemanticSceneID_
std::vector<int> sceneID_
std::shared_ptr<scene::SemanticScene> semanticScene_
std::shared_ptr<physics::PhysicsManager> physicsManager_
core::Random::ptr random_
SimulatorConfiguration config_
std::vector<agent::Agent::ptr> agents_
nav::PathFinder::ptr pathfinder_
bool frustumCulling_
int navMeshVisPrimID_
NavMesh visualization variables.
esp::scene::SceneNode* navMeshVisNode_

Function documentation

void esp::sim::Simulator::close() virtual

Closes the simulator and frees all loaded assets and GPU contexts.

const esp::physics::PhysicsManager::PhysicsSimulationLibrary& esp::sim::Simulator::getPhysicsSimulationLibrary() const

Return the library implementation type for the simulator currently in use. Use to check for a particular implementation.

Returns The implementation type of this simulator.

int esp::sim::Simulator::addObject(int objectLibIndex, scene::SceneNode* attachmentNode = nullptr, const std::string& lightSetupKey = assets::ResourceManager::DEFAULT_LIGHTING_KEY, int sceneID = 0)

Instance an object from a template index in esp::assets::ResourceManager::physicsObjectLibrary_. See esp::physics::PhysicsManager::addObject().

Parameters
objectLibIndex The index of the object's template in esp::assets::ResourceManager::physicsObjectLibrary_.
attachmentNode If provided, attach the RigidObject Feature to this node instead of creating a new one.
lightSetupKey The string key for the LightSetup to be used by this object.
sceneID !! Not used currently !! Specifies which physical scene to add an object to.
Returns The ID assigned to new object which identifies it in esp::physics::PhysicsManager::existingObjects_ or esp::ID_UNDEFINED if instancing fails.

int esp::sim::Simulator::addObjectByHandle(const std::string& objectLibHandle, scene::SceneNode* attachmentNode = nullptr, const std::string& lightSetupKey = assets::ResourceManager::DEFAULT_LIGHTING_KEY, int sceneID = 0)

Instance an object from a template index in esp::assets::ResourceManager::physicsObjectLibrary_. See esp::physics::PhysicsManager::addObject().

Parameters
objectLibHandle The config/origin handle of the object's template in esp::assets::ResourceManager::physicsObjectLibrary_.
attachmentNode If provided, attach the RigidObject Feature to this node instead of creating a new one.
lightSetupKey The string key for the LightSetup to be used by this object.
sceneID !! Not used currently !! Specifies which physical scene to add an object to.
Returns The ID assigned to new object which identifies it in esp::physics::PhysicsManager::existingObjects_ or esp::ID_UNDEFINED if instancing fails.

const assets::PhysicsObjectAttributes::cptr esp::sim::Simulator::getObjectInitializationTemplate(int objectId, const int sceneID = 0) const

Get a static view of a physics object's template when the object was instanced.

Use this to query the object's properties when it was initialized. Object pointed at by pointer is const, and can not be modified.

void esp::sim::Simulator::removeObject(const int objectID, bool deleteObjectNode = true, bool deleteVisualNode = true, const int sceneID = 0)

Remove an instanced object by ID. See esp::physics::PhysicsManager::removeObject().

Parameters
objectID The ID of the object identifying it in esp::physics::PhysicsManager::existingObjects_.
deleteObjectNode
deleteVisualNode
sceneID !! Not used currently !! Specifies which physical scene to remove the object from.

std::vector<int> esp::sim::Simulator::getExistingObjectIDs(const int sceneID = 0)

Get the IDs of the physics objects instanced in a physical scene. See esp::physics::PhysicsManager::getExistingObjectIDs.

Parameters
sceneID !! Not used currently !! Specifies which physical scene to query.
Returns A vector of ID keys into esp::physics::PhysicsManager::existingObjects_.

esp::physics::MotionType esp::sim::Simulator::getObjectMotionType(const int objectID, const int sceneID = 0)

Get the esp::physics::MotionType of an object. See esp::physics::PhysicsManager::getExistingObjectIDs.

Parameters
objectID The ID of the object identifying it in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene to query.
Returns The esp::physics::MotionType of the object or esp::physics::MotionType::ERROR_MOTIONTYPE if query failed.

bool esp::sim::Simulator::setObjectMotionType(const esp::physics::MotionType& motionType, const int objectID, const int sceneID = 0)

Set the esp::physics::MotionType of an object. See esp::physics::PhysicsManager::getExistingObjectIDs.

Parameters
motionType The desired motion type of the object
objectID The ID of the object identifying it in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene to query.
Returns whether or not the set was successful.

void esp::sim::Simulator::applyTorque(const Magnum::Vector3& tau, const int objectID, const int sceneID = 0)

Apply torque to an object. See esp::physics::PhysicsManager::applyTorque.

Parameters
tau The desired torque to apply.
objectID The ID of the object identifying it in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.

void esp::sim::Simulator::applyForce(const Magnum::Vector3& force, const Magnum::Vector3& relPos, const int objectID, const int sceneID = 0)

Apply force to an object. See esp::physics::PhysicsManager::applyForce.

Parameters
force The desired linear force to apply.
relPos The desired location relative to the object origin at which to apply the force.
objectID The ID of the object identifying it in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.

Magnum::Matrix4 esp::sim::Simulator::getTransformation(const int objectID, const int sceneID = 0)

Get the current 4x4 transformation matrix of an object. See esp::physics::PhysicsManager::getTransformation.

Parameters
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.
Returns The 4x4 transform of the object.

void esp::sim::Simulator::setTransformation(const Magnum::Matrix4& transform, const int objectID, const int sceneID = 0)

Set the 4x4 transformation matrix of an object kinematically. See esp::physics::PhysicsManager::setTransformation.

Parameters
transform The desired 4x4 transform of the object.
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.

esp::core::RigidState esp::sim::Simulator::getRigidState(const int objectID, const int sceneID = 0) const

Get the current esp::core::RigidState of an object.

Parameters
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.
Returns The esp::core::RigidState transform of the object.

void esp::sim::Simulator::setRigidState(const esp::core::RigidState& rigidState, const int objectID, const int sceneID = 0)

Set the esp::core::RigidState of an object kinematically.

Parameters
rigidState
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.

void esp::sim::Simulator::setTranslation(const Magnum::Vector3& translation, const int objectID, const int sceneID = 0)

Set the 3D position of an object kinematically. See esp::physics::PhysicsManager::setTranslation.

Parameters
translation The desired 3D position of the object.
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.

Magnum::Vector3 esp::sim::Simulator::getTranslation(const int objectID, const int sceneID = 0)

Get the current 3D position of an object. See esp::physics::PhysicsManager::getTranslation.

Parameters
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.
Returns The 3D position of the object.

void esp::sim::Simulator::setRotation(const Magnum::Quaternion& rotation, const int objectID, const int sceneID = 0)

Set the orientation of an object kinematically. See esp::physics::PhysicsManager::setRotation.

Parameters
rotation The desired orientation of the object.
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.

Magnum::Quaternion esp::sim::Simulator::getRotation(const int objectID, const int sceneID = 0)

Get the current orientation of an object. See esp::physics::PhysicsManager::getRotation.

Parameters
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.
Returns A quaternion representation of the object's orientation.

void esp::sim::Simulator::setLinearVelocity(const Magnum::Vector3& linVel, const int objectID, const int sceneID = 0)

Set the Linear Velocity of object. See esp::phyics::PhysicsManager::setLinearVelocity.

Parameters
linVel The desired linear velocity of the object.
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.

Magnum::Vector3 esp::sim::Simulator::getLinearVelocity(const int objectID, const int sceneID = 0)

Get the Linear Velocity of object. See esp::physics::PhysicsManager::getLinearVelocity.

Parameters
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.
Returns A vector3 representation of the object's linear velocity.

void esp::sim::Simulator::setAngularVelocity(const Magnum::Vector3& angVel, const int objectID, const int sceneID = 0)

Set the Angular Velocity of object. See esp::phyics::PhysicsManager::setAngularVelocity.

Parameters
angVel The desired angular velocity of the object.
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.

Magnum::Vector3 esp::sim::Simulator::getAngularVelocity(const int objectID, const int sceneID = 0)

Get the Angular Velocity of object. See esp::physics::PhysicsManager::getAngularVelocity.

Parameters
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.
Returns A vector3 representation of the object's angular velocity.

void esp::sim::Simulator::setObjectBBDraw(bool drawBB, const int objectID, const int sceneID = 0)

Turn on/off rendering for the bounding box of the object's visual component.

Parameters
drawBB Whether or not the render the bounding box.
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.

Assumes the new esp::gfx::Drawable for the bounding box should be added to the active esp::gfx::SceneGraph's default drawable group. See esp::gfx::SceneGraph::getDrawables().

void esp::sim::Simulator::setObjectSemanticId(uint32_t semanticId, int objectID, int sceneID = 0)

Set the esp::scene:SceneNode::semanticId_ for all visual nodes belonging to an object.

Parameters
semanticId The desired semantic id for the object.
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.

bool esp::sim::Simulator::contactTest(const int objectID, const int sceneID = 0)

Discrete collision check for contact between an object and the collision world.

Parameters
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
sceneID !! Not used currently !! Specifies which physical scene of the object.
Returns Whether or not the object is in contact with any other collision enabled objects.

esp::physics::RaycastResults esp::sim::Simulator::castRay(const esp::geo::Ray& ray, float maxDistance = 100.0, const int sceneID = 0)

Raycast into the collision world of a scene.

Parameters
ray The ray to cast. Need not be unit length, but returned hit distances will be in units of ray length.
maxDistance The maximum distance along the ray direction to search. In units of ray length.
sceneID !! Not used currently !! Specifies which physical scene of the object.
Returns Raycast results sorted by distance.

Note: A default physics::PhysicsManager has no collision world, so physics must be enabled for this feature.

double esp::sim::Simulator::stepWorld(const double dt = 1.0/60.0)

the physical world has a notion of time which passes during animation/simulation/action/etc... Step the physical world forward in time by a desired duration. Note that the actual duration of time passed by this step will depend on simulation time stepping mode (todo). See esp::physics::PhysicsManager::stepPhysics.

Parameters
dt The desired amount of time to advance the physical world.
Returns The new world time after stepping. See esp::physics::PhysicsManager::worldTime_.

double esp::sim::Simulator::getWorldTime()

Get the current time in the simulated world. This is always 0 if no esp::physics::PhysicsManager is initialized. See stepWorld. See esp::physics::PhysicsManager::getWorldTime.

Returns The amount of time, esp::physics::PhysicsManager::worldTime_, by which the physical world has advanced.

bool esp::sim::Simulator::recomputeNavMesh(nav::PathFinder& pathfinder, const nav::NavMeshSettings& navMeshSettings, bool includeStaticObjects = false)

Compute the navmesh for the simulator's current active scene and assign it to the referenced nav::PathFinder.

Parameters
pathfinder The pathfinder object to which the recomputed navmesh will be assigned.
navMeshSettings The nav::NavMeshSettings instance to parameterize the navmesh construction.
includeStaticObjects
Returns Whether or not the navmesh recomputation succeeded.

bool esp::sim::Simulator::setNavMeshVisualization(bool visualize)

Set visualization of the current NavMesh pathfinder_ on or off.

Parameters
visualize Whether or not to visualize the navmesh.
Returns Whether or not the NavMesh visualization is active.

bool esp::sim::Simulator::displayObservation(int agentId, const std::string& sensorId)

Displays observations on default frame buffer for a particular sensor of an agent.

Parameters
agentId Id of the agent for which the observation is to be returned
sensorId Id of the sensor for which the observation is to be returned

void esp::sim::Simulator::setFrustumCullingEnabled(bool val)

Enable or disable frustum culling (enabled by default)

Parameters
val = enable, false = disable

bool esp::sim::Simulator::isFrustumCullingEnabled()

Get status, whether frustum culling is enabled or not.

Returns true if enabled, otherwise false

void esp::sim::Simulator::setLightSetup(gfx::LightSetup lightSetup, const std::string& key = assets::ResourceManager::DEFAULT_LIGHTING_KEY)

Set a named LightSetup.

Parameters
lightSetup Light setup this key will now reference
key Key to identify this LightSetup

If this name already exists, the LightSetup is updated and all Drawables using this setup are updated.

void esp::sim::Simulator::setObjectLightSetup(int objectID, const std::string& lightSetupKey, int sceneID = 0)

Set the light setup of an object.

Parameters
objectID The object ID and key identifying the object in esp::physics::PhysicsManager::existingObjects_.
lightSetupKey LightSetup key
sceneID !! Not used currently !! Specifies which physical scene of the object.

core::Random::ptr esp::sim::Simulator::random()

Getter for PRNG.

Use this where-ever possible so that habitat won't be effect by python's random or np.random modules