NAME

cxHSVtoRGB - convert color values from hue/saturation/value to red/green/blue
#include <cx/DataAccess.h>

void cxHSVtoRGB( float hsv[3], float rgb[3] )
subroutine cxHSVtoRGB( hsv, rgb )
real hsv(3)
real rgb(3)
cxHSVtoRGB converts the Hue/Saturation/Value color values stored in hsv into Red/Green/Blue values stored in rgb.

A hue (hsv[0]) of 0 maps to red, 1/3 maps to green, 2/3 to blue, 1 maps to red. Hue values of less than 0 and more than 1 are mapped modulo 1. Saturation and value (hsv[1] and hsv[2]) are clamped to the range [0..1]. The output values will be in the range [0..1].

cxRGBtoHSV(3E), cxParamColorFloatGet(3E), cxParamColorFloatSet(3E), cxParamColorPackedGet(3E), cxParamColorPackedSet(3E)
Last modified: Mon Nov 6 16:33:21 GMT 2000
[ Documentation Home ]
© The Numerical Algorithms Group Ltd, Oxford UK. 1999