gl3n.ext.hsv
-
Declaration
pure nothrow @safe vec3
rgb2hsv
(vec3inp
);Converts a 3 dimensional color-vector from the RGB to the HSV colorspace.
Discussion
The function assumes that each component is in the range [0, 1].
-
Declaration
pure nothrow @safe vec4
rgb2hsv
(vec4inp
);Converts a 4 dimensional color-vector from the RGB to the HSV colorspace.
Discussion
The alpha value is not touched. This function also assumes that each component is in the range [0, 1].
-
Declaration
nothrow @safe vec3
hsv2rgb
(vec3inp
);Converts a 3 dimensional color-vector from the HSV to the RGB colorspace.
Discussion
RGB colors will be in the range [0, 1].
This function is not marked es pure, since it depends on std.math.floor, which
is also not pure. -
Declaration
nothrow @safe vec4
hsv2rgb
(vec4inp
);Converts a 4 dimensional color-vector from the HSV to the RGB colorspace.
Discussion
The alpha value is not touched and the resulting RGB colors will be in the range [0, 1].