ITK  5.2.0
Insight Toolkit
itkImageIOBase.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright NumFOCUS
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef itkImageIOBase_h
19 #define itkImageIOBase_h
20 #include "ITKIOImageBaseExport.h"
21 
22 #include "itkIOConfigure.h"
23 
24 #include "itkLightProcessObject.h"
25 #include "itkIndent.h"
26 #include "itkImageIORegion.h"
27 #include "itkRGBPixel.h"
28 #include "itkRGBAPixel.h"
29 #include "itkCovariantVector.h"
31 #include "itkDiffusionTensor3D.h"
33 #include "itkCommonEnums.h"
34 
35 #include "vnl/vnl_vector.h"
36 #include "vcl_compiler.h"
37 
38 #include <fstream>
39 #include <string>
40 
41 namespace itk
42 {
43 // Forward reference for VariableLengthVector
44 template <typename TValue>
45 class VariableLengthVector;
46 
75 class ITKIOImageBase_EXPORT ImageIOBase : public LightProcessObject
76 {
77 public:
78  ITK_DISALLOW_COPY_AND_ASSIGN(ImageIOBase);
79 
81  using Self = ImageIOBase;
85 
87  itkTypeMacro(ImageIOBase, Superclass);
88 
90  itkSetStringMacro(FileName);
91  itkGetStringMacro(FileName);
93 
97 
104  {};
105 
106 #if !defined(ITK_LEGACY_REMOVE)
107 
108  using IOPixelType = IOPixelEnum;
109  static constexpr IOPixelEnum UNKNOWNPIXELTYPE = IOPixelEnum::UNKNOWNPIXELTYPE;
110  static constexpr IOPixelEnum SCALAR = IOPixelEnum::SCALAR;
111  static constexpr IOPixelEnum RGB = IOPixelEnum::RGB;
112  static constexpr IOPixelEnum RGBA = IOPixelEnum::RGBA;
113  static constexpr IOPixelEnum OFFSET = IOPixelEnum::OFFSET;
114  static constexpr IOPixelEnum VECTOR = IOPixelEnum::VECTOR;
115  static constexpr IOPixelEnum POINT = IOPixelEnum::POINT;
116  static constexpr IOPixelEnum COVARIANTVECTOR = IOPixelEnum::COVARIANTVECTOR;
117  static constexpr IOPixelEnum SYMMETRICSECONDRANKTENSOR = IOPixelEnum::SYMMETRICSECONDRANKTENSOR;
118  static constexpr IOPixelEnum DIFFUSIONTENSOR3D = IOPixelEnum::DIFFUSIONTENSOR3D;
119  static constexpr IOPixelEnum COMPLEX = IOPixelEnum::COMPLEX;
120  static constexpr IOPixelEnum FIXEDARRAY = IOPixelEnum::FIXEDARRAY;
121  static constexpr IOPixelEnum MATRIX = IOPixelEnum::MATRIX;
122 #endif
123 
125 #if !defined(ITK_LEGACY_REMOVE)
126 
127  using IOComponentType = IOComponentEnum;
128  static constexpr IOComponentEnum UNKNOWNCOMPONENTTYPE = IOComponentEnum::UNKNOWNCOMPONENTTYPE;
129  static constexpr IOComponentEnum UCHAR = IOComponentEnum::UCHAR;
130  static constexpr IOComponentEnum CHAR = IOComponentEnum::CHAR;
131  static constexpr IOComponentEnum USHORT = IOComponentEnum::USHORT;
132  static constexpr IOComponentEnum SHORT = IOComponentEnum::SHORT;
133  static constexpr IOComponentEnum UINT = IOComponentEnum::UINT;
134  static constexpr IOComponentEnum INT = IOComponentEnum::INT;
135  static constexpr IOComponentEnum ULONG = IOComponentEnum::ULONG;
136  static constexpr IOComponentEnum LONG = IOComponentEnum::LONG;
137  static constexpr IOComponentEnum ULONGLONG = IOComponentEnum::ULONGLONG;
138  static constexpr IOComponentEnum LONGLONG = IOComponentEnum::LONGLONG;
139  static constexpr IOComponentEnum FLOAT = IOComponentEnum::FLOAT;
140  static constexpr IOComponentEnum DOUBLE = IOComponentEnum::DOUBLE;
141 #endif
142 
144 #if !defined(ITK_LEGACY_REMOVE)
145 
146  static constexpr IOFileEnum ASCII = IOFileEnum::ASCII;
147  static constexpr IOFileEnum Binary = IOFileEnum::Binary;
148  static constexpr IOFileEnum TypeNotApplicable = IOFileEnum::TypeNotApplicable;
149 #endif
150 
152 #if !defined(ITK_LEGACY_REMOVE)
153  using ByteOrder = itk::IOByteOrderEnum;
155  static constexpr IOByteOrderEnum BigEndian = IOByteOrderEnum::BigEndian;
156  static constexpr IOByteOrderEnum LittleEndian = IOByteOrderEnum::LittleEndian;
157  static constexpr IOByteOrderEnum OrderNotApplicable = IOByteOrderEnum::OrderNotApplicable;
158 #endif
159 
163  void
164  SetNumberOfDimensions(unsigned int);
165 
166  itkGetConstMacro(NumberOfDimensions, unsigned int);
167 
171  virtual void
172  SetDimensions(unsigned int i, SizeValueType dim);
174 
175  virtual SizeValueType
176  GetDimensions(unsigned int i) const
177  {
178  return m_Dimensions[i];
179  }
180 
183  virtual void
184  SetOrigin(unsigned int i, double origin);
185 
186  virtual double
187  GetOrigin(unsigned int i) const
188  {
189  return m_Origin[i];
190  }
191 
194  virtual void
195  SetSpacing(unsigned int i, double spacing);
196 
197  virtual double
198  GetSpacing(unsigned int i) const
199  {
200  return m_Spacing[i];
201  }
202 
205  virtual void
206  SetDirection(unsigned int i, const std::vector<double> & direction);
207 
208  virtual void
209  SetDirection(unsigned int i, const vnl_vector<double> & direction);
210 
211  virtual std::vector<double>
212  GetDirection(unsigned int i) const
213  {
214  return m_Direction[i];
215  }
216 
219  virtual std::vector<double>
220  GetDefaultDirection(unsigned int i) const;
221 
228  itkSetMacro(IORegion, ImageIORegion);
229  itkGetConstReferenceMacro(IORegion, ImageIORegion);
231 
237  itkSetEnumMacro(PixelType, ::itk::CommonEnums::IOPixel);
238  itkGetEnumMacro(PixelType, ::itk::CommonEnums::IOPixel);
240 
243  itkSetEnumMacro(ComponentType, IOComponentEnum);
244  itkGetEnumMacro(ComponentType, IOComponentEnum);
245 
251  virtual const std::type_info &
252  GetComponentTypeInfo() const;
253 
258  itkSetMacro(NumberOfComponents, unsigned int);
259  itkGetConstReferenceMacro(NumberOfComponents, unsigned int);
261 
263  itkSetMacro(UseCompression, bool);
264  itkGetConstMacro(UseCompression, bool);
265  itkBooleanMacro(UseCompression);
267 
274  itkSetClampMacro(CompressionLevel, int, 1, this->GetMaximumCompressionLevel());
275  itkGetConstMacro(CompressionLevel, int);
276 
287  virtual void
288  SetCompressor(std::string _c);
289  itkGetConstReferenceMacro(Compressor, std::string);
290 
292  itkSetMacro(UseStreamedReading, bool);
293  itkGetConstMacro(UseStreamedReading, bool);
294  itkBooleanMacro(UseStreamedReading);
296 
298  itkSetMacro(UseStreamedWriting, bool);
299  itkGetConstMacro(UseStreamedWriting, bool);
300  itkBooleanMacro(UseStreamedWriting);
302 
307  itkSetMacro(ExpandRGBPalette, bool);
308  itkGetConstMacro(ExpandRGBPalette, bool);
309  itkBooleanMacro(ExpandRGBPalette);
311 
314  itkSetMacro(WritePalette, bool);
315  itkGetConstMacro(WritePalette, bool);
316  itkBooleanMacro(WritePalette);
318 
323  itkGetConstMacro(IsReadAsScalarPlusPalette, bool);
324 
327  static std::string GetComponentTypeAsString(IOComponentEnum);
328 
330  static IOComponentEnum
331  GetComponentTypeFromString(const std::string & typeString);
332 
335  static std::string GetPixelTypeAsString(IOPixelEnum);
336 
338  static IOPixelEnum
339  GetPixelTypeFromString(const std::string & pixelString);
340 
343  itkSetEnumMacro(FileType, IOFileEnum);
344  itkGetEnumMacro(FileType, IOFileEnum);
345  void
347  {
348  this->SetFileType(IOFileEnum::ASCII);
349  }
351 
352  void
354  {
355  this->SetFileType(IOFileEnum::Binary);
356  }
357 
369  itkSetEnumMacro(ByteOrder, IOByteOrderEnum);
370  itkGetEnumMacro(ByteOrder, IOByteOrderEnum);
371  void
373  {
374  this->SetByteOrder(IOByteOrderEnum::BigEndian);
375  }
377 
378  void
380  {
381  this->SetByteOrder(IOByteOrderEnum::LittleEndian);
382  }
383 
386  std::string GetFileTypeAsString(IOFileEnum) const;
387 
390  std::string GetByteOrderAsString(IOByteOrderEnum) const;
391 
394 
398 
405  virtual SizeType
406  GetPixelStride() const;
407 
409  SizeType
410  GetImageSizeInPixels() const;
411 
413  SizeType
414  GetImageSizeInBytes() const;
415 
418  SizeType
419  GetImageSizeInComponents() const;
420 
425  virtual unsigned int
426  GetComponentSize() const;
427 
428  /*-------- This part of the interfaces deals with reading data ----- */
429 
432  virtual bool
433  CanReadFile(const char *) = 0;
434 
439  virtual bool
441  {
442  return false;
443  }
444 
447  virtual void
448  ReadImageInformation() = 0;
449 
451  virtual void
452  Read(void * buffer) = 0;
453 
454  /*-------- This part of the interfaces deals with writing data ----- */
455 
458  virtual bool
459  CanWriteFile(const char *) = 0;
460 
467  virtual bool
469  {
470  return false;
471  }
472 
475  virtual void
476  WriteImageInformation() = 0;
477 
481  virtual void
482  Write(const void * buffer) = 0;
483 
484  /* --- Support reading and writing data as a series of files. --- */
485 
491  virtual bool
492  SupportsDimension(unsigned long dim)
493  {
494  return (dim == 2);
495  }
496 
508  virtual ImageIORegion
509  GenerateStreamableReadRegionFromRequestedRegion(const ImageIORegion & requested) const;
510 
525  virtual unsigned int
526  GetActualNumberOfSplitsForWriting(unsigned int numberOfRequestedSplits,
527  const ImageIORegion & pasteRegion,
528  const ImageIORegion & largestPossibleRegion);
529 
536  virtual ImageIORegion
537  GetSplitRegionForWriting(unsigned int ithPiece,
538  unsigned int numberOfActualSplits,
539  const ImageIORegion & pasteRegion,
540  const ImageIORegion & largestPossibleRegion);
541 
543  using ArrayOfExtensionsType = std::vector<std::string>;
544 
549  const ArrayOfExtensionsType &
550  GetSupportedReadExtensions() const;
551 
556  const ArrayOfExtensionsType &
557  GetSupportedWriteExtensions() const;
558 
559  template <typename TPixel>
560  void
561  SetTypeInfo(const TPixel *);
562 
564  template <typename TPixel>
566  {
568  };
569  template <typename TPixel>
570  void
571  SetPixelTypeInfo(const TPixel *)
572  {
573  this->SetNumberOfComponents(1);
574  this->SetPixelType(IOPixelEnum::SCALAR);
575  this->SetComponentType(MapPixelType<TPixel>::CType);
576  }
577  template <typename TPixel>
578  void
580  {
581  this->SetNumberOfComponents(3);
582  this->SetPixelType(IOPixelEnum::RGB);
583  this->SetComponentType(MapPixelType<TPixel>::CType);
584  }
585  template <typename TPixel>
586  void
588  {
589  this->SetNumberOfComponents(4);
590  this->SetPixelType(IOPixelEnum::RGBA);
591  this->SetComponentType(MapPixelType<TPixel>::CType);
592  }
593  template <typename TPixel, unsigned VLength>
594  void
596  {
597  this->SetNumberOfComponents(VLength);
598  this->SetPixelType(IOPixelEnum::VECTOR);
599  this->SetComponentType(MapPixelType<TPixel>::CType);
600  }
601  template <typename TPixel>
602  void
604  {
605  this->SetNumberOfComponents(1);
606  this->SetPixelType(IOPixelEnum::VECTOR);
607  this->SetComponentType(MapPixelType<TPixel>::CType);
608  }
609  template <typename TPixel, unsigned VLength>
610  void
612  {
613  this->SetNumberOfComponents(VLength);
614  this->SetPixelType(IOPixelEnum::COVARIANTVECTOR);
615  this->SetComponentType(MapPixelType<TPixel>::CType);
616  }
617  template <typename TPixel, unsigned VLength>
618  void
620  {
621  this->SetNumberOfComponents(VLength);
622  this->SetPixelType(IOPixelEnum::COVARIANTVECTOR);
623  this->SetComponentType(MapPixelType<TPixel>::CType);
624  }
626 
627  template <typename TPixel, unsigned VLength>
628  void
630  {
631  this->SetNumberOfComponents(VLength * (VLength + 1) / 2);
632  this->SetPixelType(IOPixelEnum::SYMMETRICSECONDRANKTENSOR);
633  this->SetComponentType(MapPixelType<TPixel>::CType);
634  }
635 
636  template <typename TPixel>
637  inline void
639  {
640  this->SetNumberOfComponents(6);
641  this->SetPixelType(IOPixelEnum::DIFFUSIONTENSOR3D);
642  this->SetComponentType(MapPixelType<TPixel>::CType);
643  }
644 
645  template <typename TPixel, unsigned VLength>
646  void
648  {
649  this->SetNumberOfComponents(VLength * VLength);
650  this->SetPixelType(IOPixelEnum::MATRIX);
651  this->SetComponentType(MapPixelType<TPixel>::CType);
652  }
653 
654  template <typename TPixel>
655  void
656  SetPixelTypeInfo(const std::complex<TPixel> *)
657  {
658  this->SetNumberOfComponents(2);
659  this->SetPixelType(IOPixelEnum::COMPLEX);
660  this->SetComponentType(MapPixelType<TPixel>::CType);
661  }
662 
663  template <unsigned VLength>
664  void
666  {
667  this->SetNumberOfComponents(VLength);
668  this->SetPixelType(IOPixelEnum::OFFSET);
669  this->SetComponentType(IOComponentEnum::LONG);
670  }
671 
672 protected:
673  ImageIOBase();
674  ~ImageIOBase() override;
675  void
676  PrintSelf(std::ostream & os, Indent indent) const override;
677 
678  virtual const ImageRegionSplitterBase *
679  GetImageRegionSplitter() const;
680 
685  virtual bool
686  HasSupportedReadExtension(const char * fileName, bool ignoreCase = true);
687  virtual bool
688  HasSupportedWriteExtension(const char * fileName, bool ignoreCase = true);
690 
693 
697 
700 
702 
705 
707  std::string m_FileName;
708 
711  unsigned int m_NumberOfComponents;
712 
714  unsigned int m_NumberOfDimensions{ 0 };
715 
717  bool m_UseCompression{ false };
718 
719 
720  int m_CompressionLevel{ 30 };
721  int m_MaximumCompressionLevel{ 100 };
722  std::string m_Compressor{ "uninitialized" };
723 
725  virtual void
726  SetMaximumCompressionLevel(int);
727  itkGetConstMacro(MaximumCompressionLevel, int);
729 
733  virtual void
734  InternalSetCompressor(const std::string & COMPRESSOR);
735 
738 
741 
744 
748 
751 
755 
757  std::vector<SizeValueType> m_Dimensions;
758 
761  std::vector<double> m_Spacing;
762 
764  std::vector<double> m_Origin;
765 
767  std::vector<std::vector<double>> m_Direction;
768 
771  std::vector<SizeType> m_Strides;
772 
774  virtual void
775  Reset(const bool freeDynamic = true);
776 
778  void
779  Resize(const unsigned int numDimensions, const unsigned int * dimensions);
780 
783  virtual unsigned int
784  GetPixelSize() const;
785 
792  void
793  ComputeStrides();
794 
797  SizeType
798  GetComponentStride() const;
799 
802  SizeType
803  GetRowStride() const;
804 
807  SizeType
808  GetSliceStride() const;
809 
821  virtual void
822  OpenFileForReading(std::ifstream & inputStream, const std::string & filename, bool ascii = false);
823 
839  virtual void
840  OpenFileForWriting(std::ofstream & outputStream,
841  const std::string & filename,
842  bool truncate = true,
843  bool ascii = false);
844 
846  virtual void
847  WriteBufferAsASCII(std::ostream & os, const void * buffer, IOComponentEnum ctype, SizeType numberOfBytesToWrite);
848 
850  virtual void
851  ReadBufferAsASCII(std::istream & os, void * buffer, IOComponentEnum ctype, SizeType numberOfBytesToBeRead);
852 
854  bool
855  ReadBufferAsBinary(std::istream & os, void * buffer, SizeType numberOfBytesToBeRead);
856 
858  void
859  AddSupportedReadExtension(const char * extension);
860 
862  void
863  AddSupportedWriteExtension(const char * extension);
864 
865 
866  void
867  SetSupportedReadExtensions(const ArrayOfExtensionsType &);
868  void
869  SetSupportedWriteExtensions(const ArrayOfExtensionsType &);
870 
873  virtual unsigned int
874  GetActualNumberOfSplitsForWritingCanStreamWrite(unsigned int numberOfRequestedSplits,
875  const ImageIORegion & pasteRegion) const;
876 
879  virtual ImageIORegion
880  GetSplitRegionForWritingCanStreamWrite(unsigned int ithPiece,
881  unsigned int numberOfActualSplits,
882  const ImageIORegion & pasteRegion) const;
883 
884 private:
885  bool
886  HasSupportedExtension(const char *, const ArrayOfExtensionsType &, bool tolower = true);
887 
890 };
891 
893 extern ITKIOImageBase_EXPORT void
895  const void * buffer,
896  std::ofstream & file,
897  IOByteOrderEnum byteOrder,
898  SizeValueType numberOfBytes,
899  SizeValueType numberOfComponents);
900 
902 extern ITKIOImageBase_EXPORT void
904  void * buffer,
905  IOByteOrderEnum byteOrder,
906  SizeValueType numberOfComponents);
907 
908 #define IMAGEIOBASE_TYPEMAP(type, ctype) \
909  template <> \
910  struct ImageIOBase::MapPixelType<type> \
911  { \
912  static constexpr IOComponentEnum CType = ctype; \
913  }
914 
915 // the following typemaps are not platform independent
917 IMAGEIOBASE_TYPEMAP(char, std::numeric_limits<char>::is_signed ? IOComponentEnum::CHAR : IOComponentEnum::UCHAR);
929 #undef IMAGIOBASE_TYPEMAP
930 
931 } // end namespace itk
932 
933 #endif // itkImageIOBase_h
itk::IOPixelEnum
CommonEnums::IOPixel IOPixelEnum
Definition: itkCommonEnums.h:156
itk::CommonEnums::IOByteOrder::LittleEndian
itk::ImageIOBase::m_WritePalette
bool m_WritePalette
Definition: itkImageIOBase.h:750
itk::CommonEnums::IOComponent::CHAR
itk::ImageIOBase
Abstract superclass defines image IO interface.
Definition: itkImageIOBase.h:75
itk::CommonEnums::IOPixel::RGBA
itk::ImageIOBase::m_SupportedReadExtensions
ArrayOfExtensionsType m_SupportedReadExtensions
Definition: itkImageIOBase.h:888
itk::ImageIOBase::m_NumberOfComponents
unsigned int m_NumberOfComponents
Definition: itkImageIOBase.h:711
itk::LightProcessObject
LightProcessObject is the base class for all process objects (source, filters, mappers) in the Insigh...
Definition: itkLightProcessObject.h:72
itk::CommonEnums::IOPixel::OFFSET
itk::RGBPixel< TPixel >
itk::CommonEnums::IOFile
IOFile
Definition: itkCommonEnums.h:100
itk::ImageIOBase::GetSpacing
virtual double GetSpacing(unsigned int i) const
Definition: itkImageIOBase.h:198
itk::CommonEnums::IOByteOrder::BigEndian
itkCovariantVector.h
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const RGBAPixel< TPixel > *)
Definition: itkImageIOBase.h:587
itkRGBPixel.h
itk::CommonEnums::IOComponent::USHORT
itk::CommonEnums::IOByteOrder
IOByteOrder
Definition: itkCommonEnums.h:127
itk::ImageIOBase::m_Dimensions
std::vector< SizeValueType > m_Dimensions
Definition: itkImageIOBase.h:757
itk::CommonEnums::IOFile::TypeNotApplicable
itk::CommonEnums::IOFile::Binary
itk::CommonEnums::IOComponent::SHORT
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const CovariantVector< TPixel, VLength > *)
Definition: itkImageIOBase.h:611
itk::CommonEnums::IOPixel::VECTOR
itk::CommonEnums::IOPixel::SCALAR
itkLightProcessObject.h
itk::IMAGEIOBASE_TYPEMAP
IMAGEIOBASE_TYPEMAP(signed char, IOComponentEnum::CHAR)
itk::CommonEnums::IOComponent::ULONG
itk::ImageIOBase::m_Direction
std::vector< std::vector< double > > m_Direction
Definition: itkImageIOBase.h:767
itk::ImageIOBase::GetOrigin
virtual double GetOrigin(unsigned int i) const
Definition: itkImageIOBase.h:187
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const std::complex< TPixel > *)
Definition: itkImageIOBase.h:656
itk::ImageIOBase::IndexValueType
::itk::IndexValueType IndexValueType
Definition: itkImageIOBase.h:95
itk::CommonEnums::IOComponent::UINT
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const Offset< VLength > *)
Definition: itkImageIOBase.h:665
itkDiffusionTensor3D.h
itk::Vector
A templated class holding a n-Dimensional vector.
Definition: itkVector.h:62
itk::DiffusionTensor3D
Represent a diffusion tensor as used in DTI images.
Definition: itkDiffusionTensor3D.h:79
itkRGBAPixel.h
itk::ImageIOBase::m_Strides
std::vector< SizeType > m_Strides
Definition: itkImageIOBase.h:771
itk::ImageIOBase::m_UseStreamedWriting
bool m_UseStreamedWriting
Definition: itkImageIOBase.h:740
itk::CommonEnums::IOPixel::COVARIANTVECTOR
itk::IOComponentEnum
CommonEnums::IOComponent IOComponentEnum
Definition: itkCommonEnums.h:157
itk::SmartPointer< Self >
itk::CommonEnums::IOPixel::SYMMETRICSECONDRANKTENSOR
itk::CommonEnums::IOComponent
IOComponent
Definition: itkCommonEnums.h:76
itk::Indent
Control indentation during Print() invocation.
Definition: itkIndent.h:49
itk::ImageIORegion
An ImageIORegion represents a structured region of data.
Definition: itkImageIORegion.h:52
itk::CommonEnums::IOComponent::UCHAR
itk::intmax_t
::intmax_t intmax_t
Definition: itkIntTypes.h:55
itk::WriteRawBytesAfterSwapping
ITKIOImageBase_EXPORT void WriteRawBytesAfterSwapping(IOComponentEnum componentType, const void *buffer, std::ofstream &file, IOByteOrderEnum byteOrder, SizeValueType numberOfBytes, SizeValueType numberOfComponents)
itk::ImageIOBase::m_IORegion
ImageIORegion m_IORegion
Definition: itkImageIOBase.h:754
itk::CommonEnums::IOPixel
IOPixel
Definition: itkCommonEnums.h:49
itk::CommonEnums::IOComponent::DOUBLE
itk::CommonEnums::IOComponent::LONGLONG
itk::SymmetricSecondRankTensor
Represent a symmetric tensor of second rank.
Definition: itkSymmetricSecondRankTensor.h:75
itk::ImageIOBase::CanStreamRead
virtual bool CanStreamRead()
Definition: itkImageIOBase.h:440
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const FixedArray< TPixel, VLength > *)
Definition: itkImageIOBase.h:619
itk::CommonEnums::IOPixel::DIFFUSIONTENSOR3D
itk::ImageIOBase::m_UseStreamedReading
bool m_UseStreamedReading
Definition: itkImageIOBase.h:737
itk::ImageIOBase::m_Initialized
bool m_Initialized
Definition: itkImageIOBase.h:704
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const RGBPixel< TPixel > *)
Definition: itkImageIOBase.h:579
itk::ImageIOBase::GetDimensions
virtual SizeValueType GetDimensions(unsigned int i) const
Definition: itkImageIOBase.h:176
itk::ImageIOBase::SetFileTypeToBinary
void SetFileTypeToBinary()
Definition: itkImageIOBase.h:353
itk::LightObject
Light weight base class for most itk classes.
Definition: itkLightObject.h:59
itk::CommonEnums::IOPixel::FIXEDARRAY
itk::ImageIOBase::BufferSizeType
::itk::OffsetValueType BufferSizeType
Definition: itkImageIOBase.h:397
itk::CommonEnums::IOPixel::MATRIX
itk::CommonEnums::IOComponent::LONG
itk::CommonEnums::IOPixel::RGB
itkIndent.h
itk::ImageRegionSplitterBase
Divide an image region into several pieces.
Definition: itkImageRegionSplitterBase.h:58
itkSymmetricSecondRankTensor.h
itk::ImageIOBase::SizeValueType
::itk::SizeValueType SizeValueType
Definition: itkImageIOBase.h:96
itk::ImageIOBase::m_IsReadAsScalarPlusPalette
bool m_IsReadAsScalarPlusPalette
Definition: itkImageIOBase.h:747
itk::CommonEnums::IOByteOrder::OrderNotApplicable
itk::ReadRawBytesAfterSwapping
ITKIOImageBase_EXPORT void ReadRawBytesAfterSwapping(IOComponentEnum componentType, void *buffer, IOByteOrderEnum byteOrder, SizeValueType numberOfComponents)
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const Matrix< TPixel, VLength, VLength > *)
Definition: itkImageIOBase.h:647
itkImageRegionSplitterBase.h
itk::CommonEnums::IOPixel::POINT
itk::ImageIOBase::m_ExpandRGBPalette
bool m_ExpandRGBPalette
Definition: itkImageIOBase.h:743
itk::CommonEnums::IOComponent::ULONGLONG
itk::IOFileEnum
CommonEnums::IOFile IOFileEnum
Definition: itkCommonEnums.h:158
itk::CommonEnums::IOComponent::INT
itk::ImageIOBase::MapPixelType
Definition: itkImageIOBase.h:565
itk::ImageIOBase::m_FileName
std::string m_FileName
Definition: itkImageIOBase.h:707
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const DiffusionTensor3D< TPixel > *)
Definition: itkImageIOBase.h:638
itk::VariableLengthVector
Represents an array whose length can be defined at run-time.
Definition: itkConstantBoundaryCondition.h:28
itk::FixedArray
Simulate a standard C array with copy semantics.
Definition: itkFixedArray.h:52
itk::Matrix
A templated class holding a M x N size Matrix.
Definition: itkMatrix.h:51
itk::ImageIOBase::GetDirection
virtual std::vector< double > GetDirection(unsigned int i) const
Definition: itkImageIOBase.h:212
itk::ImageIOBase::SetFileTypeToASCII
void SetFileTypeToASCII()
Definition: itkImageIOBase.h:346
itk::CovariantVector
A templated class holding a n-Dimensional covariant vector.
Definition: itkCovariantVector.h:70
itk::Offset
Represent a n-dimensional offset between two n-dimensional indexes of n-dimensional image.
Definition: itkOffset.h:67
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const TPixel *)
Definition: itkImageIOBase.h:571
itk::IOByteOrderEnum
CommonEnums::IOByteOrder IOByteOrderEnum
Definition: itkCommonEnums.h:160
itk::RGBAPixel
Represent Red, Green, Blue and Alpha components for color images.
Definition: itkRGBAPixel.h:59
itk::ImageIOBase::SizeType
::itk::intmax_t SizeType
Definition: itkImageIOBase.h:393
itk::CommonEnums::IOPixel::UNKNOWNPIXELTYPE
itk
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
Definition: itkAnnulusOperator.h:24
itkCommonEnums.h
itk::OffsetValueType
signed long OffsetValueType
Definition: itkIntTypes.h:94
itk::CommonEnums::IOPixel::COMPLEX
itk::CommonEnums::IOFile::ASCII
itk::ImageIOBase::m_Origin
std::vector< double > m_Origin
Definition: itkImageIOBase.h:764
itk::IndexValueType
signed long IndexValueType
Definition: itkIntTypes.h:90
itkImageIORegion.h
itk::Object
Base class for most ITK classes.
Definition: itkObject.h:62
itk::ImageIOBase::SetByteOrderToLittleEndian
void SetByteOrderToLittleEndian()
Definition: itkImageIOBase.h:379
itk::CommonEnums::IOComponent::UNKNOWNCOMPONENTTYPE
itk::ImageIOBase::SetByteOrderToBigEndian
void SetByteOrderToBigEndian()
Definition: itkImageIOBase.h:372
itk::ImageIOBase::UnknownType
Definition: itkImageIOBase.h:103
itk::ImageIOBase::m_SupportedWriteExtensions
ArrayOfExtensionsType m_SupportedWriteExtensions
Definition: itkImageIOBase.h:889
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const VariableLengthVector< TPixel > *)
Definition: itkImageIOBase.h:603
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const Vector< TPixel, VLength > *)
Definition: itkImageIOBase.h:595
itk::ImageIOBase::CanStreamWrite
virtual bool CanStreamWrite()
Definition: itkImageIOBase.h:468
itk::CommonEnums::IOComponent::FLOAT
itk::ImageIOBase::SupportsDimension
virtual bool SupportsDimension(unsigned long dim)
Definition: itkImageIOBase.h:492
itk::ImageIOBase::m_Spacing
std::vector< double > m_Spacing
Definition: itkImageIOBase.h:761
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const SymmetricSecondRankTensor< TPixel, VLength > *)
Definition: itkImageIOBase.h:629
itk::SizeValueType
unsigned long SizeValueType
Definition: itkIntTypes.h:83
itk::ImageIOBase::ArrayOfExtensionsType
std::vector< std::string > ArrayOfExtensionsType
Definition: itkImageIOBase.h:543
fileName
std::string fileName
Definition: itkTestDriverInclude.h:118