1Colconv(3NCARG)                  NCAR GRAPHICS                 Colconv(3NCARG)
2
3
4

NAME

6       Colconv - Allows a user to convert among the color models RGB, HSV,
7       HLS, and YIQ.
8

SYNOPSIS

10       HLSRGB - Converts a color specification given as Hue, Lightness, and
11       Saturation (HLS) values to Red, Green, and Blue (RGB) intensity values
12       in the RGB color space.
13
14       HSVRGB - Converts a color specification given in the Hue, Saturation,
15       and Value (HSV) color space to color values in the Red, Green, Blue
16       (RGB) color space.
17
18       RGBHLS - Converts a color specification given in the Red, Green, Blue
19       (RGB) color space to color values in the Hue, Lightness, Saturation
20       (HLS) color space.
21
22       RGBHSV - Converts a color specification given in the Red, Green, Blue
23       (RGB) color space to color values in the Hue, Saturation, and Value
24       (HSV) color space.
25
26       RGBYIQ - Converts a color specification given in the RGB Red, Green,
27       Blue, (RGB) color space to a color specification in the YIQ color
28       space.
29
30       YIQRGB - Converts a color specification given in the YIQ color space to
31       the equivalent color specification in the Red, Green, Blue (RGB) color
32       space.
33

C-BINDING SYNOPSIS

35       #include <ncarg/ncargC.h>
36
37       c_hlsrgb
38       c_hsvrgb
39       c_rgbhls
40       c_rgbhsv
41       c_rgbyiq
42       c_yiqrgb
43

ACCESS

45       To use Colconv or c_colconv routines, load the NCAR Graphics libraries
46       ncarg, ncarg_gks, and ncarg_c, preferably in that order.
47
48

MESSAGES

50       When error conditions are detected, the support routine SETER is called
51       in such a way that it writes a message to the standard error file (as
52       defined by I1MACH(4)) and then terminates execution. The possible error
53       messages are as follows:
54
55       HLSRGB - L out of range
56              Lightness is less than 0. or greater than 100.
57
58       HLSRGB - S out of range
59              Saturation is less than 0. or greater than 100.
60
61       HSVRGB - S out of range
62              Saturation is less than 0. or greater than 1.
63
64       HSVRGB - V out of range
65              Value of input color is less than 0. or greater than 1.
66
67       RGBHLS - R out of range
68              Value of red intensity component is less than 0. or greater than
69              1.
70
71       RGBHLS - G out of range
72              Value of green intensity component is less than 0. or greater
73              than 1.
74
75       RGBHLS - B out of range
76              Value of blue intensity component is less than 0. or greater
77              than 1.
78
79       RGBHSV - R out of range
80              Value of red intensity component is less than 0. or greater than
81              1.
82
83       RGBHSV - G out of range
84              Value of green intensity component is less than 0. or greater
85              than 1.
86
87       RGBHSV - B out of range
88              Value of blue intensity component is less than 0. or greater
89              than 1.
90

SEE ALSO

92       Online: hlsrgb, hsvrgb, rgbhls, rgbhsv, rgbyiq, yiqrgb, ncarg_cbind.
93
94       Hardcopy: NCAR Graphics Fundamentals, UNIX Version
95
97       Copyright (C) 1987-2007
98       University Corporation for Atmospheric Research
99
100       This documentation is free software; you can redistribute it and/or
101       modify it under the terms of the GNU General Public License as
102       published by the Free Software Foundation; either version 2 of the
103       License, or (at your option) any later version.
104
105       This software is distributed in the hope that it will be useful, but
106       WITHOUT ANY WARRANTY; without even the implied warranty of
107       MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
108       General Public License for more details.
109
110       You should have received a copy of the GNU General Public License along
111       with this software; if not, write to the Free Software Foundation,
112       Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
113
114
115
116UNIX                              March 1993                   Colconv(3NCARG)
Impressum