34 #ifndef __QGoImageView_h
35 #define __QGoImageView_h
38 #include "vtkSmartPointer.h"
52 #include "vtkPoints.h"
53 #include "vtkSeedRepresentation.h"
55 class vtkConstrainedPointHandleRepresentation;
56 class vtkImageActorPointPlacer;
59 class vtkDistanceWidget;
65 class vtkContourWidget;
66 class vtkOrientedGlyphContourRepresentation;
67 class vtkDistanceRepresentation2D;
69 #include "QGoGUILibConfigure.h"
86 virtual void SetImage(vtkImageData *iImage) = 0;
89 vtkImageData * GetImage();
92 int *GetImageCoordinatesFromWorldCoordinates(
double pos[3]);
96 void SetIntersectionLineWidth(
const float& iWidth );
99 virtual QVTKInteractor * GetInteractor(
const int &) = 0;
103 virtual void retranslateUi(
QWidget *parent) = 0;
109 void GetBackgroundColor(
double & r,
double & g,
double & b);
112 double * GetBackgroundColor();
121 int GetNumberOfImageViewers();
123 virtual void RemoveActor(
const int & iId, vtkActor *iActor);
125 virtual void AddActor(
const int & iId, vtkActor *iActor);
136 virtual std::vector< vtkActor * > AddContour(vtkPolyData *iDataset,
137 vtkProperty *iProperty = NULL);
157 void EnableContourPickingMode();
162 void ResetWindowLevel();
167 void SetLookupTable(vtkLookupTable *iLut);
172 void ShowScalarBar(
const bool &);
177 vtkImageActor * GetImageActor(
const int & iId);
182 void ShowSplinePlane();
187 void SetInterpolate(
const int & val);
189 virtual void ChangeCursorShape(
QCursor iCursorShape) = 0;
194 void InitializeDistanceWidget();
196 void EnableDistanceWidget(
bool iEnable);
201 void InitializeAngleWidget();
203 void EnableAngleWidget(
bool iActive);
208 void InitializeContourWidget();
210 void EnableContourWidget(
bool iActivate);
212 void InitializeContourWidgetNodes(
int iDir, vtkPolyData *iNodes);
214 vtkPolyData * GetContourRepresentationAsPolydata(
int iDir);
216 vtkPolyData * GetContourRepresentationNodePolydata(
int iDir);
221 void InitializeSeedWidget();
223 void EnableSeedWidget(
bool iEnable);
229 void GetSeeds( std::vector<vtkPoints*>& iPoints );
236 void SetBackgroundColor(
const double & r,
241 void SetBackgroundColor(
double rgb[3]);
243 void SetBackgroundColor(
const QColor & iColor);
248 void ShowAnnotations();
253 void ClearAllSeeds();
255 void UpdateContourRepresentationProperties(
float linewidth,
QColor linecolor,
258 void ReinitializeContourWidget();
263 void UpdateRenderWindows();
271 std::vector< vtkSmartPointer< vtkConstrainedPointHandleRepresentation > >
m_Handle;
272 std::vector< vtkSmartPointer< vtkSeedRepresentation > >
m_SeedRep;
Abstract class for the visualization of 3D Image represented by one vtkImageData*.
Manage a collection of 2D views.
std::vector< vtkSmartPointer< vtkContourWidget > > m_ContourWidget
std::vector< vtkSmartPointer< vtkSeedWidget > > m_SeedWidget
std::vector< vtkSmartPointer< vtkDistanceWidget > > m_DistanceWidget
std::vector< vtkSmartPointer< vtkAngleWidget > > m_AngleWidget
unsigned int m_SnapshotId
QColor m_ActiveNodesColor
std::vector< vtkSmartPointer< vtkSeedRepresentation > > m_SeedRep
std::vector< vtkSmartPointer< vtkConstrainedPointHandleRepresentation > > m_Handle
float m_IntersectionLineWidth
vtkViewImage2DCollection * m_Pool
Basic class to handle 2D/3D items such as images and polydatas visualization in 2D.
std::vector< vtkSmartPointer< vtkOrientedGlyphContourRepresentation > > m_ContourRepresentation