GDCM  2.2.0
vtkGDCMPolyDataWriter.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program: GDCM (Grassroots DICOM). A DICOM library
00004 
00005   Copyright (c) 2006-2011 Mathieu Malaterre
00006   All rights reserved.
00007   See Copyright.txt or http://gdcm.sourceforge.net/Copyright.html for details.
00008 
00009      This software is distributed WITHOUT ANY WARRANTY; without even
00010      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00011      PURPOSE.  See the above copyright notice for more information.
00012 
00013 =========================================================================*/
00014 // .NAME vtkGDCMPolyDataWriter - writer DICOM PolyData files (Contour Data...)
00015 // .SECTION Description
00016 // For now only support RTSTRUCT (RT Structure Set Storage)
00017 // .SECTION TODO
00018 // Need to do the same job for DVH Sequence/DVH Data...
00019 // .SECTION Warning
00020 //
00021 // .SECTION See Also
00022 // vtkGDCMImageReader vtkGDCMPolyDataReader vtkRTStructSetProperties
00023 
00024 
00025 #ifndef VTKGDCMPOLYDATAWRITER_H
00026 #define VTKGDCMPOLYDATAWRITER_H
00027 
00028 #include "vtkPolyDataWriter.h"
00029 #include "vtkStringArray.h"
00030 #include "vtkStdString.h"
00031 
00032 
00033 class vtkMedicalImageProperties;
00034 class vtkRTStructSetProperties;
00035 //BTX
00036 namespace gdcm { class File; }
00037 //ETX
00038 class VTK_EXPORT vtkGDCMPolyDataWriter : public vtkPolyDataWriter
00039 {
00040 public:
00041   static vtkGDCMPolyDataWriter *New();
00042   vtkTypeRevisionMacro(vtkGDCMPolyDataWriter,vtkPolyDataWriter);
00043   virtual void PrintSelf(ostream& os, vtkIndent indent);
00044 
00045   // Description:
00046   // Set/Get the filename of the file to be read
00047 //  vtkSetStringMacro(FileName);
00048 //  vtkGetStringMacro(FileName);
00049 
00050   // Description:
00051   // Get the medical image properties object
00052 //  vtkGetObjectMacro(MedicalImageProperties, vtkMedicalImageProperties);
00053   virtual void SetMedicalImageProperties(vtkMedicalImageProperties *pd);
00054 
00055   virtual void SetRTStructSetProperties(vtkRTStructSetProperties *pd);
00056 
00057 
00058   //this function will initialize the contained rtstructset with
00059   //the inputs of the writer and the various extra information
00060   //necessary for writing a complete rtstructset.
00061   //NOTE: inputs must be set BEFORE calling this function!
00062   //NOTE: the number of outputs for the appendpolydata MUST MATCH the ROI vectors!
00063   void InitializeRTStructSet(vtkStdString inDirectory,
00064      vtkStdString inStructLabel, vtkStdString inStructName,
00065      vtkStringArray* inROINames,
00066      vtkStringArray* inROIAlgorithmName,
00067      vtkStringArray* inROIType);
00068 
00069   // make parent class public...
00070   void SetNumberOfInputPorts(int n);
00071 
00072 protected:
00073   vtkGDCMPolyDataWriter();
00074   ~vtkGDCMPolyDataWriter();
00075 
00076   vtkMedicalImageProperties *MedicalImageProperties;
00077   vtkRTStructSetProperties *RTStructSetProperties;
00078 
00079   void WriteData();
00080 //BTX
00081   void WriteRTSTRUCTInfo(gdcm::File &file);
00082   void WriteRTSTRUCTData(gdcm::File &file, int num);
00083 //ETX
00084 
00085 private:
00086   vtkGDCMPolyDataWriter(const vtkGDCMPolyDataWriter&);  // Not implemented.
00087   void operator=(const vtkGDCMPolyDataWriter&);  // Not implemented.
00088 };
00089 
00090 #endif

Generated on Fri Jun 1 2012 19:00:32 for GDCM by doxygen 1.7.6.1
SourceForge.net Logo