eLynx SDK v3.0.1
C++ image processing API reference

eLynx::Math::ConvolutionKernel< T > Struct Template Reference

#include <ConvolutionKernel.h>

List of all members.


Public Types

typedef T type

Public Member Functions

 ConvolutionKernel ()
 ConvolutionKernel (uint32 iWidth, uint32 iHeight, T iV=T(1))
 ConvolutionKernel (uint32 iWidth, uint32 iHeight, const T *iprArray)
 ConvolutionKernel (const ConvolutionKernel &iOther)
template<typename U >
 ConvolutionKernel (const ConvolutionKernel< U > &iOther)
ConvolutionKerneloperator= (const ConvolutionKernel &iOther)
template<typename U >
ConvolutionKerneloperator= (const ConvolutionKernel< U > &iOther)
uint32 GetSize () const
uint32 GetWidth () const
uint32 GetHeight () const
GetSum () const
void Normalize ()
 Normalize elements so that sum of all elements equals 1.
ConvolutionKernel Rotated (const ECompassDirection iDirection) const
bool IsValid () const
 Return the height of kernel.
bool IsHorizontal () const
bool IsVertical () const
bool IsSquare () const
bool Is3x3 () const
bool Is5x5 () const

Public Attributes

boost::shared_array< T > _spK

Detailed Description

template<typename T>
struct eLynx::Math::ConvolutionKernel< T >

Convolution kernel in W x H dimension, used with float and double resolution.

Definition at line 47 of file ConvolutionKernel.h.


Member Typedef Documentation

template<typename T>
typedef T eLynx::Math::ConvolutionKernel< T >::type

Definition at line 49 of file ConvolutionKernel.h.


Constructor & Destructor Documentation

template<typename T>
eLynx::Math::ConvolutionKernel< T >::ConvolutionKernel (  ) 

Default constructor.

template<typename T>
eLynx::Math::ConvolutionKernel< T >::ConvolutionKernel ( uint32  iWidth,
uint32  iHeight,
iV = T(1) 
)

Constructor from size.

Parameters:
iWidth the kernel width.
iHeight the kernel height.
iV the initial value for elements.

template<typename T>
eLynx::Math::ConvolutionKernel< T >::ConvolutionKernel ( uint32  iWidth,
uint32  iHeight,
const T *  iprArray 
)

Constructor from size.

Parameters:
iWidth the kernel width.
iHeight the kernel height.
iprArray pointer on a array iW x iH of element values.

template<typename T>
eLynx::Math::ConvolutionKernel< T >::ConvolutionKernel ( const ConvolutionKernel< T > &  iOther  ) 

Copy constructor from another kernel.

Parameters:
iOther kernel to copy.

template<typename T>
template<typename U >
eLynx::Math::ConvolutionKernel< T >::ConvolutionKernel ( const ConvolutionKernel< U > &  iOther  )  [inline]

Copy constructor from another kernel type.

Parameters:
iOther kernel to copy.


Member Function Documentation

template<typename T>
ConvolutionKernel& eLynx::Math::ConvolutionKernel< T >::operator= ( const ConvolutionKernel< T > &  iOther  ) 

Assignment operator with another kernel.

Parameters:
iOther kernel to assign.

template<typename T>
template<typename U >
ConvolutionKernel& eLynx::Math::ConvolutionKernel< T >::operator= ( const ConvolutionKernel< U > &  iOther  )  [inline]

Assignment operator with another kernel type.

Parameters:
iOther kernel to assign.

template<typename T>
uint32 eLynx::Math::ConvolutionKernel< T >::GetSize (  )  const

Return the size of kernel, size = width * height.

Returns:
The kernel's size in elements.

template<typename T>
uint32 eLynx::Math::ConvolutionKernel< T >::GetWidth (  )  const

Return the width of kernel.

Returns:
The kernel's width in elements.

template<typename T>
uint32 eLynx::Math::ConvolutionKernel< T >::GetHeight (  )  const

Return the height of kernel.

Returns:
The kernel's height in elements.

template<typename T>
T eLynx::Math::ConvolutionKernel< T >::GetSum (  )  const

Return the sum of all elements of kernel.

Returns:
The sum of all elements.

template<typename T>
void eLynx::Math::ConvolutionKernel< T >::Normalize (  ) 

Normalize elements so that sum of all elements equals 1.

template<typename T>
ConvolutionKernel eLynx::Math::ConvolutionKernel< T >::Rotated ( const ECompassDirection  iDirection  )  const

Return a rotated convolution kernel NxN sized only for square kernel.

Parameters:
iDirection the new direction relative to north.
Returns:
the rotated kernel.

template<typename T>
bool eLynx::Math::ConvolutionKernel< T >::IsValid (  )  const

Return the height of kernel.

template<typename T>
bool eLynx::Math::ConvolutionKernel< T >::IsHorizontal (  )  const

Return if kernel is W x 1 sized.

Returns:
true is kernel is horizontal, false otherwise.

template<typename T>
bool eLynx::Math::ConvolutionKernel< T >::IsVertical (  )  const

Return if kernel is 1 x H sized.

Returns:
true is kernel is vertical, false otherwise.

template<typename T>
bool eLynx::Math::ConvolutionKernel< T >::IsSquare (  )  const

Return if kernel is N x N sized.

Returns:
true is kernel is squared, false otherwise.

template<typename T>
bool eLynx::Math::ConvolutionKernel< T >::Is3x3 (  )  const

Return if kernel is 3x3 sized.

Returns:
true is kernel is 3x3 sized, false otherwise.

template<typename T>
bool eLynx::Math::ConvolutionKernel< T >::Is5x5 (  )  const

Return if kernel is 5x5 sized.

Returns:
true is kernel is 5x5 sized, false otherwise.


Member Data Documentation

template<typename T>
boost::shared_array<T> eLynx::Math::ConvolutionKernel< T >::_spK

Definition at line 136 of file ConvolutionKernel.h.


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

Generated on 14 Apr 2009 by doxygen 1.5.8