DDraceNetwork Docs
color.h File Reference
#include <base/math.h>
#include <base/vmath.h>
#include <optional>
Include dependency graph for color.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  color4_base< DerivedT >
 
class  ColorHSLA
 
class  ColorHSVA
 
class  ColorRGBA
 

Functions

float RgbToHue (float r, float g, float b)
 
template<typename T , typename F >
color_cast (const F &)=delete
 
template<>
ColorHSLA color_cast (const ColorRGBA &rgb)
 
template<>
ColorRGBA color_cast (const ColorHSLA &hsl)
 
template<>
ColorHSLA color_cast (const ColorHSVA &hsv)
 
template<>
ColorHSVA color_cast (const ColorHSLA &hsl)
 
template<>
ColorRGBA color_cast (const ColorHSVA &hsv)
 
template<>
ColorHSVA color_cast (const ColorRGBA &rgb)
 
template<typename T >
color_scale (const T &col, float s)
 
template<typename T >
color_invert (const T &col)
 
template<typename T >
std::optional< T > color_parse (const char *pStr)
 

Function Documentation

◆ color_cast() [1/7]

template<>
ColorRGBA color_cast ( const ColorHSLA hsl)
inline

◆ color_cast() [2/7]

template<>
ColorHSVA color_cast ( const ColorHSLA hsl)
inline

◆ color_cast() [3/7]

template<>
ColorHSLA color_cast ( const ColorHSVA hsv)
inline

◆ color_cast() [4/7]

template<>
ColorRGBA color_cast ( const ColorHSVA hsv)
inline

◆ color_cast() [5/7]

template<>
ColorHSLA color_cast ( const ColorRGBA rgb)
inline

◆ color_cast() [6/7]

template<>
ColorHSVA color_cast ( const ColorRGBA rgb)
inline

◆ color_cast() [7/7]

template<typename T , typename F >
T color_cast ( const F &  )
delete

◆ color_invert()

template<typename T >
T color_invert ( const T &  col)

◆ color_parse()

template<typename T >
std::optional< T > color_parse ( const char *  pStr)

◆ color_scale()

template<typename T >
T color_scale ( const T &  col,
float  s 
)

◆ RgbToHue()

float RgbToHue ( float  r,
float  g,
float  b 
)
inline