CARLA
Public Member Functions | List of all members
carla::traffic_manager::TrafficManagerBase Class Referenceabstract

The function of this class is to integrate all the various stages of the traffic manager appropriately using messengers. More...

#include <TrafficManagerBase.h>

+ Inheritance diagram for carla::traffic_manager::TrafficManagerBase:

Public Member Functions

virtual carla::client::detail::EpisodeProxyGetEpisodeProxy ()=0
 Get carla episode information. More...
 
virtual void RegisterVehicles (const std::vector< ActorPtr > &actor_list)=0
 This method registers a vehicle with the traffic manager. More...
 
virtual void Release ()=0
 To release the traffic manager. More...
 
virtual void Reset ()=0
 To reset the traffic manager. More...
 
virtual void SetAutoLaneChange (const ActorPtr &actor, const bool enable)=0
 Enable/disable automatic lane change on a vehicle. More...
 
virtual void SetCollisionDetection (const ActorPtr &reference_actor, const ActorPtr &other_actor, const bool detect_collision)=0
 Method to set collision detection rules between vehicles. More...
 
virtual void SetDistanceToLeadingVehicle (const ActorPtr &actor, const float distance)=0
 Method to specify how much distance a vehicle should maintain to the leading vehicle. More...
 
virtual void SetForceLaneChange (const ActorPtr &actor, const bool direction)=0
 Method to force lane change on a vehicle. More...
 
virtual void SetGlobalDistanceToLeadingVehicle (const float dist)=0
 Method to set Global Distance to Leading Vehicle. More...
 
virtual void SetGlobalPercentageSpeedDifference (float const percentage)=0
 Set a global % decrease in velocity with respect to the speed limit. More...
 
virtual void SetHybridPhysicsMode (const bool mode_switch)=0
 Method to set hybrid physics mode. More...
 
virtual void SetHybridPhysicsRadius (const float radius)=0
 Method to set hybrid physics radius. More...
 
virtual void SetKeepRightPercentage (const ActorPtr &actor, const float percentage)=0
 Method to set probabilistic preference to keep on the right lane. More...
 
virtual void SetOSMMode (const bool mode_switch)=0
 Method to set Open Street Map mode. More...
 
virtual void SetPercentageIgnoreVehicles (const ActorPtr &actor, const float perc)=0
 Method to specify the % chance of ignoring collisions with any vehicle. More...
 
virtual void SetPercentageIgnoreWalkers (const ActorPtr &actor, const float perc)=0
 Method to specify the % chance of ignoring collisions with any walker. More...
 
virtual void SetPercentageRunningLight (const ActorPtr &actor, const float perc)=0
 Method to specify the % chance of running any traffic light. More...
 
virtual void SetPercentageRunningSign (const ActorPtr &actor, const float perc)=0
 Method to specify the % chance of running any traffic sign. More...
 
virtual void SetPercentageSpeedDifference (const ActorPtr &actor, const float percentage)=0
 Set a vehicle's % decrease in velocity with respect to the speed limit. More...
 
virtual void SetRandomDeviceSeed (const uint64_t seed)=0
 Method to set randomization seed. More...
 
virtual void SetSynchronousMode (bool mode)=0
 Method to switch traffic manager into synchronous execution. More...
 
virtual void SetSynchronousModeTimeOutInMiliSecond (double time)=0
 Method to set Tick timeout for synchronous execution. More...
 
virtual void Start ()=0
 To start the traffic manager. More...
 
virtual void Stop ()=0
 To stop the traffic manager. More...
 
virtual bool SynchronousTick ()=0
 Method to provide synchronous tick. More...
 
 TrafficManagerBase ()
 Protected constructor for singleton lifecycle management. More...
 
virtual void UnregisterVehicles (const std::vector< ActorPtr > &actor_list)=0
 This method unregisters a vehicle from traffic manager. More...
 
virtual ~TrafficManagerBase ()
 Destructor. More...
 

Detailed Description

The function of this class is to integrate all the various stages of the traffic manager appropriately using messengers.

Definition at line 19 of file TrafficManagerBase.h.

Constructor & Destructor Documentation

◆ TrafficManagerBase()

carla::traffic_manager::TrafficManagerBase::TrafficManagerBase ( )
inline

Protected constructor for singleton lifecycle management.

Definition at line 35 of file TrafficManagerBase.h.

◆ ~TrafficManagerBase()

virtual carla::traffic_manager::TrafficManagerBase::~TrafficManagerBase ( )
inlinevirtual

Member Function Documentation

◆ GetEpisodeProxy()

virtual carla::client::detail::EpisodeProxy& carla::traffic_manager::TrafficManagerBase::GetEpisodeProxy ( )
pure virtual

Get carla episode information.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ RegisterVehicles()

virtual void carla::traffic_manager::TrafficManagerBase::RegisterVehicles ( const std::vector< ActorPtr > &  actor_list)
pure virtual

