diff options
Diffstat (limited to 'tksao')
-rw-r--r-- | tksao/frame/base.h | 22 | ||||
-rw-r--r-- | tksao/frame/baseload.C | 40 | ||||
-rw-r--r-- | tksao/frame/frame.h | 11 | ||||
-rw-r--r-- | tksao/frame/frameload.C | 211 |
4 files changed, 253 insertions, 31 deletions
diff --git a/tksao/frame/base.h b/tksao/frame/base.h index e928964..808ada8 100644 --- a/tksao/frame/base.h +++ b/tksao/frame/base.h @@ -848,17 +848,17 @@ public: virtual void loadMosaicImageSocketGZCmd(MosaicType, Coord::CoordSystem, int, const char*, LayerType); virtual void loadMosaicImageVarCmd(MosaicType, Coord::CoordSystem, const char*,const char*, LayerType); - void loadMosaicAllocCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); - void loadMosaicAllocGZCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); - void loadMosaicChannelCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); - void loadMosaicMMapCmd(MosaicType, Coord::CoordSystem, const char*, LayerType); - void loadMosaicSMMapCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); - void loadMosaicMMapIncrCmd(MosaicType, Coord::CoordSystem, const char*, LayerType); - void loadMosaicShareCmd(MosaicType, Coord::CoordSystem, ShmType, int, const char*, LayerType); - void loadMosaicSShareCmd(MosaicType, Coord::CoordSystem, ShmType, int, int, const char*, LayerType); - void loadMosaicSocketCmd(MosaicType, Coord::CoordSystem, int, const char*, LayerType); - void loadMosaicSocketGZCmd(MosaicType, Coord::CoordSystem, int, const char*, LayerType); - void loadMosaicVarCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); + virtual void loadMosaicAllocCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); + virtual void loadMosaicAllocGZCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); + virtual void loadMosaicChannelCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); + virtual void loadMosaicMMapCmd(MosaicType, Coord::CoordSystem, const char*, LayerType); + virtual void loadMosaicSMMapCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); + virtual void loadMosaicMMapIncrCmd(MosaicType, Coord::CoordSystem, const char*, LayerType); + virtual void loadMosaicShareCmd(MosaicType, Coord::CoordSystem, ShmType, int, const char*, LayerType); + virtual void loadMosaicSShareCmd(MosaicType, Coord::CoordSystem, ShmType, int, int, const char*, LayerType); + virtual void loadMosaicSocketCmd(MosaicType, Coord::CoordSystem, int, const char*, LayerType); + virtual void loadMosaicSocketGZCmd(MosaicType, Coord::CoordSystem, int, const char*, LayerType); + virtual void loadMosaicVarCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); void loadMosaicImageWFPC2AllocCmd(const char*, const char*); void loadMosaicImageWFPC2AllocGZCmd(const char*, const char*); diff --git a/tksao/frame/baseload.C b/tksao/frame/baseload.C index 30bcfa2..3316659 100644 --- a/tksao/frame/baseload.C +++ b/tksao/frame/baseload.C @@ -402,7 +402,7 @@ void Base::loadMosaicImageAllocCmd(MosaicType type, Coord::CoordSystem sys, unloadFits(); FitsImage* img = new FitsImageMosaicAlloc(currentContext, interp, ch, fn, FitsFile::NOFLUSH, 1); - loadDone(currentContext->loadMosaicImage(ALLOC, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaicImage(ALLOC, fn, img, type, sys)); } void Base::loadMosaicImageAllocGZCmd(MosaicType type, Coord::CoordSystem sys, @@ -412,7 +412,7 @@ void Base::loadMosaicImageAllocGZCmd(MosaicType type, Coord::CoordSystem sys, unloadFits(); FitsImage* img = new FitsImageMosaicAllocGZ(currentContext, interp, ch, fn, FitsFile::NOFLUSH, 1); - loadDone(currentContext->loadMosaicImage(ALLOCGZ, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaicImage(ALLOCGZ, fn, img, type, sys)); } void Base::loadMosaicImageChannelCmd(MosaicType type, Coord::CoordSystem sys, @@ -423,7 +423,7 @@ void Base::loadMosaicImageChannelCmd(MosaicType type, Coord::CoordSystem sys, FitsImage* img = new FitsImageMosaicChannel(currentContext, interp, ch, fn, FitsFile::NOFLUSH, 1); - loadDone(currentContext->loadMosaicImage(CHANNEL, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaicImage(CHANNEL, fn, img, type, sys)); } void Base::loadMosaicImageMMapCmd(MosaicType type, Coord::CoordSystem sys, @@ -432,7 +432,7 @@ void Base::loadMosaicImageMMapCmd(MosaicType type, Coord::CoordSystem sys, unloadFits(); FitsImage* img = new FitsImageMosaicMMap(currentContext, interp, fn, 1); - loadDone(currentContext->loadMosaicImage(MMAP, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaicImage(MMAP, fn, img, type, sys)); } void Base::loadMosaicImageMMapIncrCmd(MosaicType type, Coord::CoordSystem sys, @@ -441,7 +441,7 @@ void Base::loadMosaicImageMMapIncrCmd(MosaicType type, Coord::CoordSystem sys, unloadFits(); FitsImage* img = new FitsImageMosaicMMapIncr(currentContext, interp, fn, 1); - loadDone(currentContext->loadMosaicImage(MMAPINCR, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaicImage(MMAPINCR, fn, img, type, sys)); } void Base::loadMosaicImageShareCmd(MosaicType type, Coord::CoordSystem sys, @@ -451,7 +451,7 @@ void Base::loadMosaicImageShareCmd(MosaicType type, Coord::CoordSystem sys, unloadFits(); FitsImage* img = new FitsImageMosaicShare(currentContext, interp, stype, id, fn, 1); - loadDone(currentContext->loadMosaicImage(SHARE, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaicImage(SHARE, fn, img, type, sys)); } void Base::loadMosaicImageSocketCmd(MosaicType type, Coord::CoordSystem sys, @@ -460,7 +460,7 @@ void Base::loadMosaicImageSocketCmd(MosaicType type, Coord::CoordSystem sys, unloadFits(); FitsImage* img = new FitsImageMosaicSocket(currentContext, interp, s, fn, FitsFile::NOFLUSH, 1); - loadDone(currentContext->loadMosaicImage(SOCKET, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaicImage(SOCKET, fn, img, type, sys)); } void Base::loadMosaicImageSocketGZCmd(MosaicType type, @@ -470,7 +470,7 @@ void Base::loadMosaicImageSocketGZCmd(MosaicType type, unloadFits(); FitsImage* img = new FitsImageMosaicSocketGZ(currentContext, interp, s, fn, FitsFile::NOFLUSH, 1); - loadDone(currentContext->loadMosaicImage(SOCKETGZ, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaicImage(SOCKETGZ, fn, img, type, sys)); } void Base::loadMosaicImageVarCmd(MosaicType type, Coord::CoordSystem sys, @@ -479,7 +479,7 @@ void Base::loadMosaicImageVarCmd(MosaicType type, Coord::CoordSystem sys, unloadFits(); FitsImage* img = new FitsImageMosaicVar(currentContext, interp, ch, fn, 1); - loadDone(currentContext->loadMosaicImage(VAR, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaicImage(VAR, fn, img, type, sys)); } // *** Mosaic *** @@ -489,7 +489,7 @@ void Base::loadMosaicAllocCmd(MosaicType type, Coord::CoordSystem sys, { FitsImage* img = new FitsImageFitsAlloc(currentContext, interp, ch, fn, FitsFile::NOFLUSH, 1); - loadDone(currentContext->loadMosaic(ALLOC, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaic(ALLOC, fn, img, type, sys)); } void Base::loadMosaicAllocGZCmd(MosaicType type, Coord::CoordSystem sys, @@ -497,7 +497,7 @@ void Base::loadMosaicAllocGZCmd(MosaicType type, Coord::CoordSystem sys, { FitsImage* img = new FitsImageFitsAllocGZ(currentContext, interp, ch, fn, FitsFile::NOFLUSH, 1); - loadDone(currentContext->loadMosaic(ALLOCGZ, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaic(ALLOCGZ, fn, img, type, sys)); } void Base::loadMosaicChannelCmd(MosaicType type, Coord::CoordSystem sys, @@ -506,7 +506,7 @@ void Base::loadMosaicChannelCmd(MosaicType type, Coord::CoordSystem sys, FitsImage* img = new FitsImageFitsChannel(currentContext, interp, ch, fn, FitsFile::NOFLUSH, 1); - loadDone(currentContext->loadMosaic(CHANNEL, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaic(CHANNEL, fn, img, type, sys)); } void Base::loadMosaicMMapCmd(MosaicType type, Coord::CoordSystem sys, @@ -514,7 +514,7 @@ void Base::loadMosaicMMapCmd(MosaicType type, Coord::CoordSystem sys, { FitsImage* img = new FitsImageFitsMMap(currentContext, interp, fn, 1); - loadDone(currentContext->loadMosaic(MMAP, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaic(MMAP, fn, img, type, sys)); } void Base::loadMosaicSMMapCmd(MosaicType type, Coord::CoordSystem sys, @@ -523,7 +523,7 @@ void Base::loadMosaicSMMapCmd(MosaicType type, Coord::CoordSystem sys, { FitsImage* img = new FitsImageFitsSMMap(currentContext, interp, hdr, fn, 1); - loadDone(currentContext->loadMosaic(MMAP, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaic(MMAP, fn, img, type, sys)); } void Base::loadMosaicMMapIncrCmd(MosaicType type, Coord::CoordSystem sys, @@ -531,7 +531,7 @@ void Base::loadMosaicMMapIncrCmd(MosaicType type, Coord::CoordSystem sys, { FitsImage* img = new FitsImageFitsMMapIncr(currentContext, interp, fn, 1); - loadDone(currentContext->loadMosaic(MMAPINCR, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaic(MMAPINCR, fn, img, type, sys)); } void Base::loadMosaicShareCmd(MosaicType type, Coord::CoordSystem sys, @@ -540,7 +540,7 @@ void Base::loadMosaicShareCmd(MosaicType type, Coord::CoordSystem sys, { FitsImage* img = new FitsImageFitsShare(currentContext, interp, stype, id, fn, 1); - loadDone(currentContext->loadMosaic(SHARE, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaic(SHARE, fn, img, type, sys)); } void Base::loadMosaicSShareCmd(MosaicType type, Coord::CoordSystem sys, @@ -549,7 +549,7 @@ void Base::loadMosaicSShareCmd(MosaicType type, Coord::CoordSystem sys, { FitsImage* img = new FitsImageFitsSShare(currentContext, interp, stype, hdr, id, fn, 1); - loadDone(currentContext->loadMosaic(SSHARE, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaic(SSHARE, fn, img, type, sys)); } void Base::loadMosaicSocketCmd(MosaicType type, Coord::CoordSystem sys, @@ -557,7 +557,7 @@ void Base::loadMosaicSocketCmd(MosaicType type, Coord::CoordSystem sys, { FitsImage* img = new FitsImageFitsSocket(currentContext, interp, s, fn, FitsFile::FLUSH, 1); - loadDone(currentContext->loadMosaic(SOCKET, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaic(SOCKET, fn, img, type, sys)); } void Base::loadMosaicSocketGZCmd(MosaicType type, Coord::CoordSystem sys, @@ -565,7 +565,7 @@ void Base::loadMosaicSocketGZCmd(MosaicType type, Coord::CoordSystem sys, { FitsImage* img = new FitsImageFitsSocketGZ(currentContext, interp, s, fn, FitsFile::FLUSH, 1); - loadDone(currentContext->loadMosaic(SOCKETGZ, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaic(SOCKETGZ, fn, img, type, sys)); } void Base::loadMosaicVarCmd(MosaicType type, Coord::CoordSystem sys, @@ -574,7 +574,7 @@ void Base::loadMosaicVarCmd(MosaicType type, Coord::CoordSystem sys, { FitsImage* img = new FitsImageFitsVar(currentContext, interp, ch, fn, 1); - loadDone(currentContext->loadMosaic(VAR, fn, img, type, sys), ll); + loadDone(currentContext->loadMosaic(VAR, fn, img, type, sys)); } // *** Mosaic Image WFPC2 *** diff --git a/tksao/frame/frame.h b/tksao/frame/frame.h index 4ce1b0b..0420d5e 100644 --- a/tksao/frame/frame.h +++ b/tksao/frame/frame.h @@ -127,6 +127,17 @@ class Frame : public FrameBase { void loadMosaicImageSocketGZCmd(MosaicType, Coord::CoordSystem, int, const char*, LayerType); void loadMosaicImageVarCmd(MosaicType, Coord::CoordSystem, const char*,const char*, LayerType); + void loadMosaicAllocCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); + void loadMosaicAllocGZCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); + void loadMosaicChannelCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); + void loadMosaicMMapCmd(MosaicType, Coord::CoordSystem, const char*, LayerType); + void loadMosaicSMMapCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); + void loadMosaicMMapIncrCmd(MosaicType, Coord::CoordSystem, const char*, LayerType); + void loadMosaicShareCmd(MosaicType, Coord::CoordSystem, ShmType, int, const char*, LayerType); + void loadMosaicSShareCmd(MosaicType, Coord::CoordSystem, ShmType, int, int, const char*, LayerType); + void loadMosaicSocketCmd(MosaicType, Coord::CoordSystem, int, const char*, LayerType); + void loadMosaicSocketGZCmd(MosaicType, Coord::CoordSystem, int, const char*, LayerType); + void loadMosaicVarCmd(MosaicType, Coord::CoordSystem, const char*, const char*, LayerType); }; #endif diff --git a/tksao/frame/frameload.C b/tksao/frame/frameload.C index 2cc4567..24dadcf 100644 --- a/tksao/frame/frameload.C +++ b/tksao/frame/frameload.C @@ -613,6 +613,217 @@ void Frame::loadMosaicImageVarCmd(MosaicType type, Coord::CoordSystem sys, } } +// *** Mosaic *** + +void Frame::loadMosaicAllocCmd(MosaicType type, Coord::CoordSystem sys, + const char* ch, const char* fn, LayerType ll) +{ + switch (ll) { + case IMG: + Base::loadMosaicAllocCmd(type, sys, ch, fn, ll); + break; + case MASK: + FitsMask* msk = new FitsMask(this, maskColorName, maskMark); + mask.append(msk); + Context* cc = msk->context(); + FitsImage* img = new FitsImageFitsAlloc(cc, interp, + ch, fn, FitsFile::NOFLUSH, 1); + loadDone(cc->loadMosaic(ALLOC, fn, img, type, sys)); + break; + } +} + +void Frame::loadMosaicAllocGZCmd(MosaicType type, Coord::CoordSystem sys, + const char* ch, const char* fn, LayerType ll) +{ + switch (ll) { + case IMG: + Base::loadMosaicAllocGZCmd(type, sys, ch, fn, ll); + break; + case MASK: + FitsMask* msk = new FitsMask(this, maskColorName, maskMark); + mask.append(msk); + Context* cc = msk->context(); + FitsImage* img = new FitsImageFitsAllocGZ(cc, interp, + ch, fn, FitsFile::NOFLUSH, 1); + loadDone(cc->loadMosaic(ALLOCGZ, fn, img, type, sys)); + break; + } +} + +void Frame::loadMosaicChannelCmd(MosaicType type, Coord::CoordSystem sys, + const char* ch, const char* fn, LayerType ll) +{ + switch (ll) { + case IMG: + Base::loadMosaicChannelCmd(type, sys, ch, fn, ll); + break; + case MASK: + FitsMask* msk = new FitsMask(this, maskColorName, maskMark); + mask.append(msk); + Context* cc = msk->context(); + FitsImage* img = new FitsImageFitsChannel(cc, interp, + ch, fn, FitsFile::NOFLUSH, 1); + loadDone(cc->loadMosaic(CHANNEL, fn, img, type, sys)); + break; + } + +} + +void Frame::loadMosaicMMapCmd(MosaicType type, Coord::CoordSystem sys, + const char* fn, LayerType ll) +{ + switch (ll) { + case IMG: + Base::loadMosaicMMapCmd(type, sys, fn, ll); + break; + case MASK: + FitsMask* msk = new FitsMask(this, maskColorName, maskMark); + mask.append(msk); + Context* cc = msk->context(); + FitsImage* img = new FitsImageFitsMMap(cc, interp, + fn, 1); + loadDone(cc->loadMosaic(MMAP, fn, img, type, sys)); + break; + } + +} + +void Frame::loadMosaicSMMapCmd(MosaicType type, Coord::CoordSystem sys, + const char* hdr, const char* fn, + LayerType ll) +{ + switch (ll) { + case IMG: + Base::loadMosaicSMMapCmd(type, sys, hdr, fn, ll); + break; + case MASK: + FitsMask* msk = new FitsMask(this, maskColorName, maskMark); + mask.append(msk); + Context* cc = msk->context(); + FitsImage* img = new FitsImageFitsSMMap(cc, interp, + hdr, fn, 1); + loadDone(cc->loadMosaic(MMAP, fn, img, type, sys)); + break; + } + +} + +void Frame::loadMosaicMMapIncrCmd(MosaicType type, Coord::CoordSystem sys, + const char* fn, LayerType ll) +{ + switch (ll) { + case IMG: + Base::loadMosaicMMapIncrCmd(type, sys, fn, ll); + break; + case MASK: + FitsMask* msk = new FitsMask(this, maskColorName, maskMark); + mask.append(msk); + Context* cc = msk->context(); + FitsImage* img = new FitsImageFitsMMapIncr(cc, interp, + fn, 1); + loadDone(cc->loadMosaic(MMAPINCR, fn, img, type, sys)); + break; + } + +} + +void Frame::loadMosaicShareCmd(MosaicType type, Coord::CoordSystem sys, + ShmType stype, int id, const char* fn, + LayerType ll) +{ + switch (ll) { + case IMG: + Base::loadMosaicShareCmd(type, sys, stype, id, fn, ll); + break; + case MASK: + FitsMask* msk = new FitsMask(this, maskColorName, maskMark); + mask.append(msk); + Context* cc = msk->context(); + FitsImage* img = new FitsImageFitsShare(cc, interp, + stype, id, fn, 1); + loadDone(cc->loadMosaic(SHARE, fn, img, type, sys)); + break; + } + +} + +void Frame::loadMosaicSShareCmd(MosaicType type, Coord::CoordSystem sys, + ShmType stype, int hdr, int id, const char* fn, + LayerType ll) +{ + switch (ll) { + case IMG: + Base::loadMosaicSShareCmd(type, sys, stype, hdr, id, fn, ll); + break; + case MASK: + FitsMask* msk = new FitsMask(this, maskColorName, maskMark); + mask.append(msk); + Context* cc = msk->context(); + FitsImage* img = new FitsImageFitsSShare(cc, interp, + stype, hdr, id, fn, 1); + loadDone(cc->loadMosaic(SSHARE, fn, img, type, sys)); + break; + } + +} + +void Frame::loadMosaicSocketCmd(MosaicType type, Coord::CoordSystem sys, + int s, const char* fn, LayerType ll) +{ + switch (ll) { + case IMG: + Base::loadMosaicSocketCmd(type, sys, s, fn, ll); + break; + case MASK: + FitsMask* msk = new FitsMask(this, maskColorName, maskMark); + mask.append(msk); + Context* cc = msk->context(); + FitsImage* img = new FitsImageFitsSocket(cc, interp, + s, fn, FitsFile::FLUSH, 1); + loadDone(cc->loadMosaic(SOCKET, fn, img, type, sys)); + break; + } + +} + +void Frame::loadMosaicSocketGZCmd(MosaicType type, Coord::CoordSystem sys, + int s, const char* fn, LayerType ll) +{ + switch (ll) { + case IMG: + Base::loadMosaicSocketGZCmd(type, sys, s, fn, ll); + break; + case MASK: + FitsMask* msk = new FitsMask(this, maskColorName, maskMark); + mask.append(msk); + Context* cc = msk->context(); + FitsImage* img = new FitsImageFitsSocketGZ(cc, interp, + s, fn, FitsFile::FLUSH, 1); + loadDone(cc->loadMosaic(SOCKETGZ, fn, img, type, sys)); + break; + } +} + +void Frame::loadMosaicVarCmd(MosaicType type, Coord::CoordSystem sys, + const char* ch, const char* fn, + LayerType ll) +{ + switch (ll) { + case IMG: + Base::loadMosaicVarCmd(type, sys, ch, fn, ll); + break; + case MASK: + FitsMask* msk = new FitsMask(this, maskColorName, maskMark); + mask.append(msk); + Context* cc = msk->context(); + FitsImage* img = new FitsImageFitsVar(cc, interp, + ch, fn, 1); + loadDone(cc->loadMosaic(VAR, fn, img, type, sys)); + break; + } +} + // Support void Frame::loadDone(int rr) |