21 #ifndef __ctkVTKAbstractView_h 22 #define __ctkVTKAbstractView_h 28 #include <QVTKWidget.h> 32 #include "ctkVisualizationVTKWidgetsExport.h" 33 class ctkVTKAbstractViewPrivate;
35 class vtkCornerAnnotation;
36 class vtkInteractorObserver;
37 class vtkRenderWindowInteractor;
38 class vtkRenderWindow;
45 Q_PROPERTY(QString cornerAnnotationText READ cornerAnnotationText WRITE setCornerAnnotationText)
46 Q_PROPERTY(QColor backgroundColor READ backgroundColor WRITE setBackgroundColor)
47 Q_PROPERTY(QColor backgroundColor2 READ backgroundColor2 WRITE setBackgroundColor)
48 Q_PROPERTY(
bool gradientBackground READ gradientBackground WRITE setGradientBackground)
49 Q_PROPERTY(
bool renderEnabled READ renderEnabled WRITE setRenderEnabled)
53 Q_PROPERTY(
bool fpsVisible READ isFPSVisible WRITE setFPSVisible)
57 Q_PROPERTY(
bool useDepthPeeling READ useDepthPeeling WRITE setUseDepthPeeling)
69 virtual
void scheduleRender();
74 virtual
void forceRender();
77 virtual
void setBackgroundColor(const QColor& newBackgroundColor);
81 virtual
void setBackgroundColor2(const QColor& newBackgroundColor);
85 virtual
void setGradientBackground(
bool enable);
88 void setRenderEnabled(
bool value);
91 virtual
void setCornerAnnotationText(const QString& text);
94 void setFPSVisible(
bool show);
98 void setUseDepthPeeling(
bool use);
102 Q_INVOKABLE vtkRenderWindow* renderWindow()const;
105 Q_INVOKABLE vtkRenderWindowInteractor* interactor()const;
110 virtual
void setInteractor(vtkRenderWindowInteractor* interactor);
113 Q_INVOKABLE vtkInteractorObserver* interactorStyle()const;
116 QString cornerAnnotationText() const;
117 Q_INVOKABLE vtkCornerAnnotation* cornerAnnotation()const;
120 Q_INVOKABLE QVTKWidget * VTKWidget() const;
123 virtual QColor backgroundColor() const;
126 virtual QColor backgroundColor2() const;
129 virtual
bool gradientBackground() const;
132 bool renderEnabled() const;
135 bool isFPSVisible() const;
142 bool useDepthPeeling()const;
153 static
void setMultiSamples(
int);
157 static
int multiSamples();
159 virtual QSize minimumSizeHint()const;
160 virtual QSize sizeHint()const;
161 virtual
bool hasHeightForWidth()const;
162 virtual
int heightForWidth(
int width)const;
169 QScopedPointer<ctkVTKAbstractViewPrivate> d_ptr;
170 ctkVTKAbstractView(ctkVTKAbstractViewPrivate* pimpl, QWidget* parent);
173 Q_DECLARE_PRIVATE(ctkVTKAbstractView);
174 Q_DISABLE_COPY(ctkVTKAbstractView);
#define QVTK_OBJECT
Define VTK/Qt event/slot connection utility methods. It is a convenient macro that declares and defin...