Skip to content

raylib.ColorFromHSV

JoeStrout edited this page Apr 29, 2026 · 2 revisions

Get a Color from HSV values Implementation reference: https://en.wikipedia.org/wiki/HSL_and_HSV#Alternative_HSV_conversion NOTE: Color->HSV->Color conversion will not yield exactly the same color due to rounding errors Hue is provided in degrees: [0..360] Saturation/Value are provided normalized: [0.0f..1.0f]

Parameters

Parameter Default Value Note
hue
saturation
value

Return value

Condition Return Value
(always) map

Notes

Example

// Get a red color from HSV values (hue=0, full saturation and value)
c = raylib.ColorFromHSV(0, 1, 1)
print c  // same as raylib.RED

Clone this wiki locally