4 #ifndef __bbcreaMaracasVisuContourVOI_h_INCLUDED__
5 #define __bbcreaMaracasVisuContourVOI_h_INCLUDED__
6 #include "bbtkWxBlackBox.h"
9 #include <vtkImageData.h>
10 #include <vtkExtractVOI.h>
12 #include "Contour/ContourVOIWidget.h"
14 namespace bbcreaMaracasVisu
18 //--------------------------------------------------------------------------
20 class wxWidgetVOI : public wxPanel
23 wxWidgetVOI(wxWindow* parent, wxVtkBaseView *wxvtkbaseview=NULL, vtkImageData *imagedata=NULL);
26 //if the MPR had generated the refresh event
27 void OnRefreshView(wxCommandEvent & event);
28 void OnDClickLeft(wxCommandEvent & event);
33 ContourVOIWidget* GetContourVOIWidget();
35 void setImageData(vtkImageData * imagedata);
36 void setBaseView(wxVtkBaseView * wxvtkbaseview);
38 void initializeVOIWidget();
42 // ContourVOI *mbbViewerMPR;
43 ContourVOIWidget *mcontourvoiwidget;
45 wxVtkBaseView * wxvtkbaseview;
46 vtkImageData * imagedata;
51 DECLARE_EVENT_TABLE( );
54 //------------------------------------------------------------------------
55 //------------------------------------------------------------------------
56 //------------------------------------------------------------------------
63 class /*BBTK_EXPORT*/ ContourVOI
65 public bbtk::WxBlackBox
67 BBTK_BLACK_BOX_INTERFACE(ContourVOI,bbtk::WxBlackBox);
68 //==================================================================
69 /// User callback called in the box contructor
70 virtual void bbUserConstructor();
71 /// User callback called in the box copy constructor
72 virtual void bbUserCopyConstructor(bbtk::BlackBox::Pointer);
73 /// User callback called in the box destructor
74 virtual void bbUserDestructor();
75 //==================================================================
76 BBTK_DECLARE_INPUT(Title,std::string);
77 BBTK_DECLARE_INPUT(In, vtkImageData*);
78 BBTK_DECLARE_INPUT(wxVtkBaseView, wxVtkBaseView*);
79 BBTK_DECLARE_OUTPUT(Index,std::string);
80 BBTK_DECLARE_OUTPUT(Size,std::string);
81 BBTK_DECLARE_OUTPUT(VOI,vtkImageData*);
82 BBTK_PROCESS(Process);
84 BBTK_CREATE_WIDGET(CreateWidget);
85 void CreateWidget(wxWindow*);
90 vtkExtractVOI* _extract;
94 BBTK_BEGIN_DESCRIBE_BLACK_BOX(ContourVOI,bbtk::WxBlackBox);
95 BBTK_NAME("ContourVOI");
96 BBTK_AUTHOR("Eduardo.Davila [at] creatis.insa-lyon.fr");
97 BBTK_DESCRIPTION("define VOI widget");
98 //BBTK_CATEGORY("__CategoryBlackBox__");
99 BBTK_INPUT(ContourVOI,Title,"Title prepended to the text",std::string,"");
100 BBTK_INPUT(ContourVOI,In,"Input Image", vtkImageData *,"" );
101 BBTK_INPUT(ContourVOI,wxVtkBaseView,"maracas visu wxVtkBaseView",wxVtkBaseView*,"");
102 BBTK_OUTPUT(ContourVOI,Index, "Index" , std::string,"");
103 BBTK_OUTPUT(ContourVOI,Size, "Size" , std::string,"");
104 BBTK_OUTPUT(ContourVOI,VOI,"Region of interest",vtkImageData*,"");
105 BBTK_END_DESCRIBE_BLACK_BOX(ContourVOI);
107 // EO namespace bbcreaMaracasVisu
109 #endif // __bbcreaMaracasVisuContourVOI_h_INCLUDED__
110 #endif // _USE_WXWIDGETS_