physics/Light.hh
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2015 Open Source Robotics Foundation
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16 */
17 
18 #ifndef GAZEBO_PHYSICS_LIGHT_HH_
19 #define GAZEBO_PHYSICS_LIGHT_HH_
20 
21 #include <memory>
22 #include "gazebo/physics/Entity.hh"
23 
24 namespace gazebo
25 {
26  namespace physics
27  {
28  class LightPrivate;
29  class LightState;
30 
33 
35  class GZ_PHYSICS_VISIBLE Light : public Entity
36  {
39  public: explicit Light(BasePtr _parent);
40 
42  public: virtual ~Light();
43 
45  public: void Init();
46 
49  public: void ProcessMsg(const msgs::Light &_msg);
50 
53  public: void FillMsg(msgs::Light &_msg);
54 
57  public: void SetState(const LightState &_state);
58 
59  // Documentation inherited
60  public: void OnPoseChange();
61 
63  private: void PublishPose();
64 
68  public: void SetWorldPoseDirty();
69 
70  // Documentation inherited.
71  public: virtual const ignition::math::Pose3d &WorldPose() const;
72 
74  private: std::unique_ptr<LightPrivate> dataPtr;
75  };
77  }
78 }
79 #endif
80 
A light entity.
Definition: physics/Light.hh:35
Store state information of a Light object.
Definition: LightState.hh:38
Base class for all physics objects in Gazebo.
Definition: Entity.hh:52
GAZEBO_VISIBLE void Init(google::protobuf::Message &_message, const std::string &_id="")
Initialize a message.
boost::shared_ptr< Base > BasePtr
Definition: PhysicsTypes.hh:77