28 #ifndef IMAGES_WCREGION_H 29 #define IMAGES_WCREGION_H 32 #include <casacore/casa/aips.h> 33 #include <casacore/casa/Containers/Record.h> 34 #include <casacore/coordinates/Coordinates/CoordinateSystem.h> 35 #include <casacore/tables/Tables/TableRecord.h> 41 class RecordInterface;
191 const String& className)
const;
250 return (!
operator==(other));
A Vector of integers, for indexing into Array<T> objects.
const Record & getAxisDesc(uInt axis) const
Get the description of the given axis.
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.
void makeWorldAbsolute(Vector< Double > &world, const Vector< Int > &absRel, const CoordinateSystem &cSys, const IPosition &shape) const
Convert relative to absolute world as needed.
virtual WCRegion * cloneRegion() const =0
Clone a WCRegion object.
const String & comment() const
Get or set the comment.
virtual String type() const =0
Return region type.
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.
Int axisNr(const Record &desc, const Record &axesDesc) const
Return the axis number of the description of an axis in the full axes description.
Bool operator!=(const WCRegion &other) const
Bool isAxisDescEqual(const Record &desc1, const Record &desc2) const
Are both axis descriptions equal?
void defineRecordFields(RecordInterface &record, const String &className) const
Define the type and class name in the record.
WCRegion & operator=(const WCRegion &other)
Assignment (copy semantics) makes only sense for a derived class.
const Record & getAxesDesc() const
Get the description of all axes.
virtual TableRecord toRecord(const String &tableName) const =0
Convert the (derived) object to a 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.
Record makeAxesDesc(const CoordinateSystem &cSys) const
Make a description of all pixel axes in the coordinate system (in pixel axes order).
virtual Bool canExtend() const
Can the region extend itself? By default it cannot.
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)
void checkAxes(const IPosition &pixelAxes, const CoordinateSystem &cSys, const Vector< String > &quantityUnits) const
String: the storage and methods of handling collections of characters.
Abstract base class for Record classes.
Record makeAxisDesc(const CoordinateSystem &cSys, uInt pixelAxis) const
Make a description of a pixel axis in the coordinate system.
void addAxisDesc(const Record &axisDesc)
Add an axis with its description.
virtual ~WCRegion()
Destructor.
this file contains all the compiler specific defines
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.
virtual Bool operator==(const WCRegion &other) const
Comparison.