This method registers a vehicle with the traffic manager.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::RegisterVehicles(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ Release()

virtual void carla::traffic_manager::TrafficManagerBase::Release ( )
pure virtual

◆ Reset()

virtual void carla::traffic_manager::TrafficManagerBase::Reset ( )
pure virtual

◆ SetAutoLaneChange()

virtual void carla::traffic_manager::TrafficManagerBase::SetAutoLaneChange ( const ActorPtr actor,
const bool  enable 
)
pure virtual

Enable/disable automatic lane change on a vehicle.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetAutoLaneChange(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetCollisionDetection()

virtual void carla::traffic_manager::TrafficManagerBase::SetCollisionDetection ( const ActorPtr reference_actor,
const ActorPtr other_actor,
const bool  detect_collision 
)
pure virtual

Method to set collision detection rules between vehicles.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetCollisionDetection(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetDistanceToLeadingVehicle()

virtual void carla::traffic_manager::TrafficManagerBase::SetDistanceToLeadingVehicle ( const ActorPtr actor,
const float  distance 
)
pure virtual

Method to specify how much distance a vehicle should maintain to the leading vehicle.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetDistanceToLeadingVehicle(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetForceLaneChange()

virtual void carla::traffic_manager::TrafficManagerBase::SetForceLaneChange ( const ActorPtr actor,
const bool  direction 
)
pure virtual

Method to force lane change on a vehicle.

Direction flag can be set to true for left and false for right.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetForceLaneChange(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetGlobalDistanceToLeadingVehicle()

virtual void carla::traffic_manager::TrafficManagerBase::SetGlobalDistanceToLeadingVehicle ( const float  dist)
pure virtual

Method to set Global Distance to Leading Vehicle.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetGlobalDistanceToLeadingVehicle(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetGlobalPercentageSpeedDifference()

virtual void carla::traffic_manager::TrafficManagerBase::SetGlobalPercentageSpeedDifference ( float const  percentage)
pure virtual

Set a global % decrease in velocity with respect to the speed limit.

If less than 0, it's a % increase.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetGlobalPercentageSpeedDifference(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetHybridPhysicsMode()

virtual void carla::traffic_manager::TrafficManagerBase::SetHybridPhysicsMode ( const bool  mode_switch)
pure virtual

Method to set hybrid physics mode.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetHybridPhysicsMode(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetHybridPhysicsRadius()

virtual void carla::traffic_manager::TrafficManagerBase::SetHybridPhysicsRadius ( const float  radius)
pure virtual

Method to set hybrid physics radius.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetHybridPhysicsRadius(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetKeepRightPercentage()

virtual void carla::traffic_manager::TrafficManagerBase::SetKeepRightPercentage ( const ActorPtr actor,
const float  percentage 
)
pure virtual

Method to set probabilistic preference to keep on the right lane.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetKeepRightPercentage(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetOSMMode()

virtual void carla::traffic_manager::TrafficManagerBase::SetOSMMode ( const bool  mode_switch)
pure virtual

Method to set Open Street Map mode.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetOSMMode(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetPercentageIgnoreVehicles()

virtual void carla::traffic_manager::TrafficManagerBase::SetPercentageIgnoreVehicles ( const ActorPtr actor,
const float  perc 
)
pure virtual

Method to specify the % chance of ignoring collisions with any vehicle.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetPercentageIgnoreVehicles(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetPercentageIgnoreWalkers()

virtual void carla::traffic_manager::TrafficManagerBase::SetPercentageIgnoreWalkers ( const ActorPtr actor,
const float  perc 
)
pure virtual

Method to specify the % chance of ignoring collisions with any walker.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetPercentageIgnoreWalkers(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetPercentageRunningLight()

virtual void carla::traffic_manager::TrafficManagerBase::SetPercentageRunningLight ( const ActorPtr actor,
const float  perc 
)
pure virtual

Method to specify the % chance of running any traffic light.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetPercentageRunningLight(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetPercentageRunningSign()

virtual void carla::traffic_manager::TrafficManagerBase::SetPercentageRunningSign ( const ActorPtr actor,
const float  perc 
)
pure virtual

Method to specify the % chance of running any traffic sign.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetPercentageRunningSign(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetPercentageSpeedDifference()

virtual void carla::traffic_manager::TrafficManagerBase::SetPercentageSpeedDifference ( const ActorPtr actor,
const float  percentage 
)
pure virtual

Set a vehicle's % decrease in velocity with respect to the speed limit.

If less than 0, it's a % increase.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetPercentageSpeedDifference(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetRandomDeviceSeed()

virtual void carla::traffic_manager::TrafficManagerBase::SetRandomDeviceSeed ( const uint64_t  seed)
pure virtual

Method to set randomization seed.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetRandomDeviceSeed(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetSynchronousMode()

virtual void carla::traffic_manager::TrafficManagerBase::SetSynchronousMode ( bool  mode)
pure virtual

Method to switch traffic manager into synchronous execution.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetSynchronousMode(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ SetSynchronousModeTimeOutInMiliSecond()

virtual void carla::traffic_manager::TrafficManagerBase::SetSynchronousModeTimeOutInMiliSecond ( double  time)
pure virtual

Method to set Tick timeout for synchronous execution.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SetSynchronousModeTimeOutInMiliSecond(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ Start()

virtual void carla::traffic_manager::TrafficManagerBase::Start ( )
pure virtual

◆ Stop()

virtual void carla::traffic_manager::TrafficManagerBase::Stop ( )
pure virtual

◆ SynchronousTick()

virtual bool carla::traffic_manager::TrafficManagerBase::SynchronousTick ( )
pure virtual

Method to provide synchronous tick.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManager::SynchronousTick(), carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

◆ UnregisterVehicles()

virtual void carla::traffic_manager::TrafficManagerBase::UnregisterVehicles ( const std::vector< ActorPtr > &  actor_list)
pure virtual

This method unregisters a vehicle from traffic manager.

Implemented in carla::traffic_manager::TrafficManagerLocal, and carla::traffic_manager::TrafficManagerRemote.

Referenced by carla::traffic_manager::TrafficManagerServer::TrafficManagerServer(), carla::traffic_manager::TrafficManager::UnregisterVehicles(), and ~TrafficManagerBase().

+ Here is the caller graph for this function:

The documentation for this class was generated from the following file: