28 #ifndef IMAGES_WCREGION_H
29 #define IMAGES_WCREGION_H
41 class RecordInterface;
191 const String& className)
const;
250 return (!
operator==(other));
A Vector of integers, for indexing into Array<T> objects.
Record makeAxesDesc(const CoordinateSystem &cSys) const
Make a description of all pixel axes in the coordinate system (in pixel axes order).
void checkAxes(const IPosition &pixelAxes, const CoordinateSystem &cSys, const Vector< String > &quantityUnits) const
const String & comment() const
Get or set the comment.
virtual WCRegion * cloneRegion() const =0
Clone a WCRegion object.
virtual String type() const =0
Return region type.
Record makeAxisDesc(const CoordinateSystem &cSys, uInt pixelAxis) const
Make a description of a pixel axis in the coordinate system.
void makeWorldAbsolute(Vector< Double > &world, const Vector< Int > &absRel, const CoordinateSystem &cSys, const IPosition &shape) const
Convert relative to absolute world as needed.
const Record & getAxisDesc(uInt axis) const
Get the description of the given axis.
Bool operator!=(const WCRegion &other) const
LCRegion * toLCRegionAxes(const CoordinateSystem &cSys, const IPosition &shape, const IPosition &pixelAxesMap, const IPosition &outOrder) const
Convert to an LCRegion using the given coordinate system and shape.
WCRegion & operator=(const WCRegion &other)
Assignment (copy semantics) makes only sense for a derived class.
virtual Bool canExtend() const
Can the region extend itself? By default it cannot.
virtual TableRecord toRecord(const String &tableName) const =0
Convert the (derived) object to a record.
Int axisNr(const Record &desc, const Record &axesDesc) const
Return the axis number of the description of an axis in the full axes description.
virtual Bool operator==(const WCRegion &other) const
Comparison.
void defineRecordFields(RecordInterface &record, const String &className) const
Define the type and class name in the record.
A hierarchical collection of named fields of various types.
bool Bool
Define the standard types used by Casacore.
static WCRegion * fromRecord(const TableRecord &rec, const String &tableName)
Convert correct object from a record.
TableExprNode shape(const TableExprNode &array)
Function operating on any scalar or array resulting in a Double array containing the shape...
A hierarchical collection of named fields of various types.
const Record & getAxesDesc() const
Get the description of all axes.
virtual LCRegion * toLCRegion(const CoordinateSystem &cSys, const IPosition &shape) const
Convert to an LCRegion using the given new coordinate system and shape.
virtual uInt ndim() const
Get the dimensionality (i.e.
Base class to define world coordinate regions of interest in an image.
static void convertPixel(Double &pixel, const Double &value, const String &unit, const Int absRel, const Double refPix, const Int shape)
void setComment(const String &comment)
String: the storage and methods of handling collections of characters.
Bool isAxisDescEqual(const Record &desc1, const Record &desc2) const
Are both axis descriptions equal?
Abstract base class for Record classes.
void addAxisDesc(const Record &axisDesc)
Add an axis with its description.
virtual ~WCRegion()
Destructor.
virtual LCRegion * doToLCRegion(const CoordinateSystem &cSys, const IPosition &shape, const IPosition &pixelAxesMap, const IPosition &extendAxes) const =0
Convert to an LCRegion using the given coordinate system and shape.
Interconvert pixel and world coordinates.
LatticeExprNode value(const LatticeExprNode &expr)
This function returns the value of the expression without a mask.
Abstract base class to define a region of interest in lattice coordinates.
#define casacore
<X11/Intrinsic.h> #defines true, false, casacore::Bool, and String.