casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes
casa::RegionManager Class Reference

#include <RegionManager.h>

Inheritance diagram for casa::RegionManager:
casa::CasacRegionManager

List of all members.

Public Member Functions

 RegionManager ()
 blank constructor
 RegionManager (const CoordinateSystem &csys)
virtual ~RegionManager ()
String absreltype (const Int absrelval=0)
void setcoordsys (const CoordinateSystem &csys)
const CoordinateSystemgetcoordsys () const
Recordbox (const Vector< Double > &blc, const Vector< Double > &trc, const Vector< Double > &inc, const String &absrel, const Bool frac, const String &comment="")
 LCSlicer box.
Recordbox (const Vector< Double > &blc, const Vector< Double > &trc, const Vector< Int > &shape, const String &comment="")
 LCBox box.
Recordwbox (const Vector< Quantity > &blc, const Vector< Quantity > &trc, const Vector< Int > &pixelaxes, const CoordinateSystem &csys, const String &absrel, const String &comment)
Recordwbox (const Vector< String > &blc, const Vector< String > &trc, const Vector< Int > &pixelaxes, const CoordinateSystem &csys, const String &absrel, const String &comment)
Recordwbox (const Vector< Quantity > &blc, const Vector< Quantity > &trc, const Vector< Int > &pixelaxes, const String &absrel, const String &comment)
Recordwbox (const Vector< String > &blc, const Vector< String > &trc, const Vector< Int > &pixelaxes, const String &absrel, const String &comment)
ImageRegionwbox (const Vector< Quantity > &blc, const Vector< Quantity > &trc, const Vector< Int > &pixelaxes, const CoordinateSystem &csys, const String &absrel="abs")
ImageRegionwpolygon (const Vector< Quantity > &x, const Vector< Quantity > &y, const Vector< Int > &pixelaxes, const CoordinateSystem &csys, const String &absrel)
 Wpolygon with coordsys and if pixelaxes[0] is -1 then its assumed to be 0,1,...
ImageRegionwpolygon (const Vector< Quantity > &x, const Vector< Quantity > &y, const Vector< Int > &pixelaxes, const String &absrel)
 wpolygon version without csys...throws an exception if setcoordsys is not run
ImageRegionwellipse (const Quantity &xc, const Quantity &yc, const Quantity &a, const Quantity &b, const Quantity &pa, const uInt pixelAxis0, const uInt pixelAxis1, const String &absrel) const
 wellipse version without csys...throws an exception if setcoordsys is not run
ImageRegionwsphere (const Vector< Quantity > &center, const Quantity &radius, const Vector< Int > &pixelaxes, const String &absrel) const
 wsphere version without csys...throws an exception if setcoordsys is not run
ImageRegionwellipsoid (const Vector< Quantity > &center, const Vector< Quantity > &radii, const Vector< Int > &pixelaxes, const String &absrel) const
ImageRegionwshell (const Vector< Quantity > &center, const Vector< Quantity > &innerRadii, const Vector< Quantity > &outerRadii, const Vector< Int > &pixelaxes, const String &absrel) const
ImageRegiondoComplement (const WCRegion &reg1)
 Various versions of creating a complement region.
ImageRegiondoComplement (const PtrBlock< const WCRegion * > &reg1)
ImageRegiondoComplement (const ImageRegion &reg1)
ImageRegiondoConcatenation (const WCRegion &region, const WCBox &box)
 Various versions of concatenating a region onto another.
ImageRegiondoconcatenation (const PtrBlock< const WCRegion * > &regions, const WCBox &box)
ImageRegiondoConcatenation (const PtrBlock< const ImageRegion * > &regions, const TableRecord &box)
ImageRegiondoConcatenation (const Record &regions, const TableRecord &box)
ImageRegiondoDifference (const WCRegion &reg1, const WCRegion &reg2)
 Various versions of handling the difference of regions.
ImageRegiondoDifference (const PtrBlock< const WCRegion * > &reg1)
ImageRegiondoDifference (const ImageRegion &reg1, const ImageRegion &reg2)
ImageRegiondoIntersection (const WCRegion &reg1, const WCRegion &reg2)
 Different versions of intersecting regions.
ImageRegiondoIntersection (const PtrBlock< const WCRegion * > &reg1)
ImageRegiondoIntersection (const ImageRegion &reg1, const ImageRegion &reg2)
ImageRegiondoUnion (const WCRegion &reg1, const WCRegion &reg2)
 Different versions of unioning regions.
ImageRegiondoUnion (const PtrBlock< const WCRegion * > &reg1)
ImageRegiondoUnion (const ImageRegion &reg1, const ImageRegion &reg2) const
String imageRegionToTable (const String &tabName, const ImageRegion &imreg, const String &regName, Bool asmask=False)
 save region into a table (image, blank table or any other such)
