18 #ifndef GAZEBO_GUI_MODEL_VISUALCONFIG_HH_
19 #define GAZEBO_GUI_MODEL_VISUALCONFIG_HH_
24 #include <ignition/math/Pose3.hh>
25 #include <ignition/math/Vector3.hh>
50 private slots:
void OnToggleItem(
bool _checked);
85 public slots:
void RestoreOriginalData();
91 public:
void AddVisual(
const std::string &_name,
92 const msgs::Visual *_visualMsg =
NULL);
97 public:
void UpdateVisual(
const std::string &_name,
98 ConstVisualPtr _visualMsg);
101 public:
void Reset();
105 public:
unsigned int GetVisualCount()
const;
110 public:
void SetShowVisual(
const bool _show,
const std::string &_name);
115 public: msgs::Visual *GetData(
const std::string &_name)
const;
121 public:
void SetGeometry(
const std::string &_name,
122 const ignition::math::Vector3d &_size,
const std::string &_uri =
"");
128 public:
void Geometry(
const std::string &_name,
129 ignition::math::Vector3d &_size, std::string &_uri);
138 public:
void SetMaterial(
const std::string &_name,
139 const std::string &_materialName,
145 public:
const std::map<int, VisualConfigData *> &ConfigData()
const;
149 Q_SIGNALS:
void VisualRemoved(
const std::string &_name);
153 Q_SIGNALS:
void VisualAdded(
const std::string &_name);
158 Q_SIGNALS:
void ShowVisual(
const bool _show,
const std::string &_name);
161 Q_SIGNALS:
void Applied();
164 private slots:
void OnAddVisual();
168 private slots:
void OnRemoveVisual(
int _id);
172 private slots:
void OnShowVisual(
const int _id);
178 private slots:
void OnPoseChanged(
const QString &_name,
179 const ignition::math::Pose3d &_value);
187 private slots:
void OnGeometryChanged(
const std::string &_name,
188 const std::string &_value,
189 const ignition::math::Vector3d &_dimensions,
190 const std::string &_uri);
196 private slots:
void OnColorChanged(
const QString &_name,
203 private slots:
void OnDoubleChanged(
const QString &_name,
204 const double _value);
210 private slots:
void OnStringChanged(
const QString &_name,
211 const std::string &_value);
214 private: std::map<int, VisualConfigData *> configs;
217 private: std::map<int, VisualConfigData *> deletedConfigs;
220 private: std::map<int, VisualConfigData *> addedConfigs;
223 private:
int counter;
226 private: QSignalMapper *mapperRemove;
229 private: QSignalMapper *mapperShow;
232 private: QVBoxLayout *listLayout;
std::string name
Name of the visual.
Definition: VisualConfig.hh:56
int id
Unique ID of this visual config.
Definition: VisualConfig.hh:53
A class of widgets used for configuring visual properties.
Definition: VisualConfig.hh:41
ConfigWidget * configWidget
Config widget for configuring visual properties.
Definition: VisualConfig.hh:59
void RestoreOriginalData()
Restore the widget's data to how it was when first opened.
A tab for configuring visual properties of a link.
Definition: VisualConfig.hh:71
msgs::Visual originalDataMsg
Message containing the data which was in the widget when first open.
Definition: VisualConfig.hh:66
QWidget * widget
Widget associated with this data.
Definition: VisualConfig.hh:62
#define NULL
Definition: CommonTypes.hh:31
Defines a color.
Definition: Color.hh:36
GAZEBO_VISIBLE void Init(google::protobuf::Message &_message, const std::string &_id="")
Initialize a message.