Re: HSB to RGB? [message #5916] |
Wed, 13 March 1996 00:00 |
hahn
Messages: 108 Registered: November 1993
|
Senior Member |
|
|
lgao@aol.com (LGAO) wrote:
> Hi,
> Does anyone know the equation to convert the color in
> HSB(hue,satriration,brightness) model to the color in RGB(red, green blue)
> model?
If you translate HSB into HLS (Hue, Lightness, Saturation) or HSB
(Hue, Saturation, Brightness) you can use the IDL procedure
COLOR_CONVERT to convert to and from RGB.
Is the conversion 1 to 1?
That depends upon the implementation and the color coordinate system
used: RGB is a cube, HSB is a cone and HLS is a double cone (if I
don't intermix HSB and HLS).
> Thanks.
> Li
Norbert Hahn
|
|
|
Re: HSB to RGB? [message #5930 is a reply to message #5916] |
Tue, 12 March 1996 00:00  |
sterner
Messages: 106 Registered: February 1991
|
Senior Member |
|
|
lgao@aol.com (LGAO) writes:
> Does anyone know the equation to convert the color in
> HSB(hue,satriration,brightness) model to the color in RGB(red, green blue)
> model? Is the conversion 1 to 1?
Check the help for the IDL function color_convert. One of the
conversions it can handle is HSV to RGB, not far from what you need.
The online help also gives a useful reference.
Ray Sterner sterner@tesla.jhuapl.edu
The Johns Hopkins University North latitude 39.16 degrees.
Applied Physics Laboratory West longitude 76.90 degrees.
Laurel, MD 20723-6099
WWW Home page: http://fermi.jhuapl.edu/s1r/people/res/res.html
|
|
|