ApplyWrenchDialogPrivate.hh
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2015-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_APPLY_WRENCH_DIALOG_PRIVATE_HH_
18 #define _GAZEBO_APPLY_WRENCH_DIALOG_PRIVATE_HH_
19 
20 #include <string>
21 #include <vector>
22 #include <map>
23 #include <mutex>
24 
25 #include "gazebo/gui/qt.h"
27 
28 namespace gazebo
29 {
30  namespace gui
31  {
35  {
38 
40  public: std::string modelName;
41 
43  public: std::string linkName;
44 
46  public: QLabel *modelLabel;
47 
49  public: QComboBox *linksComboBox;
50 
52  public: QRadioButton *comRadio;
53 
55  public: QRadioButton *forcePosRadio;
56 
58  public: QDoubleSpinBox *forcePosXSpin;
59 
61  public: QDoubleSpinBox *forcePosYSpin;
62 
64  public: QDoubleSpinBox *forcePosZSpin;
65 
67  public: QDoubleSpinBox *forceMagSpin;
68 
70  public: QDoubleSpinBox *forceXSpin;
71 
73  public: QDoubleSpinBox *forceYSpin;
74 
76  public: QDoubleSpinBox *forceZSpin;
77 
79  public: QDoubleSpinBox *torqueMagSpin;
80 
82  public: QDoubleSpinBox *torqueXSpin;
83 
85  public: QDoubleSpinBox *torqueYSpin;
86 
88  public: QDoubleSpinBox *torqueZSpin;
89 
92 
95 
98 
101 
105 
108 
110  public: std::vector<event::ConnectionPtr> connections;
111 
113  public: std::map<std::string, math::Vector3> linkToCOMMap;
114 
117 
120  public: bool draggingTool;
121 
125 
128  public: std::string manipState;
129 
132 
134  public: std::mutex mutex;
135 
138  };
139  }
140 }
141 #endif
QLabel * modelLabel
Label holding the model name.
Definition: ApplyWrenchDialogPrivate.hh:46
std::map< std::string, math::Vector3 > linkToCOMMap
Map link name to link CoM vector.
Definition: ApplyWrenchDialogPrivate.hh:113
rendering::ApplyWrenchVisualPtr applyWrenchVisual
Interactive visual which represents the wrench to be applied.
Definition: ApplyWrenchDialogPrivate.hh:116
std::vector< event::ConnectionPtr > connections
A list of events connected to this.
Definition: ApplyWrenchDialogPrivate.hh:110
QDoubleSpinBox * torqueMagSpin
Spin for torque magnitude.
Definition: ApplyWrenchDialogPrivate.hh:79
QRadioButton * forcePosRadio
Radio button for force position.
Definition: ApplyWrenchDialogPrivate.hh:55
Encapsulates a position and rotation in three space.
Definition: Pose.hh:37
MainWindow * mainWindow
Pointer to the main window.
Definition: ApplyWrenchDialogPrivate.hh:137
std::string modelName
Name of the model this is connected to.
Definition: ApplyWrenchDialogPrivate.hh:40
ApplyWrenchDialog::Mode mode
Current mode, either force, torque or none.
Definition: ApplyWrenchDialogPrivate.hh:131
The Vector3 class represents the generic vector containing 3 elements.
Definition: Vector3.hh:39
transport::NodePtr node
Node for communication.
Definition: ApplyWrenchDialogPrivate.hh:37
QDoubleSpinBox * forceXSpin
Spin for force X.
Definition: ApplyWrenchDialogPrivate.hh:70
std::string linkName
Name of the link currently targeted.
Definition: ApplyWrenchDialogPrivate.hh:43
QDoubleSpinBox * forcePosXSpin
Spin for force position X.
Definition: ApplyWrenchDialogPrivate.hh:58
math::Vector3 forceVector
Force vector.
Definition: ApplyWrenchDialogPrivate.hh:97
QDoubleSpinBox * forceYSpin
Spin for force Y.
Definition: ApplyWrenchDialogPrivate.hh:73
math::Vector3 forcePosVector
Force position coordinates in link frame.
Definition: ApplyWrenchDialogPrivate.hh:94
std::shared_ptr< Visual > VisualPtr
Definition: RenderTypes.hh:112
QComboBox * linksComboBox
Dropdown holding all link names.
Definition: ApplyWrenchDialogPrivate.hh:49
Mode
Definition: ApplyWrenchDialog.hh:45
math::Pose dragStartPose
World pose of the rotation tool the moment dragging started.
Definition: ApplyWrenchDialogPrivate.hh:124
QDoubleSpinBox * forcePosZSpin
Spin for force position Z.
Definition: ApplyWrenchDialogPrivate.hh:64
math::Vector3 torqueVector
Torque vector.
Definition: ApplyWrenchDialogPrivate.hh:100
QRadioButton * comRadio
Radio button for CoM.
Definition: ApplyWrenchDialogPrivate.hh:52
bool draggingTool
Indicate whether mouse is dragging on top the rotation tool or not.
Definition: ApplyWrenchDialogPrivate.hh:120
rendering::VisualPtr linkVisual
Visual of the targeted link.
Definition: ApplyWrenchDialogPrivate.hh:107
boost::shared_ptr< Node > NodePtr
Definition: TransportTypes.hh:57
Definition: MainWindow.hh:43
math::Vector3 comVector
CoM coordinates in link frame.
Definition: ApplyWrenchDialogPrivate.hh:91
QDoubleSpinBox * forceZSpin
Spin for force Z.
Definition: ApplyWrenchDialogPrivate.hh:76
QDoubleSpinBox * torqueZSpin
Spin for torque Z.
Definition: ApplyWrenchDialogPrivate.hh:88
QDoubleSpinBox * torqueXSpin
Spin for torque X.
Definition: ApplyWrenchDialogPrivate.hh:82
std::shared_ptr< ApplyWrenchVisual > ApplyWrenchVisualPtr
Definition: RenderTypes.hh:172
QDoubleSpinBox * torqueYSpin
Spin for torque Y.
Definition: ApplyWrenchDialogPrivate.hh:85
QDoubleSpinBox * forceMagSpin
Spin for force magnitude.
Definition: ApplyWrenchDialogPrivate.hh:67
std::string manipState
State of the manipulation tool, here only using "rot_y" and "rot_z".
Definition: ApplyWrenchDialogPrivate.hh:128
boost::shared_ptr< Publisher > PublisherPtr
Definition: TransportTypes.hh:49
transport::PublisherPtr userCmdPub
Publish user command messages for the server to place in the undo queue.
Definition: ApplyWrenchDialogPrivate.hh:104
Private data for the ApplyWrenchDialog class.
Definition: ApplyWrenchDialogPrivate.hh:34
QDoubleSpinBox * forcePosYSpin
Spin for force position Y.
Definition: ApplyWrenchDialogPrivate.hh:61
std::mutex mutex
Mutex to protect variables.
Definition: ApplyWrenchDialogPrivate.hh:134