normaliseColours

Takes a colour and, if it deems it is too dark to see on a black terminal background, makes it brighter.

version(Colours)
private pure @safe nothrow @nogc
void
normaliseColours
(
ref uint r
,
ref uint g
,
ref uint b
)

Parameters

r uint

Reference to a red value.

g uint

Reference to a green value.

b uint

Reference to a blue value.

Examples

int r = 255;
int g = 128;
int b = 100;
normaliseColours(r, g, b);
assert(r != 255);
assert(g != 128);
assert(b != 100);