27 #include <Eigen/Eigen>
31 #include <ArmarXCore/interface/core/ArmarXManagerInterface.h>
38 #include <RobotComponents/gui-plugins/LaserScannerSelfLocalisation/ui_LaserScannerSelfLocalisationWidget.h>
39 #include <RobotComponents/interface/components/LaserScannerSelfLocalisation.h>
60 public armarx::LaserScannerSelfLocalisationListener
78 void loadSettings(QSettings* settings)
override;
83 void saveSettings(QSettings* settings)
override;
92 return "RobotControl.LaserScannerSelfLocalisation";
98 void onInitComponent()
override;
103 void onConnectComponent()
override;
105 QPointer<QDialog> getConfigDialog(QWidget* parent)
override;
107 void configured()
override;
109 void onPaintCanvas(QPainter& painter, QSize size);
115 const Ice::Current&)
override;
119 const Ice::Current&)
override;
122 void reportLaserScanPoints(
const Vector2fSeq& globalPoints,
const Ice::Current&)
override;
123 void reportExtractedEdges(
const LineSegment2DSeq&,
const Ice::Current&)
override;
126 void onSpinBoxChanged(
int value);
127 void onSpinBoxChanged(
double value);
128 void onNewDataReported();
129 void onSetPoseClick();
130 void onCanvasClick(QPoint p);
134 void newDataReported();
137 void updateProperties();
138 void readProperties();
140 enum class SetPoseState
150 void timerEvent(QTimerEvent* event)
override;
153 Ui::LaserScannerSelfLocalisationWidget widget;
154 QPointer<SimpleConfigDialog> dialog;
155 QPainterWidget* painterWidget;
158 std::string localisationName;
159 LaserScannerSelfLocalisationInterfacePrx localisation;
160 ArmarXManagerInterfacePrx localisationManager;
161 Ice::PropertiesAdminPrx localisationAdmin;
162 LineSegment2DSeq map;
164 std::atomic<float> poseX;
165 std::atomic<float> poseY;
166 std::atomic<float> poseTheta;
168 std::atomic<float> poseUncertaintyX;
169 std::atomic<float> poseUncertaintyY;
170 std::atomic<float> poseUncertaintyTheta;
175 LineSegment2DSeq edges;
177 std::vector<QLine> lines;
178 std::vector<QPoint> qpoints;
179 std::vector<QLine> qedges;
181 SetPoseState setPoseState;
183 QPoint setOrientation;