aest 0.1.0
Collection of C++ utility libraries
Loading...
Searching...
No Matches
Space.cppm File Reference

Partition aest.colors:space: the tag that selects the color space an operation works in, and the linear space a color follows by default. More...

#include <type_traits>
import aest.colors:gamut;

Go to the source code of this file.

Classes

struct  aest::colors::In< Space >
 Tag naming the color space an operation works in. More...
struct  aest::colors::LinearSpaceOf< Color >
 The linear space that operations in linear light, such as mix() and over(), use for a color type when no space is given. More...
struct  aest::colors::LinearSpaceOf< BasicRGB< Gamut, Transfer > >
 An RGB space follows the linear space of its gamut. More...
struct  aest::colors::LinearSpaceOf< BasicHSL< RGB > >
 HSL follows the linear space of its RGB space. More...
struct  aest::colors::LinearSpaceOf< BasicHSV< RGB > >
 HSV follows the linear space of its RGB space. More...
struct  aest::colors::LinearSpaceOf< XYZ >
 XYZ is linear already. More...

Typedefs

template<typename Space, ColorType Color>
using aest::colors::WorkingSpace
 The working space of an operation that follows its input: Space when given, the LinearSpaceOf Color when it is void.

Variables

template<ColorType Space>
constexpr In< Space > aest::colors::in {}
 Selects the color space an operation works in, e.g. lighten(color, 0.2f, in<HSL>).

Detailed Description

Partition aest.colors:space: the tag that selects the color space an operation works in, and the linear space a color follows by default.

Author
Davide Pierotti

Definition in file Space.cppm.

Typedef Documentation

◆ WorkingSpace

template<typename Space, ColorType Color>
using aest::colors::WorkingSpace
Initial value:
std::conditional_t<std::is_void_v<Space>, typename LinearSpaceOf<Color>::type, Space>
LinSRGB type
The linear space.
Definition Space.cppm:55

The working space of an operation that follows its input: Space when given, the LinearSpaceOf Color when it is void.

Template Parameters
SpaceThe space named by the caller, or void
ColorThe color type the operation follows

Definition at line 107 of file Space.cppm.

Variable Documentation

◆ in

template<ColorType Space>
In<Space> aest::colors::in {}
inlineconstexprexport

Selects the color space an operation works in, e.g. lighten(color, 0.2f, in<HSL>).

Template Parameters
SpaceThe color space.

Definition at line 38 of file Space.cppm.