]> Creatis software - clitk.git/blob - tools/clitkImage2DicomRTStruct.cxx
GateAsciiImageIO is now cross-platform using itksys::RegularExpression
[clitk.git] / tools / clitkImage2DicomRTStruct.cxx
1 /*=========================================================================
2   Program:         vv http://www.creatis.insa-lyon.fr/rio/vv
3   Main authors :   XX XX XX
4
5   Authors belongs to: 
6   - University of LYON           http://www.universite-lyon.fr/
7   - Léon Bérard cancer center    http://www.centreleonberard.fr
8   - CREATIS CNRS laboratory      http://www.creatis.insa-lyon.fr
9
10   This software is distributed WITHOUT ANY WARRANTY; without even
11   the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12   PURPOSE.  See the copyright notices for more information.
13
14   It is distributed under dual licence
15   - BSD       http://www.opensource.org/licenses/bsd-license.php
16   - CeCILL-B  http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
17
18   =========================================================================*/
19
20 #include "clitkImage2DicomRTStructFilter.h"
21 #include "clitkDicomRT_StructureSet.h"
22 #include "clitkImage2DicomRTStruct_ggo.h"
23
24 //--------------------------------------------------------------------
25 int main(int argc, char * argv[]) {
26
27   // Init command line
28   GGO(clitkImage2DicomRTStruct, args_info);
29
30   // Read initial 3D image
31   typedef float PixelType;
32   typedef itk::Image<PixelType, 3> ImageType;
33   ImageType::Pointer input = clitk::readImage<ImageType>(args_info.input_arg, true);
34
35   // Create a filter to convert image into dicomRTStruct
36   clitk::Image2DicomRTStructFilter<PixelType> filter;
37   filter.SetInput(input);
38   filter.Update();
39   
40   // Write result
41   clitk::DicomRT_StructureSet::Pointer s = filter.GetDicomRTStruct();
42   //  s->Write(args_info.output_arg);
43
44   // This is the end my friend 
45   return 0;
46 }
47 //--------------------------------------------------------------------