-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathmainwindow.h
More file actions
65 lines (52 loc) · 1.34 KB
/
mainwindow.h
File metadata and controls
65 lines (52 loc) · 1.34 KB
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
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
#include "Atmosphere.h"
#include <QMainWindow>
#include <QtConcurrent>
#include <vsgXchange/all.h>
#include <vsg/all.h>
QT_BEGIN_NAMESPACE
namespace Ui { class MainWindow; }
QT_END_NAMESPACE
class DatabaseException : QException
{
public:
DatabaseException(const QString &path)
: err_path(path)
{
}
QString getErrPath() { return err_path; }
void raise() const override { throw *this; }
DatabaseException *clone() const override { return new DatabaseException(*this); }
private:
QString err_path;
};
class MainWindow : public QMainWindow
{
Q_OBJECT
public:
MainWindow(QWidget *parent = nullptr);
~MainWindow();
public slots:
void generate();
void setImagePath();
void setSettingsPath();
void openImage(const QString &text);
void openSettings(const QString &text);
private:
Ui::MainWindow *ui;
enum Mask : uint64_t
{
Tiles = 0b1,
SceneObjects = 0b10,
Points = 0b100,
Letters = 0b1000,
Tracks = 0b10000
};
vsg::ref_ptr<vsg::Data> _defaultTexture;
vsg::ref_ptr<atmosphere::AtmosphereModelSettings> _atmosphereSettings;
QFutureWatcher<vsg::ref_ptr<vsg::PagedLOD>> *_watcher;
vsg::ref_ptr<vsg::Options> _options;
vsg::ref_ptr<vsg::Builder> _builder;
};
#endif // MAINWINDOW_H