Image Component Library (ICL)
Public Member Functions | Public Attributes | List of all members
icl::core::Parable Struct Reference

Utility class for the parable-based chromaticity segmentation. More...

#include <Parable.h>

Public Member Functions

 Parable ()
 create an empty parable (a=b=c=0) More...
 
 Parable (float a, float b, float c)
 create a parable with given parameters a,b and c More...
 
 Parable (utils::Point32f p1, utils::Point32f p2, utils::Point32f p3)
 create a parable with given 3 points More...
 
float operator() (float x) const
 Evaluate this parable at a given location x. More...
 
void show () const
 shows this parable to std::out More...
 

Public Attributes

float a
 
float b
 
float c
 

Detailed Description

Utility class for the parable-based chromaticity segmentation.

A parabolic function is defined by 3 parameters a,b and c:

\[ f(x) = ax^2 + bx + c \]

Parables can be created by given parameters a,b and c or by 3 given points.

Constructor & Destructor Documentation

◆ Parable() [1/3]

icl::core::Parable::Parable ( )
inline

create an empty parable (a=b=c=0)

◆ Parable() [2/3]

icl::core::Parable::Parable ( float  a,
float  b,
float  c 
)
inline

create a parable with given parameters a,b and c

◆ Parable() [3/3]

icl::core::Parable::Parable ( utils::Point32f  p1,
utils::Point32f  p2,
utils::Point32f  p3 
)
inline

create a parable with given 3 points

To avoid numerical problems, the x coordinates of the given points are increased by a small value (0.00000001 - 0.00000003). This is harmless, as the Parable struct is used for the ChromaWidget, where given input point are defined by relative widget coordination which much less resolution

Member Function Documentation

◆ operator()()

float icl::core::Parable::operator() ( float  x) const
inline

Evaluate this parable at a given location x.

!< third parameter a

◆ show()

void icl::core::Parable::show ( ) const
inline

shows this parable to std::out

Member Data Documentation

◆ a

float icl::core::Parable::a

◆ b

float icl::core::Parable::b

!< first parameter a

◆ c

float icl::core::Parable::c

!< second parameter a


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