#include <HxImgFtorSet.h>
Inheritance diagram for HxImgFtorSet::
Public Types | |
typedef HxImgFtorSetKey | KeyType |
The key type of this class. More... | |
Public Methods | |
HxImgFtorSet () | |
Constructor. More... | |
virtual | ~HxImgFtorSet () |
Destructor. More... | |
Protected Methods | |
virtual void | doIt (Img1DataPtrType dstPtr, Img2DataPtrType srcPtr, HxSizes srcSize, HxSizes dstSize, HxTagList &tags, HxImgFtorDescription *=0) |
Calls HxFuncSet to do the actual work. More... |
Template parameters:
|
The key type of this class.
Reimplemented from HxImgFtorI2Cast. |
|
Constructor.
00022 : HxImgFtorI2Cast<DstImgSigT, SrcImgSigT>( 00023 HxImgFtorSetKey(HxClassName<DstImgSigT>(), HxClassName<SrcImgSigT>())) 00024 { 00025 } |
|
Destructor.
00029 { 00030 } |
|
Calls HxFuncSet to do the actual work.
Reimplemented from HxImgFtorI2Cast.
00039 { 00040 HxPointInt srcBegin, dstBegin, srcEnd, dstEnd; 00041 00042 srcBegin = HxGetTag(tags, "srcBegin", HxPointInt(0, 0, 0)); 00043 srcEnd = HxGetTag(tags, "srcEnd", HxPointInt(srcSize - HxSizes(1, 1, 1))); 00044 dstBegin = HxGetTag(tags, "dstBegin", HxPointInt(0, 0, 0)); 00045 dstEnd = dstSize - HxSizes(1, 1, 1); 00046 00047 if ((srcBegin.inf(HxPointInt(0, 0, 0)) != HxPointInt(0, 0, 0)) 00048 || (srcBegin.sup(srcEnd) != srcEnd)) 00049 { 00050 HxEnvironment::instance()->errorStream() 00051 << "Extended set: source begin out of range" << STD_ENDL; 00052 return; 00053 } 00054 00055 if ((dstBegin.inf(HxPointInt(0, 0, 0)) != HxPointInt(0, 0, 0)) 00056 || (dstBegin.sup(dstEnd) != dstEnd)) 00057 { 00058 HxEnvironment::instance()->errorStream() 00059 << "Extended set: destination begin out of range" << STD_ENDL; 00060 return; 00061 } 00062 00063 if ((srcEnd.inf(srcBegin) != srcBegin) 00064 || (srcEnd.sup(srcSize - HxSizes(1, 1, 1)) 00065 != (srcSize - HxSizes(1, 1, 1)))) 00066 { 00067 HxEnvironment::instance()->errorStream() 00068 << "Extended set: source end out of range" << STD_ENDL; 00069 return; 00070 } 00071 00072 HxSizes regionSize = HxSizes(srcEnd - srcBegin) + HxSizes(1, 1, 1); 00073 regionSize = regionSize.inf(dstSize - HxSizes(dstBegin)); 00074 00075 srcPtr.incXYZ(srcBegin.x(), srcBegin.y(), srcBegin.z()); 00076 dstPtr.incXYZ(dstBegin.x(), dstBegin.y(), dstBegin.z()); 00077 00078 HxFuncSet(dstPtr, srcPtr, regionSize); 00079 } |