Namespaces

TOC

color

Main name space. Usually contain color model classes, but also might contain other useful things.

color::akin

Main Page
akin Main page.
Description
Mach most similar model/formats. e.g akin type for ::color::rgb< double > is ::color::hsl< double > and vice versa.
Example
typedef ::color::rgb< double > rgb_t;
typedef ::color::akin::hsl< rgb_t::category_type >::akin_type hsl_category_t;
typedef ::color::model< hsl_category_t > hsl_t;

color::category

Contain all color categories. Category is pair of model and format.
For more details see category.

color::check

Main Page
check main Page
Description
Test/check color components for some inconsistency.
Example
::color::rgb< double > r;
r[0]=2; r[1]=0.5; r[2]=-1;
std::cout << ::color::check::overburn( r );

color::compare

Main Page
compare main Page
Description
Contain functions to compare color by some criteria.
Example
::color::rgb< double > a, b;
std::cout << ::color::compare::darker( a,b );
std::cout << ::color::compare::brighter( a,b );

color::constant

Main Page
constant Main Page
Description
Contain various constants and constant like types for easy color manipulation.
Example
::color::rgb< double > a( ::color::constant::aqua_t{} );
a = ::color::constant::orange_t{};

color::fix

Main Page
fix main Page
Description
Fix color so instance can pass overburn and integrity checks.
Example
::color::rgb< double > a;
r[0]=2; r[1]=0.5; r[2]=-1;
::color::fix::overburn( r );
std::cout << r[0] << ", " << r[1] << ", " r[2] << std::endl;

color::get

Main Page
get Main Page
Description
Get some property of color by the name. Depend of used color model this operation might be instant like getting red channel from RGB or require some calculation like get red from HSV model.

Sub namespaces:
::color::get::constant::rgb
Constants to extract various features by different algorithnam
::color::get::constant::cmy
Constants to extract various features by different algorithnam
::color::get::constant::cmyk
Constants to extract various features by different algorithnam
Example
::color::rgb<float> c;
auto hue = color::get::hue< ::color::get::constant::rgb::hue::polar_acos_entity >( c );

color::make

Main Page
make Main Page
Description
Make color by some algorithm.
Example
::color::gray< double > g;
::color::make::gray( g, 25 );

color::operation

All operations are situated here. Some operations are not designed to be used in this form e.g. color::operation:addition
For more details see
operations.

color::operation::functor

Functor classes.
For more details see
functors.

color::place

Get index of some color component.
For more details see
place.

color::set

Main Page
set Main page
Description
Set some property of color. Similarly to get this operation might be instant or need calculation.
Example
::color::rgb< double > c{ ::color::constant::pink{} };
::color::set::red( c, 0.5 ); // set red to be 0.5

color::trait

Contain classes to retrieve some property of color specified color category.
For more details see
trait.

color::type

Contain useful types.
For more details see
type.

color::_internal

Miscellaneous internal things. Do not use entities from here. It is highly probably that this might change from version to version or from one commit to another.