]> Creatis software - creaContours.git/blob - bbtk/src/bbCreaContournDimensions.h
Feature #1772 Add licence terms for all files.
[creaContours.git] / bbtk / src / bbCreaContournDimensions.h
1 /*# ---------------------------------------------------------------------
2 #
3 # Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image
4 #                        pour la Sant�)
5 # Authors : Eduardo Davila, Frederic Cervenansky, Claire Mouton
6 # Previous Authors : Laurent Guigues, Jean-Pierre Roux
7 # CreaTools website : www.creatis.insa-lyon.fr/site/fr/creatools_accueil
8 #
9 #  This software is governed by the CeCILL-B license under French law and
10 #  abiding by the rules of distribution of free software. You can  use,
11 #  modify and/ or redistribute the software under the terms of the CeCILL-B
12 #  license as circulated by CEA, CNRS and INRIA at the following URL
13 #  http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
14 #  or in the file LICENSE.txt.
15 #
16 #  As a counterpart to the access to the source code and  rights to copy,
17 #  modify and redistribute granted by the license, users are provided only
18 #  with a limited warranty  and the software's author,  the holder of the
19 #  economic rights,  and the successive licensors  have only  limited
20 #  liability.
21 #
22 #  The fact that you are presently reading this means that you have had
23 #  knowledge of the CeCILL-B license and that you accept its terms.
24 # ------------------------------------------------------------------------ */
25
26 #ifdef _USE_WXWIDGETS_
27 #ifndef __bbCreaContournDimensions_h_INCLUDED__
28 #define __bbCreaContournDimensions_h_INCLUDED__
29 #include "bbtkWxBlackBox.h"
30
31 #include "wxContourMainFrame.h"
32
33 #include <map>
34 #include "vtkImageData.h"
35
36 #include "wx/artprov.h"
37 #include <wx/filedlg.h>
38
39 #include <vtkImageData.h>
40 #include <vtkMetaImageReader.h>
41
42 namespace bbcreaContours
43 {
44
45 class /*BBTK_EXPORT*/ nDimensions
46  : 
47    public bbtk::WxBlackBox
48 {
49   BBTK_BLACK_BOX_INTERFACE(nDimensions,bbtk::WxBlackBox);
50
51 //==================================================================
52   BBTK_DECLARE_INPUT(WorkDir,std::string);
53   BBTK_DECLARE_INPUT(In,vtkImageData*);
54   BBTK_DECLARE_INPUT(ContourType,int);
55   BBTK_PROCESS(Process);
56   void Process();
57   BBTK_CREATE_WIDGET(CreateWidget);
58   void CreateWidget(wxWindow*);
59
60   BBTK_DECLARE_OUTPUT(Mask,vtkImageData*);
61   BBTK_DECLARE_OUTPUT(Value,vtkImageData*);
62   BBTK_DECLARE_OUTPUT(X,double**);
63   BBTK_DECLARE_OUTPUT(Y,double**);
64   BBTK_DECLARE_OUTPUT(Z,double**);
65   BBTK_DECLARE_OUTPUT(SizeContour,std::vector <int>);
66
67 private:
68         //wxContourMainFrame* frame;
69         vtkImageData* currentimg;
70         //wxContourEventHandler * eventHandler;
71 };
72
73 BBTK_BEGIN_DESCRIBE_BLACK_BOX(nDimensions, bbtk::WxBlackBox);
74 BBTK_NAME("nDimensions");
75 BBTK_AUTHOR("car-prie@uniandes.edu.co");
76 BBTK_DESCRIPTION("With a given image, the box shows the nDimension application");
77 BBTK_CATEGORY("contours");
78 BBTK_INPUT(nDimensions,WorkDir,"Working data directory where config and data files are located",std::string,"");
79 BBTK_INPUT(nDimensions,In,"Image to be shown",vtkImageData*,"");
80 BBTK_INPUT(nDimensions,ContourType,"Contour type to be exported: ",int,"");
81
82 BBTK_OUTPUT(nDimensions, Mask, "Mask of the contours",vtkImageData*,"");
83 BBTK_OUTPUT(nDimensions, Value, "Value of the contours",vtkImageData*,"");
84 BBTK_OUTPUT(nDimensions, X, "Array of arrays that contains the X coordinates of each contour", double**, "");
85 BBTK_OUTPUT(nDimensions, Y, "Array of arrays that contains the Y coordinates of each contour", double**, "");
86 BBTK_OUTPUT(nDimensions, Z, "Array of arrays that contains the Z coordinates of each contour", double**, "");
87 BBTK_OUTPUT(nDimensions, SizeContour, "Vector that contains the coordinates of each contour", std::vector <int>, "");
88
89 BBTK_END_DESCRIBE_BLACK_BOX(nDimensions);
90 }
91 // EO namespace bbCreaContour
92
93 #endif // __bbCreaContournDimensions_h_INCLUDED__
94 #endif // _USE_WXWIDGETS_