28 #ifndef IMAGES_HDF5IMAGE_H
29 #define IMAGES_HDF5IMAGE_H
32 #include <casacore/casa/aips.h>
33 #include <casacore/images/Images/ImageInterface.h>
34 #include <casacore/images/Images/ImageAttrHandlerHDF5.h>
35 #include <casacore/lattices/Lattices/HDF5Lattice.h>
38 #include <casacore/casa/iosfwd.h>
129 const String& nameOfNewFile);
217 virtual void apply (T (*
function)(T));
218 virtual void apply (T (*
function)(
const T& ));
339 #ifndef CASACORE_NO_AUTO_TEMPLATES
340 #include <casacore/images/Images/HDF5Image.tcc>
Referenced counted pointer for constant data.
virtual String name(Bool stripPath=False) const
Return the current HDF5 file name.
virtual T getAt(const IPosition &where) const
These are the true implementations of the paran operator.
HDF5Image(const TiledShape &mapShape, const CoordinateSystem &coordinateInfo, const String &nameOfNewFile)
Construct a new Image from shape and coordinate information.
void restoreImageInfo(const RecordInterface &rec)
void applyMask(const String &maskName)
virtual Bool isWritable() const
Is the HDF5Image writable?
HDF5Image(const HDF5Image< T > &other)
Copy constructor (reference semantics).
virtual Bool setUnits(const Unit &newUnits)
Function which sets the units associated with the image pixels (i.e.
virtual void putAt(const T &value, const IPosition &where)
Put the value of a single element.
virtual void doPutSlice(const Array< T > &sourceBuffer, const IPosition &where, const IPosition &stride)
Function to replace the values in the map with soureBuffer.
virtual IPosition doNiceCursorShape(uInt maxPixels) const
Help the user pick a cursor for most efficient access.
LatticeRegion * regionPtr_p
virtual Bool setMiscInfo(const RecordInterface &newInfo)
Replace the miscinfo in the HDF5Image.
HDF5Image< T > & operator=(const HDF5Image< T > &other)
Assignment operator (reference semantics).
virtual LatticeIterInterface< T > * makeIter(const LatticeNavigator &navigator, Bool useRef) const
This is the implementation of the letter for the envelope Iterator class; Note: Not for public use ...
virtual Bool doGetSlice(Array< T > &buffer, const Slicer &theSlice)
Function which extracts an array from the map.
virtual ImageInterface< T > * cloneII() const
Make a copy of the object (reference semantics).
virtual IPosition shape() const
Return the shape of the image.
virtual void apply(T(*function)(T))
Replace every element, x, of the lattice with the result of f(x).
virtual void flush()
Flush the data.
virtual String imageType() const
Get the image type (returns name of derived class).
virtual Bool setImageInfo(const ImageInfo &info)
The ImageInfo object contains some miscellaneous information about the image, which unlike that store...
virtual Lattice< Bool > & pixelMask()
HDF5Image(const String &fileName, MaskSpecifier=MaskSpecifier())
Reconstruct an image from a pre-existing file.
virtual Bool isPersistent() const
An HDF5Image is always persistent.
virtual void apply(T(*function)(const T &))
void applyMaskSpecifier(const MaskSpecifier &)
virtual Bool ok() const
Check for symmetry in data members.
HDF5Image< T > & operator+=(const Lattice< T > &other)
Add a lattice to this image.
virtual ImageAttrHandler & attrHandler(Bool createHandler=False)
Get access to the attribute handler.
virtual Bool setCoordinateInfo(const CoordinateSystem &coords)
Flushes the new coordinate system to disk if the file is writable.
virtual void removeRegion(const String &name, RegionHandler::GroupType=RegionHandler::Any, Bool throwIfUnknown=True)
Remove a region/mask belonging to the image from the given group (which can be Any).
void restoreUnits(const RecordInterface &rec)
virtual uInt advisedMaxPixels() const
Returns the maximum recommended number of pixels for a cursor.
virtual void resize(const TiledShape &newShape)
Function which changes the shape of the ImageExpr.
void restoreMiscInfo(const RecordInterface &rec)
virtual void setDefaultMask(const String &maskName)
Set the default pixelmask to the mask with the given name (which has to exist in the "masks" group).
void attach_logtable()
This must be called in every constructor and place where the image is attached to a new image.
virtual void useMask(MaskSpecifier=MaskSpecifier())
Use the mask as specified.
void check_conformance(const Lattice< T > &other)
static const CountedPtr< HDF5File > & getFile(void *imagePtr)
Function to return the internal HDF5File object to the RegionHandler.
virtual const Lattice< Bool > & pixelMask() const
Get access to the pixelmask used.
virtual void apply(const Functional< T, T > &function)
virtual Bool hasPixelMask() const
Does the image object use a pixelmask?
virtual const LatticeRegion * getRegionPtr() const
Get a pointer the default pixelmask object used with this image.
virtual Bool isPaged() const
An HDF5Image is always paged to disk.
ImageAttrHandlerHDF5 itsAttrHandler
static Bool hasHDF5Support()
Check if there is HDF5 support compiled in.
GroupType
Define the possible group types (regions or masks).
String: the storage and methods of handling collections of characters.
this file contains all the compiler specific defines
Bool isHDF5Image(const String &fileName)
Check if this HDF5 file is an HDF5 image.
DataType hdf5imagePixelType(const String &fileName)
Determine the pixel type in the HDF5Image contained in fileName.
bool Bool
Define the standard types used by Casacore.
LatticeExprNode value(const LatticeExprNode &expr)
This function returns the value of the expression without a mask.
Bool canUseHDF5Image()
Tell if HDF5 images can be used.