-
Notifications
You must be signed in to change notification settings - Fork 8
/
MainWindow.h
96 lines (81 loc) · 2.32 KB
/
MainWindow.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
// Copyright (C) 2019 Piotr (Peter) Beben <[email protected]>
// See LICENSE included with this distribution.
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
#include "constants.h"
//#include <pcl/io/pcd_io.h>
#include <pcl/point_types.h>
#include <pcl/point_cloud.h>
#include <QMainWindow>
QT_BEGIN_NAMESPACE
class QAction;
class QMenu;
class QPlainTextEdit;
class QListWidget;
QT_END_NAMESPACE
class GLWidget;
class Window;
class MessageLogger;
class RandomSurfDialog;
class BoundBoxDialog;
class NormalsDialog;
class DecimateDialog;
class SparsifyDialog;
class ReconstructDialog;
class OptionsDialog;
class MainWindow : public QMainWindow
{
Q_OBJECT
typedef pcl::PointCloud<pcl::PointXYZ>::Ptr CloudPtr;
public:
explicit MainWindow(QWidget *parent = nullptr);
void badInputMessageBox(const QString& info);
private:
void open();
void saveAs();
void undo();
void viewGLNorms(bool enabled);
void setRandom();
void setBBox();
void approxNorms();
void decimate();
void sparsify();
void reconstruct();
void options();
void about();
public slots:
void changeBBoxFields(float minBBox[3], float maxBBox[3]);
void appendLogText(const QString& text);
void insertLogText(const QString& text);
signals:
void cloudChanged(CloudPtr cloud);
void cloudQueried(CloudPtr& cloud);
void cloudUndo();
void cloudNormsViewGL(bool enabled);
void cloudSetRandom(size_t nPoints);
void cloudSetBBox(float minBBox[3], float maxBBox[3]);
void cloudApproxNorms(int nIters, size_t kNN);
void cloudDecimate(size_t nHoles, size_t kNN);
void cloudSparsify(float percent);
void cloudReconstruct(
int kSVDIters, size_t kNN, size_t nfreq, float densify,
size_t natm, size_t latm, size_t maxNewPoints, bool looseBBox,
SparseApprox method);
void pointSizeChanged(float size);
void normScaleChanged(float scale);
private:
Window *centralWidget;
QToolBar *mainToolBar;
QStatusBar *statusBar;
QToolBar *toolBar;
QPlainTextEdit *logText;
RandomSurfDialog *randomSurfDialog;
BoundBoxDialog *boundBoxDialog;
NormalsDialog *normalsDialog;
DecimateDialog *decimateDialog;
SparsifyDialog *sparsifyDialog;
ReconstructDialog *reconstructDialog;
OptionsDialog *optionsDialog;
MessageLogger *msgLogger;
};
#endif // MAINWINDOW_H