1 /*# ---------------------------------------------------------------------
3 # Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image
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
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.
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
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 # ------------------------------------------------------------------------ */
26 #ifdef _USE_WXWIDGETS_
27 #ifndef __bbmaracasvisuImageBrowserReader_h_INCLUDED__
28 #define __bbmaracasvisuImageBrowserReader_h_INCLUDED__
29 #include "bbtkWxBlackBox.h"
31 #include "wxMaracasImageBrowser02.h"
34 namespace bbmaracasvisu
38 //--------------------------------------------------------------------
39 //--------------------------------------------------------------------
40 //--------------------------------------------------------------------
42 class ImageBrowserReader;
43 //------------------------------------------------------------------------------------------------------------------------------------
44 // Event handling auxiliar class
45 //------------------------------------------------------------------------------------------------------------------------------------
46 class wxMaracasImageBrowser02_EvtHandler : wxEvtHandler
49 //--------------------------------------------------------------------------------------------------------------------------------
50 // Constructors ans destructors
51 //--------------------------------------------------------------------------------------------------------------------------------
52 wxMaracasImageBrowser02_EvtHandler(ImageBrowserReader *bbParent,wxMaracasImageBrowser02 * wxmaracasimagebrowser02);
53 ~wxMaracasImageBrowser02_EvtHandler();
55 //--------------------------------------------------------------------------------------------------------------------------------
56 // Min-Max Barrange received events
57 //--------------------------------------------------------------------------------------------------------------------------------
58 void OnCutImage(wxCommandEvent& event);
60 //--------------------------------------------------------------------------------------------------------------------------------
62 //--------------------------------------------------------------------------------------------------------------------------------
63 ImageBrowserReader * mbbtkImageBrowserReader;
64 wxMaracasImageBrowser02 * mmaracasimagebrowser02;
68 //--------------------------------------------------------------------
69 //--------------------------------------------------------------------
70 //--------------------------------------------------------------------
75 class /*BBTK_EXPORT*/ ImageBrowserReader
77 public bbtk::WxBlackBox
79 BBTK_BLACK_BOX_INTERFACE(ImageBrowserReader,bbtk::WxBlackBox);
80 //==================================================================
81 /// User callback called in the box contructor
82 virtual void bbUserConstructor();
83 /// User callback called in the box copy constructor
84 virtual void bbUserCopyConstructor();
85 /// User callback called in the box destructor
86 virtual void bbUserDestructor();
87 //==================================================================
88 BBTK_DECLARE_INPUT(LstFileName,std::vector <std::string>);
89 BBTK_DECLARE_INPUT(Type,int);
90 BBTK_DECLARE_OUTPUT(Out,vtkImageData *);
92 BBTK_PROCESS(Process);
94 BBTK_CREATE_WIDGET(CreateWidget);
97 void DefineImageOutput();
100 marParameters *marparameters;
101 marFilesBase *marfilesbase;
102 wxMaracasImageBrowser02 *wxmaracasimagebrowser02;
103 wxMaracasImageBrowser02_EvtHandler *wxmaracasimagebrowser02_eventHandler;
106 BBTK_BEGIN_DESCRIBE_BLACK_BOX(ImageBrowserReader,bbtk::WxBlackBox);
107 BBTK_NAME("ImageBrowserReader");
108 BBTK_AUTHOR("eduardo.davila [at] creatis.insa-lyon.fr");
109 BBTK_DESCRIPTION("Read a DICOM/RAW image and select the VOI");
110 BBTK_CATEGORY("read/write");
111 BBTK_INPUT(ImageBrowserReader,LstFileName,"List of files names", std::vector <std::string> ,"");
112 BBTK_INPUT(ImageBrowserReader,Type,"Type of image (default -999) -999=Unkown -1=lst-ILPD 0=Maracas-Raw 100=Maracas-Dicom 200=Maracas-lstRaw 300=Maracas-lstAsciiRaw",int,"");
113 BBTK_OUTPUT(ImageBrowserReader,Out,"Output Image",vtkImageData*,"");
114 BBTK_END_DESCRIBE_BLACK_BOX(ImageBrowserReader);
116 // EO namespace bbmaracasvisu
118 #endif // __bbmaracasvisuImageBrowserReader_h_INCLUDED__
119 #endif // _USE_WXWIDGETS_