1 #ifndef __cpExtensions__QT__ImageWidget__h__
2 #define __cpExtensions__QT__ImageWidget__h__
4 #include <cpExtensions/QT/RendererWidget.h>
6 #ifdef cpExtensions_QT4
10 namespace cpExtensions
12 namespace Visualization
14 class ImageSliceActors;
15 class ImageViewerActors;
17 namespace Interaction { class ImageSliceStyle; }
23 class cpExtensions_EXPORT ImageWidget
24 : public RendererWidget
29 typedef ImageWidget Self;
30 typedef RendererWidget Superclass;
33 explicit ImageWidget( QWidget* parent = NULL, Qt::WindowFlags f = 0 );
34 virtual ~ImageWidget( );
36 vtkInteractorStyle* GetInteractorStyle( );
37 const vtkInteractorStyle* GetInteractorStyle( ) const;
40 vtkImageData* image, int orientation, const std::string& name
42 void Add( vtkDataSet* data, const std::string& name );
44 // TODO: std::vector< vtkProp* > GetActors( const std::string& name ) const;
45 int GetOrientation( ) const;
46 void SetSliceNumber( int slice );
48 virtual void ResetCamera( ) cpExtensions_OVERRIDE;
50 void GetScalarRange( double r[ 2 ] ) const;
51 void GetWindowLevel( double wl[ 2 ] ) const;
52 double GetImageOpacity( ) const;
53 unsigned char GetImageInterpolation( ) const;
55 void SetScalarRange( double r[ 2 ] );
56 void SetWindowLevel( double wl[ 2 ] );
57 void SetImageOpacity( double o );
58 void SetImageInterpolation( unsigned char i );
61 vtkSmartPointer< cpExtensions::Visualization::ImageViewerActors >
63 vtkSmartPointer< cpExtensions::Interaction::ImageSliceStyle >
65 std::string m_ImageName;
72 #endif // cpExtensions_QT4
74 #endif // __cpExtensions__QT__ImageWidget__h__