aboutsummaryrefslogtreecommitdiff
path: root/src/mainwindow.h
blob: d8a1dc165037a614253460a18eaf1c3ae008d0fe (plain)
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
#pragma once

#include <QMainWindow>
#include <QCheckBox>
#include <QSlider>
#include <QSpinBox>
#include <QDoubleSpinBox>
#include <QPushButton>
#include <QLabel>
#include "raytracer/raytracer.h"
#include "utils/aspectratiowidget/aspectratiowidget.hpp"

class MainWindow : public QWidget
{
    Q_OBJECT

public:
    void initialize();
    void finish();
    QLabel *imageLabel;

private:
    void connectUIElements();
    void connectUploadFile();
    void connectSaveImage();
    void connectBulkRender();
    void connectxy();
    void connectxz();
    void connectxw();
    void connectyz();
    void connectyw();
    void connectzw();
    void connectMaxTimeSlider();
    void connectNegativeRotation();
    void connectW();

    RayTracer *rayTracer;
    AspectRatioWidget *aspectRatioWidget;
    QPushButton *uploadFile;
    QPushButton *saveImage;
    QPushButton *bulkRender;
    QSlider *xySlider;
    QDoubleSpinBox *xyBox;
    QSlider *xzSlider;
    QDoubleSpinBox *xzBox;
    QSlider *xwSlider;
    QDoubleSpinBox *xwBox;
    QSlider *yzSlider;
    QDoubleSpinBox *yzBox;
    QSlider *ywSlider;
    QDoubleSpinBox *ywBox;
    QSlider *zwSlider;
    QDoubleSpinBox *zwBox;
    QSlider *maxTimeSlider;
    QSpinBox *maxTimeSpinBox;
    QPushButton *rotateNegative;
    QSlider *wSlider;
    QDoubleSpinBox *wBox;


private slots:
    void onUploadFile();
    void onSaveImage();
    void onBulkRender();
    void onValChangexySlider(int newValue);
    void onValChangexyBox(double newValue);
    void onValChangexzSlider(int newValue);
    void onValChangexzBox(double newValue);
    void onValChangexwSlider(int newValue);
    void onValChangexwBox(double newValue);
    void onValChangeyzSlider(int newValue);
    void onValChangeyzBox(double newValue);
    void onValChangeywSlider(int newValue);
    void onValChangeywBox(double newValue);
    void onValChangezwSlider(int newValue);
    void onValChangezwBox(double newValue);
    void onValChangeMaxTimeSlider(int newValue);
    void onValChangeMaxTimeBox(double newValue);
    void onRotateNegative();
    void updateXySlider(double newValue);
    void updateXzSlider(double newValue);
    void updateXwSlider(double newValue);
    void updateYzSlider(double newValue);
    void updateYwSlider(double newValue);
    void updateZwSlider(double newValue);
    void updateRotationSlider(float newValue);
    void onValChangeWSlider(int newValue);
    void onValChangeWBox(double newValue);
    // void updateCameraPosition();
};