#include <ImageRaster.h>
Reader-writer for the image data unit.
This handler provides methods to access image metadata (image-related keyword records) and data.
Reading methods either return a VecRaster
or fill an existing Raster
.
Data can be read and written region-wise. Source and destination regions are specified by a FileMemRegions
object.
Public Member Functions | |
Image properties. | |
const std::type_info & | readTypeid () const |
Read the image pixel value type. | |
long | readSize () const |
Read the number of pixels in the image. | |
template<long N = 2> | |
Position< N > | readShape () const |
Read the image shape. | |
template<long N = 2> | |
void | updateShape (const Position< N > &shape) const |
Update the image shape. | |
template<typename T , long N = 2> | |
void | reinit (const Position< N > &shape) const |
Update the image type and shape. | |
Read the whole data unit. | |
template<typename T , long N = 2> | |
VecRaster< T, N > | read () const |
Read the whole data unit as a new VecRaster . More... | |
template<typename TRaster > | |
void | readTo (TRaster &raster) const |
Read the whole data unit into an existing Raster . More... | |
template<typename T , long N = 2, typename TContainer > | |
void | readTo (Subraster< T, N, TContainer > &subraster) const |
Read the whole data unit into an existing Subraster . More... | |
Read a region of the data unit. | |
template<typename T , long M, long N> | |
VecRaster< T, M > | readRegion (const Region< N > ®ion) const |
Read a region as a new VecRaster . More... | |
template<typename TRaster > | |
void | readRegionTo (FileMemRegions< TRaster::Dim > regions, TRaster &raster) const |
Read a region of the data unit into a region of an existing Raster . More... | |
Write the whole data unit. | |
template<typename TRaster > | |
void | write (const TRaster &raster) const |
Write the whole data unit. | |
Write a region of the data unit. | |
template<typename TRaster , long N> | |
void | writeRegion (FileMemRegions< N > regions, const TRaster &raster) const |
Write a Raster at a given position of the data unit. More... | |