String recordToTable (const String &tabName, const RecordInterface &rec, const String &regName="", Bool asmask=False)
RecordtableToRecord (const String &tabName, const String &regname)
 recover region from table
Vector< StringnamesInTable (const String &tabName)
 names of regions in table
Bool removeRegionInTable (const String &tabName, const String &regName)
 Remove a region from table...refuse is regionname is "".

Static Public Member Functions

static Bool isPixelRegion (const ImageRegion &reg)
 Some little but useful tidbits.
static Bool isWorldRegion (const ImageRegion &reg)
static ImageRegionwellipse (const Quantity &xc, const Quantity &yc, const Quantity &a, const Quantity &b, const Quantity &pa, const uInt pixelAxis0, const uInt pixelAxis1, const CoordinateSystem &csys, const String &absrel)
static ImageRegionwsphere (const Vector< Quantity > &center, const Quantity &radius, const Vector< Int > &pixelaxes, const CoordinateSystem &csys, const String &absrel)
static ImageRegionwellipsoid (const Vector< Quantity > &center, const Vector< Quantity > &radii, const Vector< Int > &pixelaxes, const CoordinateSystem &csys, const String &absrel)
static ImageRegionwshell (const Vector< Quantity > &center, const Vector< Quantity > &innerRadii, const Vector< Quantity > &outerRadii, const Vector< Int > &pixelaxes, const CoordinateSystem &csys, const String &absrel)
static ImageRegionwmask (const String &command)
static RecordreadImageFile (String filename, String regionname)
 Reading of a file containing an ImageRegion in the AipsIO format dump.
static Bool writeImageFile (const String &file, const String &regionname, const Record &regionRecord)
 Writing a file of the AipsIO dump of the record representation of the region.

Protected Member Functions

LogIO_getLog () const

Private Member Functions

void toQuantity (Quantity &out, const String &in)
 Convert a string to Quantity.

Static Private Member Functions

static TablegetTable (void *ptr, Bool writable)
 Function to return the internal Table object to the RegionHandler.

Private Attributes

LogIOitsLog
CoordinateSystemitsCSys
Table tab_p

Detailed Description

Definition at line 56 of file RegionManager.h.


Constructor & Destructor Documentation

blank constructor

virtual casa::RegionManager::~RegionManager ( ) [virtual]

Member Function Documentation

LogIO* casa::RegionManager::_getLog ( ) const [inline, protected]

Definition at line 258 of file RegionManager.h.

References itsLog.

String casa::RegionManager::absreltype ( const Int  absrelval = 0)
Record* casa::RegionManager::box ( const Vector< Double > &  blc,
const Vector< Double > &  trc,
const Vector< Double > &  inc,
const String absrel,
const Bool  frac,
const String comment = "" 
)

LCSlicer box.

Record* casa::RegionManager::box ( const Vector< Double > &  blc,
const Vector< Double > &  trc,
const Vector< Int > &  shape,
const String comment = "" 
)

LCBox box.

Various versions of creating a complement region.

ImageRegion* casa::RegionManager::doConcatenation ( const WCRegion region,
const WCBox box 
)

Various versions of concatenating a region onto another.

ImageRegion* casa::RegionManager::doconcatenation ( const PtrBlock< const WCRegion * > &  regions,
const WCBox box 
)
ImageRegion* casa::RegionManager::doConcatenation ( const PtrBlock< const ImageRegion * > &  regions,
const TableRecord box 
)
ImageRegion* casa::RegionManager::doConcatenation ( const Record regions,
const TableRecord box 
)
ImageRegion* casa::RegionManager::doDifference ( const WCRegion reg1,
const WCRegion reg2 
)

Various versions of handling the difference of regions.

ImageRegion* casa::RegionManager::doIntersection ( const WCRegion reg1,
const WCRegion reg2 
)

Different versions of intersecting regions.

ImageRegion* casa::RegionManager::doUnion ( const WCRegion reg1,
const WCRegion reg2 
)

Different versions of unioning regions.

ImageRegion* casa::RegionManager::doUnion ( const ImageRegion reg1,
const ImageRegion reg2 
) const
static Table& casa::RegionManager::getTable ( void *  ptr,
Bool  writable 
) [static, private]

Function to return the internal Table object to the RegionHandler.

String casa::RegionManager::imageRegionToTable ( const String tabName,
const ImageRegion imreg,
const String regName,
Bool  asmask = False 
)

save region into a table (image, blank table or any other such)

static Bool casa::RegionManager::isPixelRegion ( const ImageRegion reg) [static]

Some little but useful tidbits.

static Bool casa::RegionManager::isWorldRegion ( const ImageRegion reg) [static]

names of regions in table

static Record* casa::RegionManager::readImageFile ( String  filename,
String  regionname 
) [static]

Reading of a file containing an ImageRegion in the AipsIO format dump.

