LookAtDemoPlugin.hh
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2016 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 #ifndef GAZEBO_PLUGINS_LOOKATDEMOPLUGIN_HH_
18 #define GAZEBO_PLUGINS_LOOKATDEMOPLUGIN_HH_
19 
20 #include <ignition/transport/Node.hh>
21 
22 #include <gazebo/common/Plugin.hh>
23 #include <gazebo/gui/GuiPlugin.hh>
24 #ifndef Q_MOC_RUN // See: https://bugreports.qt-project.org/browse/QTBUG-22829
25 # include <gazebo/transport/transport.hh>
26 # include <gazebo/gui/gui.hh>
27 #endif
28 
29 namespace gazebo
30 {
47  {
48  Q_OBJECT
49 
51  public: LookAtDemoPlugin();
52 
54  public: virtual ~LookAtDemoPlugin();
55 
56  // Documentation inherited
57  public: void Load(sdf::ElementPtr /*_elem*/);
58 
61  private slots: void OnChange(const double _newValue);
62 
64  private: QDoubleSpinBox *eyeX;
65 
67  private: QDoubleSpinBox *eyeY;
68 
70  private: QDoubleSpinBox *eyeZ;
71 
73  private: QDoubleSpinBox *targetX;
74 
76  private: QDoubleSpinBox *targetY;
77 
79  private: QDoubleSpinBox *targetZ;
80 
82  private: QDoubleSpinBox *upX;
83 
85  private: QDoubleSpinBox *upY;
86 
88  private: QDoubleSpinBox *upZ;
89 
91  private: transport::NodePtr node;
92 
94  private: transport::PublisherPtr modelModifyPub;
95 
96  // Place ignition::transport objects at the end of this file to
97  // guarantee they are destructed first.
98 
100  private: ignition::transport::Node nodeIgn;
101 
103  private: ignition::transport::Node::Publisher modelModifyPubIgn;
104  };
105 }
106 
107 #endif
Forward declarations for the common classes.
Definition: Animation.hh:33
A plugin loaded within the gzclient on startup.
Definition: GuiPlugin.hh:26
boost::shared_ptr< Publisher > PublisherPtr
Definition: TransportTypes.hh:49
boost::shared_ptr< Node > NodePtr
Definition: TransportTypes.hh:57
A GUI plugin that demos the ignition::math::Matrix4<T>::LookAt function.
Definition: LookAtDemoPlugin.hh:46
#define GAZEBO_VISIBLE
Use to represent "symbol visible" if supported.
Definition: system.hh:58