mainwindow.h
Go to the documentation of this file.
1 
18 #ifndef MAINWINDOW_H
19 #define MAINWINDOW_H
20 
21 #include <QMainWindow>
22 #include <QCheckBox>
23 #include <QRadioButton>
24 #include <QLabel>
25 #include <QPushButton>
26 #include <QListWidget>
27 #ifndef Q_MOC_RUN
28 #include <boost/shared_ptr.hpp>
29 #endif
30 
33 #include "laserscanthread.h"
36 #include <GUI/ptuwindow.h>
37 #include <calibration_object.h>
42 
43 class MainWindow : public QMainWindow
44 {
45  Q_OBJECT
46 public:
47  explicit MainWindow(QWidget *parent = 0);
48  EIGEN_MAKE_ALIGNED_OPERATOR_NEW
49 protected:
50  unsigned int showData;
52  QCheckBox *chk_rawdata;
53  QCheckBox *chk_avgData;
54  QCheckBox *chk_filteredData;
55  QCheckBox *chk_segments;
56  QCheckBox *chk_edges;
57 
58  //Shows the coordinates of all triangles currently detected by the scanner
59  QLabel *lblTriangles;
60  //Shows the number of solutions of the p3p problem for the current triangle
61  QLabel *lblSolutions;
62 
64 
66 
68 
69  //Shows the variance over all captured poses of the objects top point
71 
72  QPushButton *btnCapture;
75  QPushButton *btnStartPTUCapture;
76  QPushButton *btnAddTopPose;
77  QPushButton *btnDeleteTopPose;
78  QPushButton *btnClearTopPose;
79 
80  QListWidget * lstTopPose;
81 
83 
85 
86  QRadioButton *radio_polar;
87  QRadioButton *radio_flat;
89 
90  std::vector<Eigen::Vector2d, Eigen::aligned_allocator<Eigen::Vector2d> > *currentTriangles;
91  std::vector<Eigen::Vector2d, Eigen::aligned_allocator<Eigen::Vector2d> > *selectedTriangle;
92 
93  //
94  std::vector<Eigen::Vector3d, Eigen::aligned_allocator<Eigen::Vector3d> > *capturedTopPoses;
95 
96  //All the possible solutions for the current triangle
97  std::vector<Eigen::Matrix4d, Eigen::aligned_allocator<Eigen::Matrix4d> > * solutionFrames;
98 
100 
101  //Used to publish the current results to ros
103 
104  //Contains all the parameters of the calibration object
106 
108 
110 
111  //Used to project the tf frames into the camera image
113 
114  void addMatrixRow(QString* text, double value);
115  void showPossibleSolutions();
116  void resizeEvent(QResizeEvent * event);
117  void toggleCaptureMode();
119 signals:
120  void setCurves(unsigned int showData = 1);
121  void newTransform_Laserscan(const Eigen::Matrix4d& transform, double distanceToTop);
122 
123 public slots:
124  void trianglesFound(std::vector<Eigen::Vector2d, Eigen::aligned_allocator<Eigen::Vector2d> > *triangles);
125 
126  void chk_rawData_stateChanged(bool state);
127  void chk_avgData_stateChanged(bool state);
128  void chk_filteredData_stateChanged(bool state);
129  void chk_segments_stateChanged(bool state);
130  void chk_edges_stateChanged(bool state);
131 
132  void radio_polar_stateChanged(bool state);
133  void radio_flat_stateChanged(bool state);
134 
135  void btnCapture_clicked();
136 
140 
141  void btnAddTopPose_clicked();
144 
145 };
146 
147 #endif // MAINWINDOW_H
QPushButton * btnDeleteTopPose
Definition: mainwindow.h:77
void calculateTransformationFrames()
Definition: mainwindow.cpp:459
QPushButton * btnCapture
Definition: mainwindow.h:72
QRadioButton * radio_flat
Definition: mainwindow.h:87
QPushButton * btnStartPTUCapture
Definition: mainwindow.h:75
QCheckBox * chk_rawdata
Definition: mainwindow.h:52
void btnPossibleSolutions_Right_clicked()
Definition: mainwindow.cpp:366
QPushButton * btnPossibleSolutions_Right
Definition: mainwindow.h:74
boost::shared_ptr< FeasibilityChecker > feasibilityChecker
Definition: mainwindow.h:107
void btnClearTopPose_clicked()
Definition: mainwindow.cpp:355
void showPossibleSolutions()
Definition: mainwindow.cpp:484
QPushButton * btnAddTopPose
Definition: mainwindow.h:76
QLabel * lblSolutionMatrix
Definition: mainwindow.h:65
QCheckBox * chk_filteredData
Definition: mainwindow.h:54
QCheckBox * chk_segments
Definition: mainwindow.h:55
QCheckBox * chk_edges
Definition: mainwindow.h:56
QPushButton * btnPossibleSolutions_Left
Definition: mainwindow.h:73
void toggleCaptureMode()
Definition: mainwindow.cpp:389
unsigned int showData
Definition: mainwindow.h:50
boost::shared_ptr< ResectionSolver > solver
Definition: mainwindow.h:99
QCheckBox * chk_avgData
Definition: mainwindow.h:53
QLabel * lblTriangles
Definition: mainwindow.h:59
bool isCapturing
Definition: mainwindow.h:51
boost::shared_ptr< Transformation_Publisher > transformationPublisher
Definition: mainwindow.h:109
void radio_polar_stateChanged(bool state)
Definition: mainwindow.cpp:316
MainWindow(QWidget *parent=0)
Definition: mainwindow.cpp:24
void chk_avgData_stateChanged(bool state)
Definition: mainwindow.cpp:292
int possibleSolutions_Position
Definition: mainwindow.h:82
void btnDeleteTopPose_clicked()
Definition: mainwindow.cpp:343
void btnPossibleSolutions_Left_clicked()
Definition: mainwindow.cpp:360
boost::shared_ptr< Calibration_Object > calibrationObject
Definition: mainwindow.h:105
boost::shared_ptr< MarkerPublisher > markerPublisher
Definition: mainwindow.h:102
void btnStartPTUCapture_clicked()
Definition: mainwindow.cpp:372
void btnAddTopPose_clicked()
Definition: mainwindow.cpp:330
std::vector< Eigen::Vector2d, Eigen::aligned_allocator< Eigen::Vector2d > > * selectedTriangle
Definition: mainwindow.h:91
std::vector< Eigen::Vector3d, Eigen::aligned_allocator< Eigen::Vector3d > > * capturedTopPoses
Definition: mainwindow.h:94
QLabel * lblCurrentTriangle
Definition: mainwindow.h:63
void setCurves(unsigned int showData=1)
void trianglesFound(std::vector< Eigen::Vector2d, Eigen::aligned_allocator< Eigen::Vector2d > > *triangles)
Definition: mainwindow.cpp:563
QRadioButton * radio_polar
Definition: mainwindow.h:86
void chk_rawData_stateChanged(bool state)
Definition: mainwindow.cpp:286
QPushButton * btnClearTopPose
Definition: mainwindow.h:78
void newTransform_Laserscan(const Eigen::Matrix4d &transform, double distanceToTop)
LaserScanWidget * widget
Definition: mainwindow.h:88
void chk_edges_stateChanged(bool state)
Definition: mainwindow.cpp:310
std::vector< Eigen::Vector2d, Eigen::aligned_allocator< Eigen::Vector2d > > * currentTriangles
Definition: mainwindow.h:90
boost::shared_ptr< TF_Visualizer > tfVisualizer
Definition: mainwindow.h:112
QLabel * lblPossibleSolutions_Position
Definition: mainwindow.h:67
LaserScanThread * currentThread
Definition: mainwindow.h:84
void chk_segments_stateChanged(bool state)
Definition: mainwindow.cpp:304
std::vector< Eigen::Matrix4d, Eigen::aligned_allocator< Eigen::Matrix4d > > * solutionFrames
Definition: mainwindow.h:97
void resizeEvent(QResizeEvent *event)
Definition: mainwindow.cpp:251
QLabel * lblTopPoseVariance
Definition: mainwindow.h:70
QLabel * lblSolutions
Definition: mainwindow.h:61
void addMatrixRow(QString *text, double value)
Definition: mainwindow.cpp:556
void radio_flat_stateChanged(bool state)
Definition: mainwindow.cpp:320
QListWidget * lstTopPose
Definition: mainwindow.h:80
void btnCapture_clicked()
Definition: mainwindow.cpp:325
void chk_filteredData_stateChanged(bool state)
Definition: mainwindow.cpp:298


asr_mild_calibration_tool
Author(s): Aumann Florian, Heller Florian, Meißner Pascal
autogenerated on Mon Dec 2 2019 03:11:43