MIRA
Public Member Functions | Static Public Member Functions | Public Attributes | Protected Member Functions | List of all members
HSV Class Referenceabstract

Color in HSV color space. More...

#include <image/Color.h>

Inheritance diagram for HSV:
Inheritance graph
[legend]

Public Member Functions

 HSV (float hue, float saturation, float value)
 Constructs color in HSV color space. More...
 
 HSV ()
 Default constructor initializes H,S, and V to 0.0. More...
 
template<typename Reflector >
void reflect (Reflector &r)
 
virtual Color::RGB toRGB () const
 Converts the HSV color to RGB. More...
 
virtual operator cv::Scalar () const
 converts color to cv::Scalar Converts color to cv::Scalar by first converting to RGB and then creating a 4 channel cv::Scalar(B,G,R,255); More...
 
Class const & getClass () const
 call the virtual internalGetClass(). More...
 

Static Public Member Functions

static PseudoClass const & CLASS ()
 

Public Attributes

float h
 
float s
 
float v
 

Protected Member Functions

virtual Class const & internalGetClass () const =0
 

Detailed Description

Color in HSV color space.

Constructor & Destructor Documentation

◆ HSV() [1/2]

HSV ( float  hue,
float  saturation,
float  value 
)
inline

Constructs color in HSV color space.

H,S and V: range from 0.0 to 1.0

◆ HSV() [2/2]

HSV ( )
inline

Default constructor initializes H,S, and V to 0.0.

Member Function Documentation

◆ reflect()

void reflect ( Reflector &  r)
inline

◆ toRGB()

virtual Color::RGB toRGB ( ) const
inlinevirtual

Converts the HSV color to RGB.

If the HSV components are within their valid ranges, the resulting RGB color components will be within their valid ranges, too.

Implements ColorBase.

◆ operator cv::Scalar()

operator cv::Scalar ( ) const
inlinevirtualinherited

converts color to cv::Scalar Converts color to cv::Scalar by first converting to RGB and then creating a 4 channel cv::Scalar(B,G,R,255);

cast operator to cv::Scalar converts color to OpenCV BGRA format by scaling range to 0..255 and setting alpha channel to 255

Reimplemented in RGBA.

◆ getClass()

Class const& getClass ( ) const
inlineinherited

call the virtual internalGetClass().

◆ CLASS()

static PseudoClass const& CLASS ( )
inlinestaticinherited

◆ internalGetClass()

virtual Class const& internalGetClass ( ) const
protectedpure virtualinherited

Member Data Documentation

◆ h

float h

◆ s

float s

◆ v

float v

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