Ocean
Ocean::CV::FrameNorm Class Reference

This class implements functions allowing to determine norms of images e.g, a L2 norm. More...

Static Public Member Functions

template<typename T , typename TNorm >
static TNorm normL2 (const T *data, const size_t size)
 Determines the L2 norm (square root of summed squares) of given data. More...
 
template<typename T , typename TNorm >
static TNorm normL2 (const T *frame, const unsigned int width, const unsigned int height, const unsigned int framePaddingElements)
 Determines the L2 norm (square root of summed squares) of a given frame allowing to specify a padding to enable the application of e.g., sub-frames. More...
 
template<typename T , typename TNorm >
static TNorm squaredNormL2 (const T *data, const size_t size)
 Determines the squared L2 norm (summed squares) of given data. More...
 
template<typename T , typename TNorm >
static TNorm squaredNormL2 (const T *frame, const unsigned int width, const unsigned int height, const unsigned int framePaddingElements)
 Determines the squared L2 norm (summed squares) of a given frame allowing to specify a padding to enable the application of e.g., sub-frames. More...
 

Detailed Description

This class implements functions allowing to determine norms of images e.g, a L2 norm.

Member Function Documentation

◆ normL2() [1/2]

template<typename T , typename TNorm >
TNorm Ocean::CV::FrameNorm::normL2 ( const T *  data,
const size_t  size 
)
static

Determines the L2 norm (square root of summed squares) of given data.

This function is actually a wrapper around normL2() - and applies the sqrt calculation in addition.

Parameters
dataThe data for which the norm value will be determined, must be valid
sizeThe size of the given data in elements, with range [1, infinity)
Returns
The resulting L2 norm
Template Parameters
TData type of each value, e.g., 'uint8_t' or 'float'
TNormThe data type of the resulting norm (and the intermediate sum), e.g., 'uint32_t' or 'double'
See also
squaredNormL2().

◆ normL2() [2/2]

template<typename T , typename TNorm >
TNorm Ocean::CV::FrameNorm::normL2 ( const T *  frame,
const unsigned int  width,
const unsigned int  height,
const unsigned int  framePaddingElements 
)
static

Determines the L2 norm (square root of summed squares) of a given frame allowing to specify a padding to enable the application of e.g., sub-frames.

This function is actually a wrapper around normL2() - and applies the sqrt calculation in addition.

Parameters
frameThe data of the frame for which the norm value will be determined, must be valid
widthThe width of the given frame in pixel, with range [1, infinity)
heightThe height of the given frame in pixel, with range [1, infinity)
framePaddingElementsThe number of padding elements at the end of each row, in elements, with range [0, infinity)
Returns
The resulting L2 norm
Template Parameters
TData type of each value, e.g., 'unsigned char' or 'float'
TNormThe data type of the resulting norm (and the intermediate sum), e.g., 'unsigned int' or 'double'
See also
squaredNormL2().

◆ squaredNormL2() [1/2]

template<typename T , typename TNorm >
TNorm Ocean::CV::FrameNorm::squaredNormL2 ( const T *  data,
const size_t  size 
)
static

Determines the squared L2 norm (summed squares) of given data.

Parameters
dataThe data for which the norm value will be determined, must be valid
sizeThe size of the given data in elements, with range [1, infinity)
Returns
The resulting L2 norm
Template Parameters
TData type of each value, e.g., 'uint8_t' or 'float'
TNormThe data type of the resulting norm (and the intermediate sum), e.g., 'uint32_t' or 'double'
See also
normL2().

◆ squaredNormL2() [2/2]

template<typename T , typename TNorm >
TNorm Ocean::CV::FrameNorm::squaredNormL2 ( const T *  frame,
const unsigned int  width,
const unsigned int  height,
const unsigned int  framePaddingElements 
)
static

Determines the squared L2 norm (summed squares) of a given frame allowing to specify a padding to enable the application of e.g., sub-frames.

Parameters
frameThe data of the frame for which the norm value will be determined, must be valid
widthThe width of the given frame in pixel, with range [1, infinity)
heightThe height of the given frame in pixel, with range [1, infinity)
framePaddingElementsThe number of padding elements at the end of each row, in elements, with range [0, infinity)
Returns
The resulting L2 norm
Template Parameters
TData type of each value, e.g., 'unsigned char' or 'float'
TNormThe data type of the resulting norm (and the intermediate sum), e.g., 'unsigned int' or 'double'
See also
normL2().

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