ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/qtrvu/mainwindow.h
Revision: 1.2
Committed: Wed May 30 18:31:11 2012 UTC (12 years, 5 months ago) by greg
Content type: text/plain
Branch: MAIN
CVS Tags: rad4R2P2, rad4R2, rad4R2P1
Changes since 1.1: +1 -0 lines
Log Message:
Patches to cmake build system and QT driver for rvu

File Contents

# User Rev Content
1 greg 1.1
2     #ifndef __MainWindow_H
3     #define __MainWindow_H
4    
5     #include <QtGui/QMainWindow>
6     #include "fvect.h"
7     #include "rpaint.h"
8    
9     class QAction;
10     class QDialog;
11     class RvuWidget;
12    
13     namespace Ui
14     {
15     class MainWindow;
16     class exposureDialog;
17     class parameterDialog;
18     class viewDialog;
19     class incrementsDialog;
20     class commandsDialog;
21     }
22    
23     class MainWindow : public QMainWindow
24     {
25     Q_OBJECT
26    
27     public:
28     MainWindow(int width, int height, const char* name, const char* id);
29     ~MainWindow();
30    
31     RvuWidget* getRvuWidget() const;
32     void resizeImage(int width, int height);
33     void setStatus(const char*);
34     void setProgress(int);
35     void pick( int* x, int* y);
36     protected:
37     void closeEvent(QCloseEvent *event);
38     void doSubmit();
39     void updatePositionLabels();
40     void runCommand(const char *command);
41     void move(int direction, float amount);
42     void refreshView(VIEW *nv);
43    
44     protected slots:
45     void buttonPressed();
46     void redraw();
47     void traceRay();
48     void saveImage();
49     void saveCurrentImage();
50     void loadView();
51 greg 1.2 void loadRif();
52 greg 1.1 void toggleToolBar();
53     void toggleTranslateTool();
54     void toggleStatusBar();
55     void moveXPlusOne();
56     void moveXPlusTwo();
57     void moveYPlusOne();
58     void moveYPlusTwo();
59     void moveZPlusOne();
60     void moveZPlusTwo();
61     void moveXMinusOne();
62     void moveXMinusTwo();
63     void moveYMinusOne();
64     void moveYMinusTwo();
65     void moveZMinusOne();
66     void moveZMinusTwo();
67     void showExposureDialog();
68     void hideExposureDialog();
69     void showParameterDialog();
70     void hideParameterDialog();
71     void adjustExposure();
72     void updatePointRadio();
73     void adjustParameters();
74     void showViewDialog();
75     void hideViewDialog();
76     void adjustView();
77     void toggleBackfaceVisibility();
78     void toggleIrradiance();
79     void toggleGrayscale();
80     void appendToRif();
81     void appendToView();
82     void showIncrementsDialog();
83     void hideIncrementsDialog();
84     void adjustIncrements();
85     void showCommandsDialog();
86     void showAbout();
87     /** Enable/disable elements of the UI while rendering. */
88     void enableInterface(bool enable);
89    
90     private:
91     void createActions();
92     void connectSlots();
93    
94     /** Our MainWindow GUI. */
95     Ui::MainWindow *m_ui;
96     QAction *m_minimizeAction;
97     QAction *m_maximizeAction;
98     QAction *m_restoreAction;
99     QAction *m_quitAction;
100    
101     /** Exposure Dialog */
102     QDialog *m_exposureDialog;
103     Ui::exposureDialog *m_exposureDialogUi;
104    
105     /** Parameter Dialog */
106     QDialog *m_parameterDialog;
107     Ui::parameterDialog *m_parameterDialogUi;
108    
109     /** View Dialog */
110     QDialog *m_viewDialog;
111     Ui::viewDialog *m_viewDialogUi;
112    
113     /** Increments Dialog */
114     QDialog *m_incrementsDialog;
115     Ui::incrementsDialog *m_incrementsDialogUi;
116     float smallIncrement;
117     float largeIncrement;
118    
119     /** Commands Dialog */
120     QDialog *m_commandsDialog;
121     Ui::commandsDialog *m_commandsDialogUi;
122    
123     /** save image */
124     QString currentImageName;
125     };
126    
127     #endif