]> Creatis software - creaMaracasVisu.git/blob - lib/maracasVisuLib/src/interface/wxWindows/widgets/wxMaracas_ViewerWidget.h
ViewerNV 2D with color Transfer Function
[creaMaracasVisu.git] / lib / maracasVisuLib / src / interface / wxWindows / widgets / wxMaracas_ViewerWidget.h
1 /*=========================================================================
2
3   Program:   wxMaracas
4   Module:    $RCSfile: wxMaracas_ViewerWidget.h,v $
5   Language:  C++
6   Date:      $Date: 2009/07/27 07:58:20 $
7   Version:   $Revision: 1.7 $
8
9   Copyright: (c) 2002, 2003
10   License:
11   
12      This software is distributed WITHOUT ANY WARRANTY; without even 
13      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
14      PURPOSE.  See the above copyright notice for more information.
15
16 =========================================================================*/
17
18 #ifndef __WX__MARACAS__VIEWERWIDGET__H__
19 #define __WX__MARACAS__VIEWERWIDGET__H__
20
21
22 // -----------------------------------------------------------------------------------------------------------
23 // WX headers inclusion.
24 // For compilers that support precompilation, includes <wx/wx.h>.
25 // -----------------------------------------------------------------------------------------------------------
26 #include <wx/wxprec.h>
27 #ifdef __BORLANDC__
28 #pragma hdrstop
29 #endif
30 #ifndef WX_PRECOMP
31 #include <wx/wx.h>
32 #endif
33
34 //------------------------------------------------------------------------------------------------------------
35 // Includes
36 //------------------------------------------------------------------------------------------------------------
37
38 #include "vtkImageData.h"
39 #include "vtkRenderer.h"
40
41 #include "wxVtkBaseView.h"
42 #include "wxMPRWidget.h"
43
44 //------------------------------------------------------------------------------------------------------------
45 // Class definition
46 //------------------------------------------------------------------------------------------------------------
47
48
49  class wxMaracas_ViewerWidget : public wxPanel
50   {
51   public:
52           
53         //------------------------------------------------------------------------------------------------------------
54         // Constructors & Destructors
55         //------------------------------------------------------------------------------------------------------------
56
57     wxMaracas_ViewerWidget(wxWindow *parent, vtkImageData* imagedata, int type, vtkMPRBaseData *vtkmprbasedata=NULL);
58     ~wxMaracas_ViewerWidget();
59
60         //------------------------------------------------------------------------------------------------------------
61         // Methods
62         //------------------------------------------------------------------------------------------------------------
63
64 //    vtkRenderer *GetRenderer();
65         void ConfigureVTK();
66         void RefreshView();
67         virtual void Refresh(bool eraseBackground = true,const wxRect* rect = NULL );
68
69         wxVtkBaseView *GetwxVtkBaseView();
70         void SetImage( vtkImageData *image      );
71         double GetX();
72         double GetY();
73         double GetZ();
74
75         //------------------------------------------------------------------------------------------------------------
76         // Attributes
77         //------------------------------------------------------------------------------------------------------------
78
79         void setColorTransferFunction(vtkColorTransferFunction* colortable);
80   private:
81                 int                                                             mType;
82
83                 bool                            minternalVtkmprbasedata;
84                 vtkMPRBaseData                                  *mvtkmprbasedata; 
85
86                 wxVtk2DBaseView                                 *mvtk2Dbaseview;
87                 wxVtkMPR2DView                                  *mvtkmpr2Dview_X; 
88                 wxVtkMPR2DView                                  *mvtkmpr2Dview_Y; 
89                 wxVtkMPR2DView                                  *mvtkmpr2Dview_Z; 
90                 wxWidgetMesure2D_Plane_in_MPR   *mwidgetMesure;
91                 vtkPlane2DView                                  *mvtkplane2Dview;
92                 wxSphereView                                    *mwxsphereview; 
93
94                 wxVtkClipping3DView                             *mwxvtkclipping3Dview;
95                 wxVtk3DBaseView                                 *mwxvtk3Dbaseview_Clipping3D;
96                 wxVtkMPR3DView                                  *mwxvtkmpr3Dview;
97
98
99                 vtkMPR3DDataViewer                              *vtkmpr3Ddataviewer;
100
101
102   };
103
104 #endif // __WX__MARACAS__VIEWERWIDGET__H__