Main Page   Class Overview   Pixels   Images   Geometry   Quick Index  

HxImgFtorGenConv2dK1d Class Template Reference

Instantiation of generic algorithm for generalized convolution operations on 2d images with a 1d kernel. More...

#include <HxImgFtorGenConv2dK1d.h>

Inheritance diagram for HxImgFtorGenConv2dK1d::

HxImgFtorI3Cast< DstImgSigT, SrcImgSigT, KerImgSigT > HxImgFtorI3 HxImgFunctor List of all members.

Public Types

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

typedef SrcImgSigT::DataPtrType SrcDataPtrType
 The data pointer type of the source image. More...

typedef KerImgSigT::DataPtrType KerDataPtrType
 The data pointer type of the kernel image. More...


Public Methods

 HxImgFtorGenConv2dK1d ()
 Constructor. More...

virtual ~HxImgFtorGenConv2dK1d ()
 Destructor. More...


Protected Methods

virtual void doIt (DstDataPtrType dstPtr, SrcDataPtrType srcPtr, KerDataPtrType kerPtr, HxSizes dstSize, HxSizes srcSize, HxSizes kerSize, HxTagList &tags, HxImgFtorDescription *=0)
 Calls convolutionX, convolutionY, convolutionXIp, or convolutionYIp to do the actual work based on the "dimension" and "inplace" tags. More...

void convolutionX (DstDataPtrType dstPtr, SrcDataPtrType srcPtr, KerDataPtrType kerPtr, HxSizes dstSize, HxSizes srcSize, HxSizes kerSize, HxTagList &tags)
void convolutionY (DstDataPtrType dstPtr, SrcDataPtrType srcPtr, KerDataPtrType kerPtr, HxSizes dstSize, HxSizes srcSize, HxSizes kerSize, HxTagList &tags)
void convolutionXIp (DstDataPtrType dstPtr, SrcDataPtrType srcPtr, KerDataPtrType kerPtr, HxSizes dstSize, HxSizes srcSize, HxSizes kerSize, HxTagList &tags)
void convolutionYIp (DstDataPtrType dstPtr, SrcDataPtrType srcPtr, KerDataPtrType kerPtr, HxSizes dstSize, HxSizes srcSize, HxSizes kerSize, HxTagList &tags)

Detailed Description

template<class DstImgSigT, class SrcImgSigT, class KerImgSigT, class PixOpT, class RedOpT, class KernelT>
class HxImgFtorGenConv2dK1d< DstImgSigT, SrcImgSigT, KerImgSigT, PixOpT, RedOpT, KernelT >

Instantiation of generic algorithm for generalized convolution operations on 2d images with a 1d kernel.


Member Typedef Documentation

template<class DstImgSigT, class SrcImgSigT, class KerImgSigT, class PixOpT, class RedOpT, class KernelT>
typedef HxImgFtorGenConvK1dKey HxImgFtorGenConv2dK1d::KeyType
 

The key type of this class.

Reimplemented from HxImgFtorI3Cast.

template<class DstImgSigT, class SrcImgSigT, class KerImgSigT, class PixOpT, class RedOpT, class KernelT>
typedef SrcImgSigT::DataPtrType HxImgFtorGenConv2dK1d::SrcDataPtrType
 

The data pointer type of the source image.

template<class DstImgSigT, class SrcImgSigT, class KerImgSigT, class PixOpT, class RedOpT, class KernelT>
typedef KerImgSigT::DataPtrType HxImgFtorGenConv2dK1d::KerDataPtrType
 

The data pointer type of the kernel image.


Constructor & Destructor Documentation

template<class DstImgSigT, class SrcImgSigT, class KerImgSigT, class PixOpT, class RedOpT, class KernelT>
HxImgFtorGenConv2dK1d< DstImgSigT, SrcImgSigT, KerImgSigT, PixOpT, RedOpT, KernelT >::HxImgFtorGenConv2dK1d   [inline]
 

Constructor.

00024         : HxImgFtorI3Cast<DstImgSigT, SrcImgSigT, KerImgSigT>(
00025             HxImgFtorGenConvK1dKey(HxClassName<DstImgSigT>(), 
00026                 HxClassName<SrcImgSigT>(), HxClassName<KerImgSigT>(), 
00027                 HxClassName<PixOpT>(), HxClassName<RedOpT>(),
00028                 HxClassName<KernelT>()))
00029 {
00030 #ifdef CD_TRACE
00031     HxEnvironment::instance()->outputStream()
00032         << "HxImgFtorGenConv2dK1d::HxImgFtorGenConv2dK1d()" << STD_ENDL;
00033 #endif
00034 }

template<class DstImgSigT, class SrcImgSigT, class KerImgSigT, class PixOpT, class RedOpT, class KernelT>
HxImgFtorGenConv2dK1d< DstImgSigT, SrcImgSigT, KerImgSigT, PixOpT, RedOpT, KernelT >::~HxImgFtorGenConv2dK1d   [virtual]
 

Destructor.

00040 {
00041 #ifdef CD_TRACE
00042     HxEnvironment::instance()->outputStream()
00043         << "HxImgFtorGenConv2dK1d::~HxImgFtorGenConv2dK1d()" << STD_ENDL;
00044 #endif
00045 }


Member Function Documentation

template<class DstImgSigT, class SrcImgSigT, class KerImgSigT, class PixOpT, class RedOpT, class KernelT>
void HxImgFtorGenConv2dK1d< DstImgSigT, SrcImgSigT, KerImgSigT, PixOpT, RedOpT, KernelT >::doIt DstDataPtrType    dstPtr,
SrcDataPtrType    srcPtr,
KerDataPtrType    kerPtr,
HxSizes    dstSize,
HxSizes    srcSize,
HxSizes    kerSize,
HxTagList   tags,
HxImgFtorDescription   description = 0
[protected, virtual]
 

Calls convolutionX, convolutionY, convolutionXIp, or convolutionYIp to do the actual work based on the "dimension" and "inplace" tags.

00056 {
00057     int dimension = HxGetTag<int>(tags, "dimension");
00058     bool inplace = HxGetTag(tags, "inplace", false);
00059 
00060     if (inplace && description)
00061         description->setVariation("inplace");
00062 
00063     switch (dimension) {
00064     case 1  :
00065         if (inplace)
00066             convolutionXIp(
00067                 dstPtr, srcPtr, kerPtr, dstSize, srcSize, kerSize, tags);
00068         else
00069             convolutionX(
00070                 dstPtr, srcPtr, kerPtr, dstSize, srcSize, kerSize, tags);
00071         break;
00072     case 2  :
00073         if (inplace)
00074             convolutionYIp(
00075                 dstPtr, srcPtr, kerPtr, dstSize, srcSize, kerSize, tags);
00076         else
00077             convolutionY(
00078                 dstPtr, srcPtr, kerPtr, dstSize, srcSize, kerSize, tags);
00079         break;
00080     default :
00081         HxEnvironment::instance()->errorStream()
00082             << "Generalized convolution (2d image, 1d kernel): "
00083             << "cannot execute convolution in dimension " << dimension
00084             << STD_ENDL;
00085         HxEnvironment::instance()->flush();
00086     }
00087 }


The documentation for this class was generated from the following files:
Generated on Tue Jan 8 13:59:28 2002 for C++Reference by doxygen1.2.12 written by Dimitri van Heesch, © 1997-2001