Subversion Repositories seema-scanner

Rev

Rev 67 | Rev 75 | 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"
4 jakw 12
#include "SMCaptureWorker.h"
27 jakw 13
#include "SMCalibrationWorker.h"
14
#include "SMReconstructionWorker.h"
4 jakw 15
 
16
#include <opencv2/opencv.hpp>
17
#include <pcl/point_cloud.h>
18
#include <pcl/point_types.h>
19
 
23 jakw 20
 
1 jakw 21
namespace Ui {
23 jakw 22
    class SMScanner;
1 jakw 23
}
24
 
23 jakw 25
class SMScanner : public QMainWindow{
1 jakw 26
    Q_OBJECT
27
 
23 jakw 28
    public:
29
        explicit SMScanner(QWidget *parent = 0);
30
        void closeEvent(QCloseEvent *event);
31
        ~SMScanner();
1 jakw 32
 
23 jakw 33
    private slots:
34
        void on_actionPreferences_triggered();
73 jakw 35
        void onPreferencesChanged();
4 jakw 36
 
23 jakw 37
        void onReceiveFrame(unsigned int camId, cv::Mat frame);
27 jakw 38
        void onReceiveCalibrationSet(SMCalibrationSet calibrationSet);
39
        void onReceiveFrameSequence(SMFrameSequence frameSequence);
30 jakw 40
        void onReceiveRotatedTo(float angle);
27 jakw 41
 
26 jakw 42
        void onCalibrationSetProcessed(int idx);
29 jakw 43
        void onCalibrationFrameResult(int idx, int camID, bool success, cv::Mat result);
27 jakw 44
 
23 jakw 45
        void on_singleCalibrationButton_clicked();
46
 
27 jakw 47
        void on_calibrateButton_clicked();
48
 
49
        void onCalibrationDone();
50
        void on_calibrationListWidget_itemSelectionChanged();
51
 
52
        void on_singleCaptureButton_clicked();
53
 
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
 
41 jakw 69
        void on_reconstructButton_clicked();
42 jakw 70
        void onNewPointCloud(SMPointCloud pc);
41 jakw 71
 
44 jakw 72
        void on_actionExport_Point_Clouds_triggered();
42 jakw 73
 
44 jakw 74
        void on_pointCloudsListWidget_itemChanged(QListWidgetItem *item);
75
 
76
        void on_actionExport_Parameters_triggered();
77
 
67 jakw 78
        void on_actionClear_Sequences_triggered();
79
 
1 jakw 80
private:
23 jakw 81
        Ui::SMScanner *ui;
4 jakw 82
 
23 jakw 83
        QSettings settings;
4 jakw 84
 
23 jakw 85
        SMPreferenceDialog preferenceDialog;
4 jakw 86
 
23 jakw 87
        SMCaptureWorker *captureWorker;
88
        QThread *captureWorkerThread;
4 jakw 89
 
27 jakw 90
        SMCalibrationWorker *calibrationWorker;
91
        QThread *calibrationWorkerThread;
4 jakw 92
 
27 jakw 93
        SMReconstructionWorker *reconstructionWorker;
94
        QThread *reconstructionWorkerThread;
95
 
96
        std::vector< SMCalibrationSet > calibrationData;
97
        std::vector< SMFrameSequence > captureData;
41 jakw 98
        std::vector< SMPointCloud > pointCloudData;
25 jakw 99
 
67 jakw 100
        int lastCaptureId;
101
 
25 jakw 102
        bool calibrationReviewMode;
27 jakw 103
        bool captureReviewMode;
1 jakw 104
};
105
 
106
#endif // SMSCANNER_H