3 #ifndef __bbgdcmvtkGetXCoherentInfoGdcmReader_h_INCLUDED__
4 #define __bbgdcmvtkGetXCoherentInfoGdcmReader_h_INCLUDED__
6 #include "bbgdcmvtk_EXPORT.h"
7 #include "bbtkAtomicBlackBox.h"
11 #include "vtkGdcmReader.h"
14 #if defined(USE_GDCM2)
15 #include "vtkGDCMImageReader.h"
19 #include "gdcmSerieHelper.h"
21 #include "vtkImageData.h"
25 class bbgdcmvtk_EXPORT GetXCoherentInfoGdcmReader
27 public bbtk::AtomicBlackBox
29 BBTK_BLACK_BOX_INTERFACE(GetXCoherentInfoGdcmReader,bbtk::AtomicBlackBox);
31 BBTK_DECLARE_INPUT(In, std::vector<std::string>);
32 BBTK_DECLARE_INPUT(IPPSort, bool);
34 BBTK_DECLARE_OUTPUT(Out, vtkImageData *);
35 BBTK_DECLARE_OUTPUT(IPP, std::vector<double>);
36 BBTK_DECLARE_OUTPUT(IOP, std::vector<double>);
37 BBTK_DECLARE_OUTPUT(PixelSpacing, std::vector<double>);
39 BBTK_PROCESS(Process);
45 GDCM_NAME_SPACE::File *f;
46 GDCM_NAME_SPACE::SerieHelper *sh;
47 vtkGdcmReader *reader;
50 vtkGDCMImageReader *reader;
54 //=================================================================
55 // UserBlackBox description
56 BBTK_BEGIN_DESCRIBE_BLACK_BOX(GetXCoherentInfoGdcmReader,bbtk::AtomicBlackBox);
57 BBTK_NAME("GetXCoherentInfoGdcmReader");
58 BBTK_AUTHOR("jpr, eduardo");
59 BBTK_DESCRIPTION("Get Dicom info from a File Set (a list of Dicom image file names) and read (as a vtkImageData)");
62 BBTK_INPUT(GetXCoherentInfoGdcmReader,In, "List of Dicom image file names", std::vector<std::string>,"");
63 BBTK_INPUT(GetXCoherentInfoGdcmReader,IPPSort,"Sort on Image Position Patient",bool,"");
65 BBTK_OUTPUT(GetXCoherentInfoGdcmReader,Out, "Output image", vtkImageData *,"");
66 BBTK_OUTPUT(GetXCoherentInfoGdcmReader,IPP, "Image Position (Patient)", std::vector<double>,"");
67 BBTK_OUTPUT(GetXCoherentInfoGdcmReader,IOP, "Image Orientation (Patient)", std::vector<double>,"");
68 BBTK_OUTPUT(GetXCoherentInfoGdcmReader,PixelSpacing,"Pixel Spacing", std::vector<double>,"");
69 BBTK_END_DESCRIBE_BLACK_BOX(GetXCoherentInfoGdcmReader);
70 } // EO namespace bbgdcmvtk
72 #endif // __bbgdcmvtkGetXCoherentInfoGdcmReader_h_INCLUDED__