GDCM  2.2.0
vtkGDCMThreadedImageReader.h
Go to the documentation of this file.
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 vtkGDCMThreadedImageReader - read DICOM files with multiple threads
15 // .SECTION Description
16 // vtkGDCMThreadedImageReader is a source object that reads some DICOM files
17 // This reader is threaded. Meaning that on a multiple core CPU with N cpu, it will
18 // read approx N times faster than when reading in a single thread.
19 //
20 // .SECTION Warning: Advanced users only. Do not use this class in the general case,
21 // you have to understand how physicaly medium works first (sequencial reading for
22 // instance) before playing with this class
23 //
24 // .SECTION Implementation note: when FileLowerLeft is set to on the image is not flipped
25 // upside down as VTK would expect, use this option only if you know what you are doing
26 //
27 // .SECTION FIXME: need to implement the other mode where FileLowerLeft is set to OFF
28 //
29 // .SECTION FIXME: you need to call SetFileName when reading a volume file (multiple slices DICOM)
30 // since SetFileNames expect each single file to be single slice (see parent class)
31 //
32 // .SECTION BUG: you should really consider using vtkGDCMThreadedImageReader2 instead !
33 //
34 // .SECTION See Also
35 // vtkMedicalImageReader2 vtkMedicalImageProperties vtkGDCMThreadedImageReader2
36 
37 #ifndef VTKGDCMTHREADEDIMAGEREADER_H
38 #define VTKGDCMTHREADEDIMAGEREADER_H
39 
40 #include "vtkGDCMImageReader.h"
41 
43 {
44 public:
47  virtual void PrintSelf(ostream& os, vtkIndent indent);
48 
49  // Description:
50  // Explicitely set the Rescale Intercept (0028,1052)
51  vtkSetMacro(Shift,double);
52 
53  // Description:
54  // Explicitely get/set the Rescale Slope (0028,1053)
55  vtkSetMacro(Scale,double);
56 
57  // Description:
58  // Determine whether or not reader should use value from Shift/Scale
59  // Default is 1
60  vtkSetMacro(UseShiftScale,int);
61  vtkGetMacro(UseShiftScale,int);
62  vtkBooleanMacro(UseShiftScale,int);
63 
64  // Within this class this is allowed to set the Number of Overlays from outside
65  //vtkSetMacro(NumberOfOverlays,int);
66 
67 protected:
70 
71 #if (VTK_MAJOR_VERSION >= 5) || ( VTK_MAJOR_VERSION == 4 && VTK_MINOR_VERSION > 5 )
72  int RequestInformation(vtkInformation *request,
73  vtkInformationVector **inputVector,
74  vtkInformationVector *outputVector);
75  int RequestData(vtkInformation *request,
76  vtkInformationVector **inputVector,
77  vtkInformationVector *outputVector);
78 #else /*(VTK_MAJOR_VERSION >= 5) || ( VTK_MAJOR_VERSION == 4 && VTK_MINOR_VERSION > 5 )*/
79  void ExecuteInformation();
80  void ExecuteData(vtkDataObject *out);
81 #endif /*(VTK_MAJOR_VERSION >= 5) || ( VTK_MAJOR_VERSION == 4 && VTK_MINOR_VERSION > 5 )*/
82 
83  void ReadFiles(unsigned int nfiles, const char *filenames[]);
84  void RequestDataCompat();
85 
86 private:
87  vtkGDCMThreadedImageReader(const vtkGDCMThreadedImageReader&); // Not implemented.
88  void operator=(const vtkGDCMThreadedImageReader&); // Not implemented.
89 
90  int UseShiftScale;
91 };
92 
93 #endif

Generated on Wed Jun 13 2012 20:40:37 for GDCM by doxygen 1.8.1
SourceForge.net Logo