17#ifndef GAZEBO_PHYSICS_ATMOSPHEREFACTORY_HH_
18#define GAZEBO_PHYSICS_ATMOSPHEREFACTORY_HH_
49 AtmosphereFactoryFn _factoryfn);
56 const std::string &_className,
World &_world);
64 private:
static std::map<std::string, AtmosphereFactoryFn> models;
72 #define GZ_REGISTER_ATMOSPHERE_MODEL(_name, _classname) \
73 GZ_PHYSICS_VISIBLE std::unique_ptr<Atmosphere> \
74 New##_classname(World &_world) \
76 return std::unique_ptr<Atmosphere>( \
77 new gazebo::physics::_classname(_world)); \
80 void Register##_classname() \
82 AtmosphereFactory::RegisterAtmosphere(_name, New##_classname);\
default namespace for gazebo
The atmosphere factory instantiates different atmosphere models.
Definition AtmosphereFactory.hh:40
static std::unique_ptr< Atmosphere > NewAtmosphere(const std::string &_className, World &_world)
Create a new instance of an atmosphere model.
static void RegisterAtmosphere(const std::string &_className, AtmosphereFactoryFn _factoryfn)
Register an atmosphere class.
static bool IsRegistered(const std::string &_name)
Check if an atmosphere model is registered.
static void RegisterAll()
Register everything.
The world provides access to all other object within a simulated environment.
Definition World.hh:76
std::unique_ptr< Atmosphere >(* AtmosphereFactoryFn)(World &world)
Definition AtmosphereFactory.hh:35
Forward declarations for the common classes.
Definition Animation.hh:27