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"
32 #include "itkArray.h"
33 #include "itkVariableSizeMatrix.h"
35 #include "itkCommonEnums.h"
36 
37 #include "vnl/vnl_vector.h"
38 #include "vcl_compiler.h"
39 
40 #include <fstream>
41 #include <string>
42 
43 namespace itk
44 {
45 // Forward reference for VariableLengthVector
46 template <typename TValue>
47 class VariableLengthVector;
48 
77 class ITKIOImageBase_EXPORT ImageIOBase : public LightProcessObject
78 {
79 public:
80  ITK_DISALLOW_COPY_AND_MOVE(ImageIOBase);
81 
83  using Self = ImageIOBase;
87 
89  itkTypeMacro(ImageIOBase, Superclass);
90 
92  itkSetStringMacro(FileName);
93  itkGetStringMacro(FileName);
95 
99 
106  {};
107 
108 #if !defined(ITK_LEGACY_REMOVE)
109 
110  using IOPixelType = IOPixelEnum;
111  static constexpr IOPixelEnum UNKNOWNPIXELTYPE = IOPixelEnum::UNKNOWNPIXELTYPE;
112  static constexpr IOPixelEnum SCALAR = IOPixelEnum::SCALAR;
113  static constexpr IOPixelEnum RGB = IOPixelEnum::RGB;
114  static constexpr IOPixelEnum RGBA = IOPixelEnum::RGBA;
115  static constexpr IOPixelEnum OFFSET = IOPixelEnum::OFFSET;
116  static constexpr IOPixelEnum VECTOR = IOPixelEnum::VECTOR;
117  static constexpr IOPixelEnum POINT = IOPixelEnum::POINT;
118  static constexpr IOPixelEnum COVARIANTVECTOR = IOPixelEnum::COVARIANTVECTOR;
119  static constexpr IOPixelEnum SYMMETRICSECONDRANKTENSOR = IOPixelEnum::SYMMETRICSECONDRANKTENSOR;
120  static constexpr IOPixelEnum DIFFUSIONTENSOR3D = IOPixelEnum::DIFFUSIONTENSOR3D;
121  static constexpr IOPixelEnum COMPLEX = IOPixelEnum::COMPLEX;
122  static constexpr IOPixelEnum FIXEDARRAY = IOPixelEnum::FIXEDARRAY;
123  static constexpr IOPixelEnum MATRIX = IOPixelEnum::MATRIX;
124 #endif
125 
127 #if !defined(ITK_LEGACY_REMOVE)
128 
129  using IOComponentType = IOComponentEnum;
130  static constexpr IOComponentEnum UNKNOWNCOMPONENTTYPE = IOComponentEnum::UNKNOWNCOMPONENTTYPE;
131  static constexpr IOComponentEnum UCHAR = IOComponentEnum::UCHAR;
132  static constexpr IOComponentEnum CHAR = IOComponentEnum::CHAR;
133  static constexpr IOComponentEnum USHORT = IOComponentEnum::USHORT;
134  static constexpr IOComponentEnum SHORT = IOComponentEnum::SHORT;
135  static constexpr IOComponentEnum UINT = IOComponentEnum::UINT;
136  static constexpr IOComponentEnum INT = IOComponentEnum::INT;
137  static constexpr IOComponentEnum ULONG = IOComponentEnum::ULONG;
138  static constexpr IOComponentEnum LONG = IOComponentEnum::LONG;
139  static constexpr IOComponentEnum ULONGLONG = IOComponentEnum::ULONGLONG;
140  static constexpr IOComponentEnum LONGLONG = IOComponentEnum::LONGLONG;
141  static constexpr IOComponentEnum FLOAT = IOComponentEnum::FLOAT;
142  static constexpr IOComponentEnum DOUBLE = IOComponentEnum::DOUBLE;
143 #endif
144 
146 #if !defined(ITK_LEGACY_REMOVE)
147 
148  static constexpr IOFileEnum ASCII = IOFileEnum::ASCII;
149  static constexpr IOFileEnum Binary = IOFileEnum::Binary;
150  static constexpr IOFileEnum TypeNotApplicable = IOFileEnum::TypeNotApplicable;
151 #endif
152 
154 #if !defined(ITK_LEGACY_REMOVE)
155  using ByteOrder = itk::IOByteOrderEnum;
157  static constexpr IOByteOrderEnum BigEndian = IOByteOrderEnum::BigEndian;
158  static constexpr IOByteOrderEnum LittleEndian = IOByteOrderEnum::LittleEndian;
159  static constexpr IOByteOrderEnum OrderNotApplicable = IOByteOrderEnum::OrderNotApplicable;
160 #endif
161 
165  void
166  SetNumberOfDimensions(unsigned int);
167 
168  itkGetConstMacro(NumberOfDimensions, unsigned int);
169 
173  virtual void
174  SetDimensions(unsigned int i, SizeValueType dim);
176 
177  virtual SizeValueType
178  GetDimensions(unsigned int i) const
179  {
180  return m_Dimensions[i];
181  }
182 
185  virtual void
186  SetOrigin(unsigned int i, double origin);
187 
188  virtual double
189  GetOrigin(unsigned int i) const
190  {
191  return m_Origin[i];
192  }
193 
196  virtual void
197  SetSpacing(unsigned int i, double spacing);
198 
199  virtual double
200  GetSpacing(unsigned int i) const
201  {
202  return m_Spacing[i];
203  }
204 
207  virtual void
208  SetDirection(unsigned int i, const std::vector<double> & direction);
209 
210  virtual void
211  SetDirection(unsigned int i, const vnl_vector<double> & direction);
212 
213  virtual std::vector<double>
214  GetDirection(unsigned int i) const
215  {
216  return m_Direction[i];
217  }
218 
221  virtual std::vector<double>
222  GetDefaultDirection(unsigned int k) const;
223 
230  itkSetMacro(IORegion, ImageIORegion);
231  itkGetConstReferenceMacro(IORegion, ImageIORegion);
233 
239  itkSetEnumMacro(PixelType, ::itk::CommonEnums::IOPixel);
240  itkGetEnumMacro(PixelType, ::itk::CommonEnums::IOPixel);
242 
245  itkSetEnumMacro(ComponentType, IOComponentEnum);
246  itkGetEnumMacro(ComponentType, IOComponentEnum);
247 
253  virtual const std::type_info &
254  GetComponentTypeInfo() const;
255 
260  itkSetMacro(NumberOfComponents, unsigned int);
261  itkGetConstReferenceMacro(NumberOfComponents, unsigned int);
263 
265  itkSetMacro(UseCompression, bool);
266  itkGetConstMacro(UseCompression, bool);
267  itkBooleanMacro(UseCompression);
269 
276  itkSetClampMacro(CompressionLevel, int, 1, this->GetMaximumCompressionLevel());
277  itkGetConstMacro(CompressionLevel, int);
278 
289  virtual void
290  SetCompressor(std::string _c);
291  itkGetConstReferenceMacro(Compressor, std::string);
292 
294  itkSetMacro(UseStreamedReading, bool);
295  itkGetConstMacro(UseStreamedReading, bool);
296  itkBooleanMacro(UseStreamedReading);
298 
300  itkSetMacro(UseStreamedWriting, bool);
301  itkGetConstMacro(UseStreamedWriting, bool);
302  itkBooleanMacro(UseStreamedWriting);
304 
309  itkSetMacro(ExpandRGBPalette, bool);
310  itkGetConstMacro(ExpandRGBPalette, bool);
311  itkBooleanMacro(ExpandRGBPalette);
313 
316  itkSetMacro(WritePalette, bool);
317  itkGetConstMacro(WritePalette, bool);
318  itkBooleanMacro(WritePalette);
320 
325  itkGetConstMacro(IsReadAsScalarPlusPalette, bool);
326 
329  static std::string GetComponentTypeAsString(IOComponentEnum);
330 
332  static IOComponentEnum
333  GetComponentTypeFromString(const std::string & typeString);
334 
337  static std::string GetPixelTypeAsString(IOPixelEnum);
338 
340  static IOPixelEnum
341  GetPixelTypeFromString(const std::string & pixelString);
342 
345  itkSetEnumMacro(FileType, IOFileEnum);
346  itkGetEnumMacro(FileType, IOFileEnum);
347  void
349  {
350  this->SetFileType(IOFileEnum::ASCII);
351  }
353 
354  void
356  {
357  this->SetFileType(IOFileEnum::Binary);
358  }
359 
371  itkSetEnumMacro(ByteOrder, IOByteOrderEnum);
372  itkGetEnumMacro(ByteOrder, IOByteOrderEnum);
373  void
375  {
376  this->SetByteOrder(IOByteOrderEnum::BigEndian);
377  }
379 
380  void
382  {
383  this->SetByteOrder(IOByteOrderEnum::LittleEndian);
384  }
385 
388  std::string GetFileTypeAsString(IOFileEnum) const;
389 
392  std::string GetByteOrderAsString(IOByteOrderEnum) const;
393 
396 
400 
407  virtual SizeType
408  GetPixelStride() const;
409 
411  SizeType
412  GetImageSizeInPixels() const;
413 
415  SizeType
416  GetImageSizeInBytes() const;
417 
420  SizeType
421  GetImageSizeInComponents() const;
422 
427  virtual unsigned int
428  GetComponentSize() const;
429 
430  /*-------- This part of the interfaces deals with reading data ----- */
431 
434  virtual bool
435  CanReadFile(const char *) = 0;
436 
441  virtual bool
443  {
444  return false;
445  }
446 
449  virtual void
450  ReadImageInformation() = 0;
451 
453  virtual void
454  Read(void * buffer) = 0;
455 
456  /*-------- This part of the interfaces deals with writing data ----- */
457 
460  virtual bool
461  CanWriteFile(const char *) = 0;
462 
469  virtual bool
471  {
472  return false;
473  }
474 
477  virtual void
478  WriteImageInformation() = 0;
479 
483  virtual void
484  Write(const void * buffer) = 0;
485 
486  /* --- Support reading and writing data as a series of files. --- */
487 
493  virtual bool
494  SupportsDimension(unsigned long dim)
495  {
496  return (dim == 2);
497  }
498 
510  virtual ImageIORegion
511  GenerateStreamableReadRegionFromRequestedRegion(const ImageIORegion & requested) const;
512 
527  virtual unsigned int
528  GetActualNumberOfSplitsForWriting(unsigned int numberOfRequestedSplits,
529  const ImageIORegion & pasteRegion,
530  const ImageIORegion & largestPossibleRegion);
531 
538  virtual ImageIORegion
539  GetSplitRegionForWriting(unsigned int ithPiece,
540  unsigned int numberOfActualSplits,
541  const ImageIORegion & pasteRegion,
542  const ImageIORegion & largestPossibleRegion);
543 
545  using ArrayOfExtensionsType = std::vector<std::string>;
546 
551  const ArrayOfExtensionsType &
552  GetSupportedReadExtensions() const;
553 
558  const ArrayOfExtensionsType &
559  GetSupportedWriteExtensions() const;
560 
561  template <typename TPixel>
562  void
563  SetTypeInfo(const TPixel *);
564 
566  template <typename TPixel>
568  {
570  };
571  template <typename TPixel>
572  void
573  SetPixelTypeInfo(const TPixel *)
574  {
575  this->SetNumberOfComponents(1);
576  this->SetPixelType(IOPixelEnum::SCALAR);
577  this->SetComponentType(MapPixelType<TPixel>::CType);
578  }
579  template <typename TPixel>
580  void
582  {
583  this->SetNumberOfComponents(3);
584  this->SetPixelType(IOPixelEnum::RGB);
585  this->SetComponentType(MapPixelType<TPixel>::CType);
586  }
587  template <typename TPixel>
588  void
590  {
591  this->SetNumberOfComponents(4);
592  this->SetPixelType(IOPixelEnum::RGBA);
593  this->SetComponentType(MapPixelType<TPixel>::CType);
594  }
595  template <unsigned VLength>
596  void
598  {
599  this->SetNumberOfComponents(VLength);
600  this->SetPixelType(IOPixelEnum::OFFSET);
601  this->SetComponentType(IOComponentEnum::LONG);
602  }
603  template <typename TPixel, unsigned VLength>
604  void
606  {
607  this->SetNumberOfComponents(VLength);
608  this->SetPixelType(IOPixelEnum::VECTOR);
609  this->SetComponentType(MapPixelType<TPixel>::CType);
610  }
611  template <typename TCoordRep, unsigned NPointDimension>
612  void
614  {
615  this->SetNumberOfComponents(NPointDimension);
616  this->SetPixelType(IOPixelEnum::POINT);
617  this->SetComponentType(MapPixelType<TCoordRep>::CType);
618  }
619  template <typename TPixel, unsigned VLength>
620  void
622  {
623  this->SetNumberOfComponents(VLength);
624  this->SetPixelType(IOPixelEnum::COVARIANTVECTOR);
625  this->SetComponentType(MapPixelType<TPixel>::CType);
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  template <typename TPixel>
636  void
638  {
639  this->SetNumberOfComponents(6);
640  this->SetPixelType(IOPixelEnum::DIFFUSIONTENSOR3D);
641  this->SetComponentType(MapPixelType<TPixel>::CType);
642  }
643  template <typename TPixel>
644  void
645  SetPixelTypeInfo(const std::complex<TPixel> *)
646  {
647  this->SetNumberOfComponents(2);
648  this->SetPixelType(IOPixelEnum::COMPLEX);
649  this->SetComponentType(MapPixelType<TPixel>::CType);
650  }
651  template <typename TPixel, unsigned VLength>
652  void
654  {
655  this->SetNumberOfComponents(VLength);
656  this->SetPixelType(IOPixelEnum::FIXEDARRAY);
657  this->SetComponentType(MapPixelType<TPixel>::CType);
658  }
659  template <typename TPixel>
660  void
662  {
663  this->SetNumberOfComponents(1);
664  this->SetPixelType(IOPixelEnum::VARIABLELENGTHVECTOR);
665  this->SetComponentType(MapPixelType<TPixel>::CType);
666  }
667  template <typename TValue>
668  void
670  {
671  this->SetNumberOfComponents(1);
672  this->SetPixelType(IOPixelEnum::ARRAY);
673  this->SetComponentType(MapPixelType<TValue>::CType);
674  }
675  template <typename TPixel, unsigned VLength>
676  void
678  {
679  this->SetNumberOfComponents(VLength * VLength);
680  this->SetPixelType(IOPixelEnum::MATRIX);
681  this->SetComponentType(MapPixelType<TPixel>::CType);
682  }
683  template <typename TValue>
684  void
686  {
687  this->SetNumberOfComponents(1);
688  this->SetPixelType(IOPixelEnum::VARIABLESIZEMATRIX);
689  this->SetComponentType(MapPixelType<TValue>::CType);
690  }
692 
693 
694 protected:
695  ImageIOBase();
696  ~ImageIOBase() override;
697  void
698  PrintSelf(std::ostream & os, Indent indent) const override;
699 
700  virtual const ImageRegionSplitterBase *
701  GetImageRegionSplitter() const;
702 
707  virtual bool
708  HasSupportedReadExtension(const char * fileName, bool ignoreCase = true);
709  virtual bool
710  HasSupportedWriteExtension(const char * fileName, bool ignoreCase = true);
712 
715 
719 
722 
724 
727 
729  std::string m_FileName;
730 
733  unsigned int m_NumberOfComponents;
734 
736  unsigned int m_NumberOfDimensions{ 0 };
737 
739  bool m_UseCompression{ false };
740 
741 
742  int m_CompressionLevel{ 30 };
743  int m_MaximumCompressionLevel{ 100 };
744  std::string m_Compressor{ "uninitialized" };
745 
747  virtual void
748  SetMaximumCompressionLevel(int);
749  itkGetConstMacro(MaximumCompressionLevel, int);
751 
755  virtual void
756  InternalSetCompressor(const std::string & _compressor);
757 
760 
763 
766 
770 
773 
777 
779  std::vector<SizeValueType> m_Dimensions;
780 
783  std::vector<double> m_Spacing;
784 
786  std::vector<double> m_Origin;
787 
789  std::vector<std::vector<double>> m_Direction;
790 
793  std::vector<SizeType> m_Strides;
794 
796  virtual void
797  Reset(const bool freeDynamic = true);
798 
800  void
801  Resize(const unsigned int numDimensions, const unsigned int * dimensions);
802 
805  virtual unsigned int
806  GetPixelSize() const;
807 
814  void
815  ComputeStrides();
816 
819  SizeType
820  GetComponentStride() const;
821 
824  SizeType
825  GetRowStride() const;
826 
829  SizeType
830  GetSliceStride() const;
831 
843  virtual void
844  OpenFileForReading(std::ifstream & inputStream, const std::string & filename, bool ascii = false);
845 
861  virtual void
862  OpenFileForWriting(std::ofstream & outputStream,
863  const std::string & filename,
864  bool truncate = true,
865  bool ascii = false);
866 
868  virtual void
869  WriteBufferAsASCII(std::ostream & os, const void * buffer, IOComponentEnum ctype, SizeType numComp);
870 
872  virtual void
873  ReadBufferAsASCII(std::istream & is, void * buffer, IOComponentEnum ctype, SizeType numComp);
874 
876  bool
877  ReadBufferAsBinary(std::istream & is, void * buffer, SizeType num);
878 
880  void
881  AddSupportedReadExtension(const char * extension);
882 
884  void
885  AddSupportedWriteExtension(const char * extension);
886 
887 
888  void
889  SetSupportedReadExtensions(const ArrayOfExtensionsType &);
890  void
891  SetSupportedWriteExtensions(const ArrayOfExtensionsType &);
892 
895  virtual unsigned int
896  GetActualNumberOfSplitsForWritingCanStreamWrite(unsigned int numberOfRequestedSplits,
897  const ImageIORegion & pasteRegion) const;
898 
901  virtual ImageIORegion
902  GetSplitRegionForWritingCanStreamWrite(unsigned int ithPiece,
903  unsigned int numberOfActualSplits,
904  const ImageIORegion & pasteRegion) const;
905 
906 private:
907  bool
908  HasSupportedExtension(const char *, const ArrayOfExtensionsType &, bool ignoreCase = true);
909 
912 };
913 
915 extern ITKIOImageBase_EXPORT void
917  const void * buffer,
918  std::ofstream & file,
919  IOByteOrderEnum byteOrder,
920  SizeValueType numberOfBytes,
921  SizeValueType numberOfComponents);
922 
924 extern ITKIOImageBase_EXPORT void
926  void * buffer,
927  IOByteOrderEnum byteOrder,
928  SizeValueType numberOfComponents);
929 
930 #define IMAGEIOBASE_TYPEMAP(type, ctype) \
931  template <> \
932  struct ImageIOBase::MapPixelType<type> \
933  { \
934  static constexpr IOComponentEnum CType = ctype; \
935  }
936 
937 // the following typemaps are not platform independent
939 IMAGEIOBASE_TYPEMAP(char, std::numeric_limits<char>::is_signed ? IOComponentEnum::CHAR : IOComponentEnum::UCHAR);
951 #undef IMAGIOBASE_TYPEMAP
952 
953 } // end namespace itk
954 
955 #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:772
itk::CommonEnums::IOComponent::CHAR
itk::ImageIOBase
Abstract superclass defines image IO interface.
Definition: itkImageIOBase.h:77
itk::CommonEnums::IOPixel::RGBA
itk::ImageIOBase::m_SupportedReadExtensions
ArrayOfExtensionsType m_SupportedReadExtensions
Definition: itkImageIOBase.h:910
itk::ImageIOBase::m_NumberOfComponents
unsigned int m_NumberOfComponents
Definition: itkImageIOBase.h:733
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:200
itk::CommonEnums::IOByteOrder::BigEndian
itkCovariantVector.h
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const RGBAPixel< TPixel > *)
Definition: itkImageIOBase.h:589
itkRGBPixel.h
itk::CommonEnums::IOComponent::USHORT
itk::CommonEnums::IOPixel::ARRAY
itkVariableSizeMatrix.h
itk::CommonEnums::IOByteOrder
IOByteOrder
Definition: itkCommonEnums.h:127
itk::ImageIOBase::m_Dimensions
std::vector< SizeValueType > m_Dimensions
Definition: itkImageIOBase.h:779
itk::CommonEnums::IOFile::TypeNotApplicable
itk::CommonEnums::IOFile::Binary
itk::CommonEnums::IOComponent::SHORT
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const CovariantVector< TPixel, VLength > *)
Definition: itkImageIOBase.h:621
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:789
itk::ImageIOBase::GetOrigin
virtual double GetOrigin(unsigned int i) const
Definition: itkImageIOBase.h:189
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const std::complex< TPixel > *)
Definition: itkImageIOBase.h:645
itk::ImageIOBase::IndexValueType
::itk::IndexValueType IndexValueType
Definition: itkImageIOBase.h:97
itk::CommonEnums::IOComponent::UINT
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const Offset< VLength > *)
Definition: itkImageIOBase.h:597
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:793
itk::ImageIOBase::m_UseStreamedWriting
bool m_UseStreamedWriting
Definition: itkImageIOBase.h:762
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:776
itk::VariableSizeMatrix
A templated class holding a M x N size Matrix.
Definition: itkVariableSizeMatrix.h:45
itk::CommonEnums::IOPixel
IOPixel
Definition: itkCommonEnums.h:49
itk::CommonEnums::IOComponent::DOUBLE
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const VariableSizeMatrix< TValue > *)
Definition: itkImageIOBase.h:685
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:442
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const FixedArray< TPixel, VLength > *)
Definition: itkImageIOBase.h:653
itk::CommonEnums::IOPixel::DIFFUSIONTENSOR3D
itk::ImageIOBase::m_UseStreamedReading
bool m_UseStreamedReading
Definition: itkImageIOBase.h:759
itk::ImageIOBase::m_Initialized
bool m_Initialized
Definition: itkImageIOBase.h:726
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const RGBPixel< TPixel > *)
Definition: itkImageIOBase.h:581
itk::ImageIOBase::GetDimensions
virtual SizeValueType GetDimensions(unsigned int i) const
Definition: itkImageIOBase.h:178
itk::ImageIOBase::SetFileTypeToBinary
void SetFileTypeToBinary()
Definition: itkImageIOBase.h:355
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:399
itk::CommonEnums::IOPixel::MATRIX
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const Point< TCoordRep, NPointDimension > *)
Definition: itkImageIOBase.h:613
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:98
itk::ImageIOBase::m_IsReadAsScalarPlusPalette
bool m_IsReadAsScalarPlusPalette
Definition: itkImageIOBase.h:769
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:677
itkImageRegionSplitterBase.h
itk::CommonEnums::IOPixel::POINT
itk::ImageIOBase::m_ExpandRGBPalette
bool m_ExpandRGBPalette
Definition: itkImageIOBase.h:765
itk::CommonEnums::IOComponent::ULONGLONG
itk::IOFileEnum
CommonEnums::IOFile IOFileEnum
Definition: itkCommonEnums.h:158
itk::CommonEnums::IOComponent::INT
itk::ImageIOBase::MapPixelType
Definition: itkImageIOBase.h:567
itk::ImageIOBase::m_FileName
std::string m_FileName
Definition: itkImageIOBase.h:729
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const DiffusionTensor3D< TPixel > *)
Definition: itkImageIOBase.h:637
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:214
itk::ImageIOBase::SetFileTypeToASCII
void SetFileTypeToASCII()
Definition: itkImageIOBase.h:348
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
itkArray.h
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const TPixel *)
Definition: itkImageIOBase.h:573
itk::IOByteOrderEnum
CommonEnums::IOByteOrder IOByteOrderEnum
Definition: itkCommonEnums.h:160
itk::CommonEnums::IOPixel::VARIABLESIZEMATRIX
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:395
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:786
itk::IndexValueType
signed long IndexValueType
Definition: itkIntTypes.h:90
itk::Array
Array class with size defined at construction time.
Definition: itkArray.h:47
itkImageIORegion.h
itk::Object
Base class for most ITK classes.
Definition: itkObject.h:62
itk::ImageIOBase::SetByteOrderToLittleEndian
void SetByteOrderToLittleEndian()
Definition: itkImageIOBase.h:381
itk::CommonEnums::IOComponent::UNKNOWNCOMPONENTTYPE
itk::ImageIOBase::SetByteOrderToBigEndian
void SetByteOrderToBigEndian()
Definition: itkImageIOBase.h:374
itk::Point
A templated class holding a geometric point in n-Dimensional space.
Definition: itkPoint.h:53
itk::ImageIOBase::UnknownType
Definition: itkImageIOBase.h:105
itk::ImageIOBase::m_SupportedWriteExtensions
ArrayOfExtensionsType m_SupportedWriteExtensions
Definition: itkImageIOBase.h:911
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const VariableLengthVector< TPixel > *)
Definition: itkImageIOBase.h:661
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const Vector< TPixel, VLength > *)
Definition: itkImageIOBase.h:605
itk::ImageIOBase::CanStreamWrite
virtual bool CanStreamWrite()
Definition: itkImageIOBase.h:470
itk::ImageIOBase::SetPixelTypeInfo
void SetPixelTypeInfo(const Array< TValue > *)
Definition: itkImageIOBase.h:669
itk::CommonEnums::IOComponent::FLOAT
itk::ImageIOBase::SupportsDimension
virtual bool SupportsDimension(unsigned long dim)
Definition: itkImageIOBase.h:494
itk::CommonEnums::IOPixel::VARIABLELENGTHVECTOR
itk::ImageIOBase::m_Spacing
std::vector< double > m_Spacing
Definition: itkImageIOBase.h:783
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:545
fileName
std::string fileName
Definition: itkTestDriverInclude.h:118