Subversion Repositories seema-scanner

Rev

Rev 227 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1 jakw 1
#ifndef SMSCANNER_H
2
#define SMSCANNER_H
3
 
4
#include <QMainWindow>
4 jakw 5
#include <QSettings>
6
#include <QThread>
7
#include <QCloseEvent>
27 jakw 8
#include <QModelIndex>
44 jakw 9
#include <QListWidgetItem>
1 jakw 10
 
9 jakw 11
#include "SMPreferenceDialog.h"
225 jakw 12
#include "SMLogDialog.h"
4 jakw 13
#include "SMCaptureWorker.h"
27 jakw 14
#include "SMCalibrationWorker.h"
15
#include "SMReconstructionWorker.h"
217 jakw 16
//#include "SMMeshingWorker.h"
4 jakw 17
 
18
#include <opencv2/opencv.hpp>
19
#include <pcl/point_cloud.h>
20
#include <pcl/point_types.h>
21
 
23 jakw 22
 
1 jakw 23
namespace Ui {
23 jakw 24
    class SMScanner;
1 jakw 25
}
26
 
23 jakw 27
class SMScanner : public QMainWindow{
1 jakw 28
    Q_OBJECT
29
 
23 jakw 30
    public:
31
        explicit SMScanner(QWidget *parent = 0);
32
        void closeEvent(QCloseEvent *event);
33
        ~SMScanner();
1 jakw 34
 
23 jakw 35
    private slots:
36
        void on_actionPreferences_triggered();
73 jakw 37
        void onPreferencesChanged();
4 jakw 38
 
23 jakw 39
        void onReceiveFrame(unsigned int camId, cv::Mat frame);
27 jakw 40
        void onReceiveCalibrationSet(SMCalibrationSet calibrationSet);
41
        void onReceiveFrameSequence(SMFrameSequence frameSequence);
30 jakw 42
        void onReceiveRotatedTo(float angle);
27 jakw 43
 
232 jakw 44
        void onReceiveCheckerboardResult(int idx, SMCalibrationSet calibrationSet);
27 jakw 45
 
23 jakw 46
        void on_singleCalibrationButton_clicked();
47
 
225 jakw 48
        void on_calibrateCamerasButton_clicked();
27 jakw 49
 
225 jakw 50
        void onReceiveCalibrationDone();
27 jakw 51
        void on_calibrationListWidget_itemSelectionChanged();
52
 
53
        void on_singleCaptureButton_clicked();
54
 
23 jakw 55
        void on_calibrationRotationDial_sliderReleased();
56
 
27 jakw 57
        void on_captureRotationDial_sliderReleased();
25 jakw 58
 
27 jakw 59
        void on_captureTreeWidget_itemSelectionChanged();
25 jakw 60
 
30 jakw 61
        void on_batchCalibrationButton_clicked();
62
 
63
        void on_batchCaptureButton_clicked();
64
 
36 jakw 65
        void on_actionExport_Sets_triggered();
66
 
67
        void on_actionExport_Sequences_triggered();
68
 
148 jakw 69
        void onReceivePointCloud(SMPointCloud pc);
41 jakw 70
 
44 jakw 71
        void on_actionExport_Point_Clouds_triggered();
42 jakw 72
 
44 jakw 73
        void on_pointCloudsListWidget_itemChanged(QListWidgetItem *item);
74
 
75
        void on_actionExport_Parameters_triggered();
76
 
67 jakw 77
        void on_actionClear_Sequences_triggered();
78
 
117 jakw 79
        void on_actionExport_White_Frames_triggered();
80
 
135 jakw 81
        void on_actionImport_Parameters_triggered();
82
 
83
        void on_actionImport_Sets_triggered();
84
 
139 jakw 85
        void on_actionImport_Sequences_triggered();
86
 
87
        void on_actionClear_Point_Clouds_triggered();
88
 
159 jakw 89
        void on_calibrationRotationSpinBox_editingFinished();
90
 
91
        void on_captureRotationSpinBox_editingFinished();
92
 
199 jakw 93
        void on_actionProject_Focusing_Pattern_triggered();
94
 
225 jakw 95
        void on_calibrateRotationStageButton_clicked();
96
 
97
        void on_actionView_Log_Messages_triggered();
98
 
227 jakw 99
        void on_tabWidget_currentChanged(int index);
100
 
232 jakw 101
        void on_calibrationListWidget_currentRowChanged(int currentRow);
102
 
1 jakw 103
private:
23 jakw 104
        Ui::SMScanner *ui;
4 jakw 105
 
23 jakw 106
        QSettings settings;
4 jakw 107
 
23 jakw 108
        SMPreferenceDialog preferenceDialog;
225 jakw 109
        SMLogDialog logDialog;
4 jakw 110
 
23 jakw 111
        SMCaptureWorker *captureWorker;
112
        QThread *captureWorkerThread;
4 jakw 113
 
27 jakw 114
        SMCalibrationWorker *calibrationWorker;
115
        QThread *calibrationWorkerThread;
4 jakw 116
 
27 jakw 117
        SMReconstructionWorker *reconstructionWorker;
118
        QThread *reconstructionWorkerThread;
119
 
225 jakw 120
        std::vector< SMCalibrationSet > calibrationData;
208 flgw 121
 
27 jakw 122
        std::vector< SMFrameSequence > captureData;
41 jakw 123
        std::vector< SMPointCloud > pointCloudData;
25 jakw 124
 
125
        bool calibrationReviewMode;
27 jakw 126
        bool captureReviewMode;
75 jakw 127
        int lastCaptureId;
225 jakw 128
 
1 jakw 129
};
130
 
131
#endif // SMSCANNER_H