]> Creatis software - creaContours.git/blob - bbtk/src/bbCreaContournDimensions.h
2e9dd042b2c813ac56742d41244fc2d865a93aae
[creaContours.git] / bbtk / src / bbCreaContournDimensions.h
1 #ifdef _USE_WXWIDGETS_
2 #ifndef __bbCreaContournDimensions_h_INCLUDED__
3 #define __bbCreaContournDimensions_h_INCLUDED__
4 #include "bbtkWxBlackBox.h"
5
6 #include "wxContourMainFrame.h"
7 #include "OutlineModelManager.h"
8 #include "wxContourEventHandler.h"
9 #include "wxContourMainPanel.h"
10 #include <map>
11 #include "vtkImageData.h"
12 #include "OutlineModelBuilder.h"
13 #include "ContourThing.h"
14 #include "AxeThing.h"
15 #include "ImageSourceThing.h"
16 #include "ImageSectionThing.h"
17 #include "SomeEnvironment.h"
18 #include "ReaderEnvironment.h"
19
20 #include "wx/artprov.h"
21 #include <wx/filedlg.h>
22 #include "interfMainPanel.h"
23
24 #include <vtkImageData.h>
25 #include <vtkMetaImageReader.h>
26
27 namespace bbCreaContour
28 {
29
30 class /*BBTK_EXPORT*/ nDimensions
31  : 
32    public bbtk::WxBlackBox
33 {
34   BBTK_BLACK_BOX_INTERFACE(nDimensions,bbtk::WxBlackBox);
35 //==================================================================
36 /// User callback called in the box contructor
37 virtual void bbUserConstructor();
38 /// User callback called in the box copy constructor
39 virtual void bbUserCopyConstructor();
40 /// User callback called in the box destructor
41 virtual void bbUserDestructor();
42 //==================================================================
43   BBTK_DECLARE_INPUT(WorkDir,std::string);
44   BBTK_DECLARE_INPUT(In,vtkImageData*);
45   BBTK_PROCESS(Process);
46   void Process();
47   BBTK_CREATE_WIDGET(CreateWidget);
48   void CreateWidget();
49
50   BBTK_DECLARE_OUTPUT(Mask,vtkImageData*);
51   BBTK_DECLARE_OUTPUT(Value,vtkImageData*);
52   BBTK_DECLARE_OUTPUT(X,double**);
53   BBTK_DECLARE_OUTPUT(Y,double**);
54   BBTK_DECLARE_OUTPUT(Z,double**);
55   BBTK_DECLARE_OUTPUT(SizeContour,std::vector <int>);
56
57 private:
58         wxContourMainFrame* frame;
59         wxContourEventHandler * eventHandler;
60
61 };
62
63 BBTK_BEGIN_DESCRIBE_BLACK_BOX(nDimensions,bbtk::WxBlackBox);
64 BBTK_NAME("nDimensions");
65 BBTK_AUTHOR("car-prie@uniandes.edu.co");
66 BBTK_DESCRIPTION("With a given image, the box shows the ndimension application");
67 BBTK_CATEGORY("__CategoryBlackBox__");
68 BBTK_INPUT(nDimensions,WorkDir,"Working data directory where config and data files are located",std::string,"");
69 BBTK_INPUT(nDimensions,In,"Image to be shown",vtkImageData*,"");
70
71 BBTK_OUTPUT(nDimensions,Mask,"Mask of the contours",vtkImageData*,"");
72 BBTK_OUTPUT(nDimensions,Value,"Value of the contours",vtkImageData*,"");
73 BBTK_OUTPUT(nDimensions,X,"Vector of vectors that contains the X coordinates of each contour",double**,"");
74 BBTK_OUTPUT(nDimensions,Y,"Vector of vectors that contains the Y coordinates of each contour",double**,"");
75 BBTK_OUTPUT(nDimensions,Z,"Vector of vectors that contains the Z coordinates of each contour",double**,"");
76 BBTK_OUTPUT(nDimensions,SizeContour,"Vector of vectors that contains the Z coordinates of each contour",std::vector <int>,"");
77
78
79 BBTK_END_DESCRIBE_BLACK_BOX(nDimensions);
80 }
81 // EO namespace bbCreaContour
82
83 #endif // __bbCreaContournDimensions_h_INCLUDED__
84 #endif // _USE_WXWIDGETS_
85