1 #ifndef RAYMARCHING_COLORS_H
2 #define RAYMARCHING_COLORS_H
6 using pixel =
unsigned char;
21 [[nodiscard]]
struct color mix(const struct
color &other)
const {
23 static_cast<pixel
>((
R + other.R) / 2),
24 static_cast<pixel
>((
G + other.G) / 2),
25 static_cast<pixel
>((
B + other.B) / 2)
Namespace containing all tools implemented within RayMarching package.
Definition: algebra.h:9
constexpr color_t GRAY
Definition: colors.h:31
struct RayMarching::color color_t
3 byte color representation structure
constexpr color_t WHITE
Definition: colors.h:30
constexpr color_t GREEN
Definition: colors.h:34
constexpr color_t BLACK
Definition: colors.h:32
constexpr color_t RED
Definition: colors.h:33
constexpr color_t BLUE
Definition: colors.h:35
3 byte color representation structure
Definition: colors.h:11
struct color mix(const struct color &other) const
Definition: colors.h:21
pixel R
Definition: colors.h:12
pixel B
Definition: colors.h:14
pixel G
Definition: colors.h:13