Image Component Library (ICL)
|
Internal plugin class for the LUTOp3Channel. More...
#include <LUTOp3Channel.h>
Public Member Functions | |
Plugin () | |
Empty constructor. | |
Plugin (int ref1, int ref2, int ref3, int thresh) | |
Constructor. | |
virtual | ~Plugin () |
Destructor. | |
virtual T | transform (int v1, int v2, int v3) |
Transformation function. | |
Private Attributes | |
int | m_aiRef [3] |
internal reference colors | |
int | m_iThresh |
euclidean distance threshold |
Internal plugin class for the LUTOp3Channel.
The Plugin class can be reimplemented to create custom LUTOp3Channel functions. The basic implementation realized a default color distance map on source images.
icl::filter::LUTOp3Channel< T >::Plugin::Plugin | ( | ) | [inline] |
Empty constructor.
icl::filter::LUTOp3Channel< T >::Plugin::Plugin | ( | int | ref1, |
int | ref2, | ||
int | ref3, | ||
int | thresh | ||
) | [inline] |
Constructor.
ref1 | first channel reference color value |
ref2 | second channel reference color value |
ref3 | third channel reference color value |
thresh | euclidean distance threshold |
virtual icl::filter::LUTOp3Channel< T >::Plugin::~Plugin | ( | ) | [inline, virtual] |
Destructor.
virtual T icl::filter::LUTOp3Channel< T >::Plugin::transform | ( | int | v1, |
int | v2, | ||
int | v3 | ||
) | [inline, virtual] |
Transformation function.
This function must be reimplemented for custom LUT functions. The function is:
return Cast<double,T>::cast( ::sqrt( ::pow(r-m_aiRef[0],2) + ::pow(g-m_aiRef[1],2) + ::pow(b-m_aiRef[2],2) ) / ::sqrt(3.0) < m_iThresh ? 255 : 0;)
v1 | first channel pixel value of input image |
v2 | second channel pixel value of input image |
v3 | third channel pixel value of input image |
int icl::filter::LUTOp3Channel< T >::Plugin::m_aiRef[3] [private] |
internal reference colors
int icl::filter::LUTOp3Channel< T >::Plugin::m_iThresh [private] |
euclidean distance threshold