String casa::RegionManager::recordToTable ( const String tabName,
const RecordInterface rec,
const String regName = "",
Bool  asmask = False 
)
Bool casa::RegionManager::removeRegionInTable ( const String tabName,
const String regName 
)

Remove a region from table...refuse is regionname is "".

Record* casa::RegionManager::tableToRecord ( const String tabName,
const String regname 
)

recover region from table

void casa::RegionManager::toQuantity ( Quantity out,
const String in 
) [private]

Convert a string to Quantity.

Record* casa::RegionManager::wbox ( const Vector< Quantity > &  blc,
const Vector< Quantity > &  trc,
const Vector< Int > &  pixelaxes,
const CoordinateSystem csys,
const String absrel,
const String comment 
)
Record* casa::RegionManager::wbox ( const Vector< String > &  blc,
const Vector< String > &  trc,
const Vector< Int > &  pixelaxes,
const CoordinateSystem csys,
const String absrel,
const String comment 
)
Record* casa::RegionManager::wbox ( const Vector< Quantity > &  blc,
const Vector< Quantity > &  trc,
const Vector< Int > &  pixelaxes,
const String absrel,
const String comment 
)
Record* casa::RegionManager::wbox ( const Vector< String > &  blc,
const Vector< String > &  trc,
const Vector< Int > &  pixelaxes,
const String absrel,
const String comment 
)
ImageRegion* casa::RegionManager::wbox ( const Vector< Quantity > &  blc,
const Vector< Quantity > &  trc,
const Vector< Int > &  pixelaxes,
const CoordinateSystem csys,
const String absrel = "abs" 
)
static ImageRegion* casa::RegionManager::wellipse ( const Quantity xc,
const Quantity yc,
const Quantity a,
const Quantity b,
const Quantity pa,
const uInt  pixelAxis0,
const uInt  pixelAxis1,
const CoordinateSystem csys,
const String absrel 
) [static]
ImageRegion* casa::RegionManager::wellipse ( const Quantity xc,
const Quantity yc,
const Quantity a,
const Quantity b,
const Quantity pa,
const uInt  pixelAxis0,
const uInt  pixelAxis1,
const String absrel 
) const

wellipse version without csys...throws an exception if setcoordsys is not run

static ImageRegion* casa::RegionManager::wellipsoid ( const Vector< Quantity > &  center,
const Vector< Quantity > &  radii,
const Vector< Int > &  pixelaxes,
const CoordinateSystem csys,
const String absrel 
) [static]
ImageRegion* casa::RegionManager::wellipsoid ( const Vector< Quantity > &  center,
const Vector< Quantity > &  radii,
const Vector< Int > &  pixelaxes,
const String absrel 
) const
static ImageRegion* casa::RegionManager::wmask ( const String command) [static]
ImageRegion* casa::RegionManager::wpolygon ( const Vector< Quantity > &  x,
const Vector< Quantity > &  y,
const Vector< Int > &  pixelaxes,
const CoordinateSystem csys,
const String absrel 
)

Wpolygon with coordsys and if pixelaxes[0] is -1 then its assumed to be 0,1,...

ImageRegion* casa::RegionManager::wpolygon ( const Vector< Quantity > &  x,
const Vector< Quantity > &  y,
const Vector< Int > &  pixelaxes,
const String absrel 
)

wpolygon version without csys...throws an exception if setcoordsys is not run

static Bool casa::RegionManager::writeImageFile ( const String file,
const String regionname,
const Record regionRecord 
) [static]

Writing a file of the AipsIO dump of the record representation of the region.

static ImageRegion* casa::RegionManager::wshell ( const Vector< Quantity > &  center,
const Vector< Quantity > &  innerRadii,
const Vector< Quantity > &  outerRadii,
const Vector< Int > &  pixelaxes,
const CoordinateSystem csys,
const String absrel 
) [static]
ImageRegion* casa::RegionManager::wshell ( const Vector< Quantity > &  center,
const Vector< Quantity > &  innerRadii,
const Vector< Quantity > &  outerRadii,
const Vector< Int > &  pixelaxes,
const String absrel 
) const
static ImageRegion* casa::RegionManager::wsphere ( const Vector< Quantity > &  center,
const Quantity radius,
const Vector< Int > &  pixelaxes,
const CoordinateSystem csys,
const String absrel 
) [static]
ImageRegion* casa::RegionManager::wsphere ( const Vector< Quantity > &  center,
const Quantity radius,
const Vector< Int > &  pixelaxes,
const String absrel 
) const

wsphere version without csys...throws an exception if setcoordsys is not run


Member Data Documentation

Definition at line 262 of file RegionManager.h.

Definition at line 261 of file RegionManager.h.

Referenced by _getLog().

Definition at line 267 of file RegionManager.h.


The documentation for this class was generated from the following file: