]> Creatis software - creaMaracasVisu.git/blob - bbtk/src/bbmaracasvisuContourCrown.h
BUG Axis viewer
[creaMaracasVisu.git] / bbtk / src / bbmaracasvisuContourCrown.h
1 #ifdef _USE_WXWIDGETS_
2 #ifndef __bbcreaMaracasVisuContourCrown_h_INCLUDED__
3 #define __bbcreaMaracasVisuContourCrown_h_INCLUDED__
4 #include "bbtkWxBlackBox.h"
5
6 #include <vtkImageData.h>
7
8 #include "Contour/ContourCrownWidget.h"
9
10 namespace bbcreaMaracasVisu
11 {
12
13 class /*BBTK_EXPORT*/ ContourCrown
14  : 
15    public bbtk::WxBlackBox
16 {
17   BBTK_BLACK_BOX_INTERFACE(ContourCrown,bbtk::WxBlackBox);
18 //==================================================================
19 /// User callback called in the box contructor
20 virtual void bbUserConstructor();
21 /// User callback called in the box copy constructor
22 virtual void bbUserCopyConstructor(bbtk::BlackBox::Pointer);
23 /// User callback called in the box destructor
24 virtual void bbUserDestructor();
25 //==================================================================
26     BBTK_DECLARE_INPUT(In, vtkImageData*);
27     BBTK_DECLARE_INPUT(wxVtkBaseView, wxVtkBaseView*);
28 //JSTG 26-02-08 -------------------------------------------------------
29     BBTK_DECLARE_INPUT(ControlPointsInX,std::vector<double>*);
30         BBTK_DECLARE_INPUT(ControlPointsInY,std::vector<double>*);
31         BBTK_DECLARE_INPUT(ControlPointsInZ,std::vector<double>*);
32 //---------------------------------------------------------------------
33         BBTK_DECLARE_OUTPUT(LstValue,std::vector<double>*);
34         BBTK_DECLARE_OUTPUT(LstValuePosX,std::vector<double>*);
35         BBTK_DECLARE_OUTPUT(LstValuePosY,std::vector<double>*);
36         BBTK_DECLARE_OUTPUT(LstValuePosZ,std::vector<double>*);
37         BBTK_DECLARE_OUTPUT(LstContourX,std::vector<double>*);
38         BBTK_DECLARE_OUTPUT(LstContourY,std::vector<double>*);
39         BBTK_DECLARE_OUTPUT(LstContourZ,std::vector<double>*);
40         BBTK_DECLARE_OUTPUT(LstContourCrlX,std::vector<double>*);
41         BBTK_DECLARE_OUTPUT(LstContourCrlY,std::vector<double>*);
42         BBTK_DECLARE_OUTPUT(LstContourCrlZ,std::vector<double>*);
43         BBTK_DECLARE_OUTPUT(ImageValueResult,vtkImageData*);
44         BBTK_DECLARE_OUTPUT(ImageMaskResult,vtkImageData*);
45   BBTK_PROCESS(Process);
46   void Process();
47   BBTK_CREATE_WIDGET(CreateWidget);
48   void CreateWidget(wxWindow*);
49
50 private:
51         wxMaracasCoutourTool    *mwxwidget;
52         std::vector<double>             LstValue;
53         std::vector<double>             LstValuePosX;
54         std::vector<double>             LstValuePosY;
55         std::vector<double>             LstValuePosZ;
56         std::vector<double>             LstContourX;
57         std::vector<double>             LstContourY;
58         std::vector<double>             LstContourZ;
59         std::vector<double>             LstContourCrlX;
60         std::vector<double>             LstContourCrlY;
61         std::vector<double>             LstContourCrlZ;
62 };
63
64 BBTK_BEGIN_DESCRIBE_BLACK_BOX(ContourCrown,bbtk::WxBlackBox);
65 BBTK_NAME("ContourCrown");
66 BBTK_AUTHOR("eduardo.davila [at] creatis.insa-lyon.fr");
67 BBTK_DESCRIPTION("Contour crown tool");
68     BBTK_CATEGORY("specific_appli");
69         BBTK_INPUT(ContourCrown,In,"Input Image", vtkImageData *,"" );
70         BBTK_INPUT(ContourCrown,wxVtkBaseView,"maracas visu wxVtkBaseView",wxVtkBaseView*,"");
71 //JSTG 26-02-08 ---------------------------------------------------------------------------------------------------------
72         BBTK_INPUT(ContourCrown,ControlPointsInX,"Control Points X Coords ",std::vector<double>*,"");
73         BBTK_INPUT(ContourCrown,ControlPointsInY,"Control Points Y Coords ",std::vector<double>*,"");
74         BBTK_INPUT(ContourCrown,ControlPointsInZ,"Control Points Z Coords ",std::vector<double>*,"");
75 //-----------------------------------------------------------------------------------------------------------------------
76         BBTK_OUTPUT(ContourCrown,LstValue          , "Pixel values"                                                             ,       std::vector<double>*,"");
77         BBTK_OUTPUT(ContourCrown,LstValuePosX  , "Positions X of the values"                                    ,       std::vector<double>*,"");
78         BBTK_OUTPUT(ContourCrown,LstValuePosY  , "Positions Y of the values"                                    ,       std::vector<double>*,"");
79         BBTK_OUTPUT(ContourCrown,LstValuePosZ  , "Positions Z of the values"                                    ,       std::vector<double>*,"");
80         BBTK_OUTPUT(ContourCrown,LstContourX   , "Positions X of the contours"                          ,       std::vector<double>*,"");
81         BBTK_OUTPUT(ContourCrown,LstContourY   , "Positions Y of the contours"                          ,       std::vector<double>*,"");
82         BBTK_OUTPUT(ContourCrown,LstContourZ   , "Positions Z of the contours"                          ,       std::vector<double>*,"");
83         BBTK_OUTPUT(ContourCrown,LstContourCrlX, "Positions X of the contour control points"    ,       std::vector<double>*,"");
84         BBTK_OUTPUT(ContourCrown,LstContourCrlY, "Positions Y of the contour control points"    ,       std::vector<double>*,"");
85         BBTK_OUTPUT(ContourCrown,LstContourCrlZ, "Positions Z of the contour control points"    ,       std::vector<double>*,"");
86         BBTK_OUTPUT(ContourCrown,ImageValueResult, "vtkImagedata with the values"       ,       vtkImageData *,"" );
87         BBTK_OUTPUT(ContourCrown,ImageMaskResult, "vtkImagedata with the mask"  ,       vtkImageData *,"" );
88 BBTK_END_DESCRIBE_BLACK_BOX(ContourCrown);
89 }
90 // EO namespace bbcreaMaracasVisu
91
92 #endif // __bbcreaMaracasVisuContourCrown_h_INCLUDED__
93 #endif // _USE_WXWIDGETS_
94