Horus Doc || C++ Reference || Class Overview   Pixels   Images   Detector   Geometry   Registry || Doxygen's quick Index  

HxImgFtorSetBorder2d Class Template Reference

Instantiation of generic algorithm for border operations on 2D images. More...

#include <HxImgFtorSetBorder2d.h>

Inheritance diagram for HxImgFtorSetBorder2d::

HxImgFtorI1Cast HxImgFtorI1 HxImgFunctor List of all members.

Public Types

typedef HxImgFtorSetBorderKey KeyType
 The key type of this class. More...


Public Methods

 HxImgFtorSetBorder2d ()
 Constructor. More...

virtual ~HxImgFtorSetBorder2d ()
 Destructor. More...


Protected Methods

virtual void doIt (ImgDataPtrType imgPtr, HxSizes imgSize, HxTagList &tags, HxImgFtorDescription *=0)
 Calls one of the functions below to do the actual work based on the "borderType" tag: HxFuncBorderConstant2d, HxFuncBorderMirror2d (default), HxFuncBorderPropagate2d. More...


Detailed Description

template<class ImgSigT>
class HxImgFtorSetBorder2d< ImgSigT >

Instantiation of generic algorithm for border operations on 2D images.

Template parameters:


Member Typedef Documentation

template<class ImgSigT>
typedef HxImgFtorSetBorderKey HxImgFtorSetBorder2d::KeyType
 

The key type of this class.

Reimplemented from HxImgFtorI1Cast.


Constructor & Destructor Documentation

template<class ImgSigT>
HxImgFtorSetBorder2d< ImgSigT >::HxImgFtorSetBorder2d   [inline]
 

Constructor.

template<class ImgSigT>
HxImgFtorSetBorder2d< ImgSigT >::~HxImgFtorSetBorder2d   [virtual]
 

Destructor.

00027 {
00028 }


Member Function Documentation

template<class ImgSigT>
void HxImgFtorSetBorder2d< ImgSigT >::doIt ImgDataPtrType    imgPtr,
HxSizes    imgSize,
HxTagList   tags,
HxImgFtorDescription   description = 0
[protected, virtual]
 

Calls one of the functions below to do the actual work based on the "borderType" tag: HxFuncBorderConstant2d, HxFuncBorderMirror2d (default), HxFuncBorderPropagate2d.

Reimplemented from HxImgFtorI1Cast.

00036 {
00037     HxBorderType borderType
00038         = HxGetTag(tags, "borderType", HxBorderType(HXBORDERMIRROR));
00039     HxSizes borderSize = HxGetTag(tags, "borderSize", HxSizes(0, 0, 0));
00040 
00041     switch (borderType)
00042     {
00043     case HXBORDERCONSTANT   :
00044         {
00045             HxValue value = HxGetTag(tags, "borderValue", HxValue(0));
00046             HxFuncBorderConstant2d(imgPtr, imgSize, borderSize, value);
00047         }
00048         break;
00049     case HXBORDERMIRROR     :
00050         HxFuncBorderMirror2d(imgPtr, imgSize, borderSize);
00051         break;
00052     case HXBORDERPROPAGATE  :
00053         HxFuncBorderPropagate2d(imgPtr, imgSize, borderSize);
00054         break;
00055     case HXBORDERPROPAGATENORMALIZED   :
00056         {
00057             HxValue lValue = HxGetTag(tags, "LeftBorderValue", HxValue(1));
00058             HxValue rValue = HxGetTag(tags, "RightBorderValue", HxValue(1));
00059             HxValue tValue = HxGetTag(tags, "TopBorderValue", HxValue(1));
00060             HxValue bValue = HxGetTag(tags, "BottomBorderValue", HxValue(1));
00061             HxFuncBorderPropagateNormalized2d(imgPtr, imgSize, borderSize,
00062                                               lValue, rValue, tValue, bValue);
00063         }
00064         break;
00065     }
00066 }


The documentation for this class was generated from the following files:
Generated on Tue Feb 3 14:19:01 2004 for C++Reference by doxygen1.2.12 written by Dimitri van Heesch, © 1997-2001