Main Page
Groups
Namespace List
Class Hierarchy
Alphabetical List
Compound List
File
List
Namespace Members
Compound Members
File Members
Concepts
itk::ImageFileWriter< TInputImage > Class Template Reference
[Input and Output Filters]
Writes image data to a single file.
More...
#include <itkImageFileWriter.h>
Inheritance diagram for itk::ImageFileWriter< TInputImage >:
[legend]Collaboration diagram for itk::ImageFileWriter< TInputImage >:
[legend]List of all members.
Detailed Description
template<class TInputImage>
class itk::ImageFileWriter< TInputImage >
Writes image data to a single file.
ImageFileWriter writes its input data to a single output file. ImageFileWriter interfaces with an ImageIO class to write out the data. If you wish to write data into a series of files (e.g., a slice per file) use ImageSeriesWriter.
A pluggable factory pattern is used that allows different kinds of writers to be registered (even at run time) without having to modify the code in this class. You can either manually instantiate the ImageIO object and associate it with the ImageFileWriter, or let the class figure it out from the extension. Normally just setting the filename with a suitable suffix (".png", ".jpg", etc) and setting the input to the writer is enough to get the writer to work properly.
- See also:
- ImageSeriesReader
ImageIOBase
Definition at line 77 of file itkImageFileWriter.h.
Member Typedef Documentation
Constructor & Destructor Documentation
Member Function Documentation
template<class TInputImage> |
void itk::ImageFileWriter< TInputImage >::GenerateData |
( |
void |
|
) |
[protected, virtual] |
|
template<class TInputImage> |
virtual const char* itk::ImageFileWriter< TInputImage >::GetFileName |
( |
|
) |
const [virtual] |
|
|
Specify the name of the output file to write. |
|
Set/Get the ImageIO helper class. Usually this is created via the object factory mechanism that determines whether a particular ImageIO can write a certain file. This method provides a way to get the ImageIO instance that is created, or one can be manually set where the IO factory mechanism may not work (for example, raw image files or image files with non-standard filename suffix's. If the user specifies the ImageIO, we assume she makes the correct choice and will allow a file to be created regardless of the file extension. If the factory has set the ImageIO, the extension must be supported by the specified ImageIO. |
|
Set/Get the image input of this writer. |
|
Specify the region to write. If left NULL, then the whole image is written. |
template<class TInputImage> |
virtual const char* itk::ImageFileWriter< TInputImage >::GetNameOfClass |
( |
|
) |
const [virtual] |
|
template<class TInputImage> |
virtual const bool& itk::ImageFileWriter< TInputImage >::GetUseCompression |
( |
|
) |
[virtual] |
|
|
Set the compression On or Off |
template<class TInputImage> |
virtual const bool& itk::ImageFileWriter< TInputImage >::GetUseInputMetaDataDictionary |
( |
|
) |
[virtual] |
|
|
By default the MetaDataDictionary is taken from the input image and passed to the ImageIO. In some cases, however, a user may prefer to introduce her/his own MetaDataDictionary. This is often the case of the ImageSeriesWriter. This flag defined whether the MetaDataDictionary to use will be the one from the input image or the one already set in the ImageIO object. |
|
Method for creation through the object factory.
Reimplemented from itk::Object. |
template<class TInputImage> |
void itk::ImageFileWriter< TInputImage >::PrintSelf |
( |
std::ostream & |
os, |
|
|
Indent |
indent |
|
) |
const [protected, virtual] |
|
|
Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.
Reimplemented from itk::ProcessObject. |
template<class TInputImage> |
virtual void itk::ImageFileWriter< TInputImage >::SetFileName |
( |
const char * |
_arg |
) |
[virtual] |
|
|
Specify the name of the output file to write. |
|
Set/Get the ImageIO helper class. Usually this is created via the object factory mechanism that determines whether a particular ImageIO can write a certain file. This method provides a way to get the ImageIO instance that is created, or one can be manually set where the IO factory mechanism may not work (for example, raw image files or image files with non-standard filename suffix's. If the user specifies the ImageIO, we assume she makes the correct choice and will allow a file to be created regardless of the file extension. If the factory has set the ImageIO, the extension must be supported by the specified ImageIO.
Definition at line 119 of file itkImageFileWriter.h. |
|
Set/Get the image input of this writer. |
|
Specify the region to write. If left NULL, then the whole image is written. |
template<class TInputImage> |
virtual void itk::ImageFileWriter< TInputImage >::SetUseCompression |
( |
bool |
_arg |
) |
[virtual] |
|
|
Set the compression On or Off |
template<class TInputImage> |
virtual void itk::ImageFileWriter< TInputImage >::SetUseInputMetaDataDictionary |
( |
bool |
_arg |
) |
[virtual] |
|
|
By default the MetaDataDictionary is taken from the input image and passed to the ImageIO. In some cases, however, a user may prefer to introduce her/his own MetaDataDictionary. This is often the case of the ImageSeriesWriter. This flag defined whether the MetaDataDictionary to use will be the one from the input image or the one already set in the ImageIO object. |
template<class TInputImage> |
virtual void itk::ImageFileWriter< TInputImage >::Update |
( |
void |
|
) |
[inline, virtual] |
|
template<class TInputImage> |
virtual void itk::ImageFileWriter< TInputImage >::UseCompressionOff |
( |
|
) |
[virtual] |
|
|
Set the compression On or Off |
template<class TInputImage> |
virtual void itk::ImageFileWriter< TInputImage >::UseCompressionOn |
( |
|
) |
[virtual] |
|
|
Set the compression On or Off |
template<class TInputImage> |
virtual void itk::ImageFileWriter< TInputImage >::UseInputMetaDataDictionaryOff |
( |
|
) |
[virtual] |
|
|
By default the MetaDataDictionary is taken from the input image and passed to the ImageIO. In some cases, however, a user may prefer to introduce her/his own MetaDataDictionary. This is often the case of the ImageSeriesWriter. This flag defined whether the MetaDataDictionary to use will be the one from the input image or the one already set in the ImageIO object. |
template<class TInputImage> |
virtual void itk::ImageFileWriter< TInputImage >::UseInputMetaDataDictionaryOn |
( |
|
) |
[virtual] |
|
|
By default the MetaDataDictionary is taken from the input image and passed to the ImageIO. In some cases, however, a user may prefer to introduce her/his own MetaDataDictionary. This is often the case of the ImageSeriesWriter. This flag defined whether the MetaDataDictionary to use will be the one from the input image or the one already set in the ImageIO object. |
template<class TInputImage> |
virtual void itk::ImageFileWriter< TInputImage >::Write |
( |
void |
|
) |
[virtual] |
|
|
A special version of the Update() method for writers. It invokes start and end events and handles releasing data. It eventually calls GenerateData() which does the actual writing. Note: the write method will write data specified by the IORegion. If not set, then then the whole image is written. Note that the region will be cropped to fit the input image's LargestPossibleRegion. |
The documentation for this class was generated from the following file:
Generated at Thu May 25 01:13:48 2006 for ITK by
1.3.5 written by Dimitri van Heesch,
© 1997-2000