18 #ifndef itkImageFileWriter_h
19 #define itkImageFileWriter_h
20 #include "ITKIOImageBaseExport.h"
41 const char *message =
"Error in IO",
42 const char *loc =
"Unknown"):
48 const char *message =
"Error in IO",
49 const char *loc =
"Unknown"):
84 template< typename TInputImage >
107 using Superclass::SetInput;
108 void SetInput(
const InputImageType *input);
110 const InputImageType * GetInput();
112 const InputImageType * GetInput(
unsigned int idx);
115 itkSetStringMacro(FileName);
116 itkGetStringMacro(FileName);
131 if ( this->m_ImageIO != io )
134 this->m_ImageIO = io;
136 m_FactorySpecifiedImageIO =
false;
148 virtual void Write();
156 return m_PasteIORegion;
161 itkSetMacro(NumberOfStreamDivisions,
unsigned int);
162 itkGetConstReferenceMacro(NumberOfStreamDivisions,
unsigned int);
179 m_PasteIORegion =
ImageIORegion(TInputImage::ImageDimension);
180 m_UserSpecifiedIORegion =
false;
185 itkSetMacro(UseCompression,
bool);
186 itkGetConstReferenceMacro(UseCompression,
bool);
187 itkBooleanMacro(UseCompression);
196 itkSetMacro(UseInputMetaDataDictionary,
bool);
197 itkGetConstReferenceMacro(UseInputMetaDataDictionary,
bool);
198 itkBooleanMacro(UseInputMetaDataDictionary);
204 virtual void PrintSelf(std::ostream & os,
Indent indent)
const ITK_OVERRIDE;
207 virtual void GenerateData(
void) ITK_OVERRIDE;
211 void operator=(const Self &) ITK_DELETE_FUNCTION;
213 std::
string m_FileName;
216 bool m_UserSpecifiedImageIO;
220 unsigned int m_NumberOfStreamDivisions;
221 bool m_UserSpecifiedIORegion;
223 bool m_FactorySpecifiedImageIO;
225 bool m_UseCompression;
226 bool m_UseInputMetaDataDictionary;
232 #ifndef ITK_MANUAL_INSTANTIATION
233 #include "itkImageFileWriter.hxx"
236 #ifdef ITK_IO_FACTORY_REGISTER_MANAGER
237 #include "itkImageIOFactoryRegisterManager.h"
240 #endif // itkImageFileWriter_h
SmartPointer< Self > Pointer
An ImageIORegion represents a structured region of data.
Abstract superclass defines image IO interface.
ImageFileWriterException(const std::string &file, unsigned int line, const char *message="Error in IO", const char *loc="Unknown")
InputImageType::PixelType InputImagePixelType
const ImageIORegion & GetIORegion(void) const
The base class for all process objects (source, filters, mappers) in the Insight data processing pipe...
void SetImageIO(ImageIOBase *io)
InputImageType::Pointer InputImagePointer
Base exception class for IO problems during writing.
TInputImage InputImageType
virtual void UpdateLargestPossibleRegion() override
Writes the entire image to file.
SmartPointer< const Self > ConstPointer
InputImageType::RegionType InputImageRegionType
Standard exception handling object.
ImageFileWriterException(const char *file, unsigned int line, const char *message="Error in IO", const char *loc="Unknown")
virtual void Update() override
Writes image data to a single file.
Control indentation during Print() invocation.