]> Creatis software - clitk.git/blob - common/vtkGDCMPolyDataReader.h
6fe90bd8cdc2aa6f7fd9417cfbd019a54443255c
[clitk.git] / common / vtkGDCMPolyDataReader.h
1 /*=========================================================================
2
3   Program: GDCM (Grassroots DICOM). A DICOM library
4
5   Copyright (c) 2006-2011 Mathieu Malaterre
6   All rights reserved.
7   See Copyright.txt or http://gdcm.sourceforge.net/Copyright.html for details.
8
9      This software is distributed WITHOUT ANY WARRANTY; without even
10      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11      PURPOSE.  See the above copyright notice for more information.
12
13 =========================================================================*/
14 // .NAME vtkGDCMPolyDataReader - read DICOM PolyData files (Contour Data...)
15 // .SECTION Description
16 // For now only support RTSTRUCT (RT Structure Set Storage)
17 // .SECTION TODO
18 // Need to do the same job for DVH Sequence/DVH Data...
19 // .SECTION Warning
20 // When using vtkGDCMPolyDataReader in conjonction with vtkGDCMImageReader
21 // it is *required* that FileLowerLeft is set to ON as coordinate system
22 // would be inconsistant in between the two data structures.
23 //
24 // .SECTION See Also
25 // vtkGDCMImageReader vtkGDCMPolyDataWriter vtkRTStructSetProperties
26
27
28 #ifndef VTKGDCMPOLYDATAREADER_H
29 #define VTKGDCMPOLYDATAREADER_H
30
31 #include "vtkPolyDataAlgorithm.h"
32
33 class vtkMedicalImageProperties;
34 class vtkRTStructSetProperties;
35 //BTX
36 namespace gdcm { class Reader; }
37 //ETX
38 class VTK_EXPORT vtkGDCMPolyDataReader : public vtkPolyDataAlgorithm
39 {
40 public:
41   static vtkGDCMPolyDataReader *New();
42   vtkTypeRevisionMacro(vtkGDCMPolyDataReader,vtkPolyDataAlgorithm);
43   virtual void PrintSelf(ostream& os, vtkIndent indent);
44
45   // Description:
46   // Set/Get the filename of the file to be read
47   vtkSetStringMacro(FileName);
48   vtkGetStringMacro(FileName);
49
50   // Description:
51   // Get the medical image properties object
52   vtkGetObjectMacro(MedicalImageProperties, vtkMedicalImageProperties);
53
54   vtkGetObjectMacro(RTStructSetProperties, vtkRTStructSetProperties);
55
56 protected:
57   vtkGDCMPolyDataReader();
58   ~vtkGDCMPolyDataReader();
59
60   char *FileName;
61   vtkMedicalImageProperties *MedicalImageProperties;
62   vtkRTStructSetProperties *RTStructSetProperties;
63 //BTX
64   void FillMedicalImageInformation(const gdcm::Reader &reader);
65 //ETX
66
67   int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *);
68   int RequestInformation(
69     vtkInformation *vtkNotUsed(request),
70     vtkInformationVector **vtkNotUsed(inputVector),
71     vtkInformationVector *outputVector);
72 //BTX
73   int RequestInformation_RTStructureSetStorage(gdcm::Reader const & reader);
74   int RequestData_RTStructureSetStorage(gdcm::Reader const &reader, vtkInformationVector *outputVector);
75   int RequestInformation_HemodynamicWaveformStorage(gdcm::Reader const & reader);
76   int RequestData_HemodynamicWaveformStorage(gdcm::Reader const &reader, vtkInformationVector *outputVector);
77 //ETX
78
79 private:
80   vtkGDCMPolyDataReader(const vtkGDCMPolyDataReader&);  // Not implemented.
81   void operator=(const vtkGDCMPolyDataReader&);  // Not implemented.
82 };
83
84 #endif