1 /*=========================================================================
4 Module: $RCSfile: wxMaracasMultipleVolumeRendererView.h,v $
6 Date: $Date: 2009/11/20 17:09:05 $
7 Version: $Revision: 1.5 $
9 Copyright: (c) 2002, 2003
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.
16 =========================================================================*/
18 #ifndef __wxMaracasMultipleVolumeRendererViewPanelH__
19 #define __wxMaracasMultipleVolumeRendererViewPanelH__
23 #include "wx/aui/aui.h"
26 #include "vtkProp3D.h"
28 #include "wxMaracasMultipleVolumeRendererManager.h"
29 #include "wxMaracasMultipleVolumeRendererPanel.h"
33 class creaMaracasVisu_EXPORT wxMaracasMultipleVolumeRendererView : public wxPanel
37 wxMaracasMultipleVolumeRendererView( wxWindow* parent, std::string path);
38 ~wxMaracasMultipleVolumeRendererView( );
40 static wxMaracasMultipleVolumeRendererView* getInstance(wxWindow* parent,std::string path="");
42 static wxMaracasMultipleVolumeRendererView* getInstance();
44 void setRenderer(vtkRenderer* renderer);
46 void addVolume(vtkImageData* img, std::string dataname="");
48 void loadVolume(wxString filename, wxString dataname);
50 void onLoadImageFile();
52 void addVolumeRendererPanel(wxMaracasMultipleVolumeRendererPanel* irmview, std::string dataname="");
54 std::string getPath();
56 void deleteVolume(int volid);
58 void addRemoveActor(int id, bool remove);
60 void SetValuesColorPointsFunction(int volid, std::vector<double> greylevelcolors,std::vector<double> red,std::vector<double> green,std::vector<double> blue);
61 void SetValuesPointsFunction(int volid, std::vector<double> greylevel, std::vector<double> values);
63 void addVolumeViewPanel(wxMaracasMultipleVolumeRendererPanel* irmview, std::string dataname);
65 vtkPiecewiseFunction* GetTransferFunction(int volumeid);
66 vtkColorTransferFunction* GetColorFunction(int volumeid);
68 std::vector<vtkImageData*> GetOutputImages();
70 void changeCompositeMIPFunction(int id, int function);
73 static wxMaracasMultipleVolumeRendererView* instance;
75 wxMaracasMultipleVolumeRendererManager* volmanager;
76 wxAuiManager* wxauimanager;
80 std::vector<vtkImageData*> imgVect;
83 class ToolBarEventHandlerMultipleVolumeRenderer : public wxEvtHandler{
86 ToolBarEventHandlerMultipleVolumeRenderer();
87 ~ToolBarEventHandlerMultipleVolumeRenderer();
89 void onLoadImageFile(wxCommandEvent& event);
96 class ToolBarMultipleVolumeRenderer : public wxToolBar{
100 ToolBarMultipleVolumeRenderer(wxWindow * parent,std::string iconsdir);
101 ~ToolBarMultipleVolumeRenderer(void);
106 ToolBarEventHandlerMultipleVolumeRenderer* _evthand;