-
Notifications
You must be signed in to change notification settings - Fork 5
/
VolumeRenderer.h
83 lines (67 loc) · 2 KB
/
VolumeRenderer.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
#ifndef VOLUMERENDERER_H
#define VOLUMERENDERER_H
#include <QtGui/QMainWindow>
#include "ui_VolumeRenderer.h"
#include <QMainWindow>
#include <QApplication>
#include <QMessageBox>
#include <QFileDialog>
#include <iostream>
#include <memory>
#include <cstdlib>
#ifdef VTK_OPENGL2
#include <vtk_glew.h>
#include <QVTKWidget2.h>
#else
#include <vtkgl.h>
#include <QVTKWidget.h>
#endif
#include <vtkSmartPointer.h>
#include <vtkRenderer.h>
#include <vtkRenderWindow.h>
#include <vtkRenderWindowInteractor.h>
#include <vtkColorTransferFunction.h>
#include <vtkPiecewiseFunction.h>
#include <vtkGPUVolumeRayCastMapper.h>
#include <vtkColorTransferFunction.h>
#include <vtkPiecewiseFunction.h>
#include <vtkVolumeProperty.h>
#include <vtkMetaImageReader.h>
#include <vtkVolume16Reader.h>
#include <vtkNew.h>
#include <vtkNrrdReader.h>
#include <vtkImageShiftScale.h>
#include <vtkInteractorStyleTrackballCamera.h>
#include <vtkRendererCollection.h>
#include "ctkTransferFunction.h"
#include "ctkVTKColorTransferFunction.h"
#include "ctkTransferFunctionView.h"
#include "ctkTransferFunctionGradientItem.h"
#include "ctkTransferFunctionControlPointsItem.h"
#include "ctkVTKVolumePropertyWidget.h"
#include "vtkSlicerGPURayCastVolumeMapper.h"
namespace Ui{
class VolumeRenderer;
}
class VolumeRenderer : public QMainWindow
{
Q_OBJECT
public:
VolumeRenderer(QWidget *parent = 0, Qt::WFlags flags = 0);
~VolumeRenderer();
void SetInputImage(QString fileName);
private:
Ui::VolumeRenderer *ui;
QString filename;
vtkSmartPointer<vtkRenderWindowInteractor> interactor;
QVTKWidget widget;
ctkVTKVolumePropertyWidget volumePropertywidget;
private slots:
void on_actionOpenImage_triggered();
void on_action_Exit_triggered();
void on_action_About_triggered();
void on_action_vtkSlicerGPURayCastVolumeMapper_triggered();
void on_action_vtkGPUVolumeRayCastMapper_triggered();
void on_actionScreenshotViewPane_triggered();
};
#endif // VOLUMERENDERER_H