Standard Library procedure that lets you interactivelycreate a new color table based on the HLS or HSV color system.
The values for red are stored in the first row, the values for green are stored in the second row, and those for blue in the third row; in other words:
green = colors_out(*, 1)
blue = colors_out(*, 2)
Hsv If set to 1, indicates the HSV (hue, saturation, value) color system should be used. This is the default.
Figure 2-7 The C_EDIT window lets you use the mouse to create a new color table based on either the HLS or HSV color system.
Figure 2-8 The C_EDIT window lets you use the mouse to create a new color table based on either the HLS or HSV color system.
C_EDIT is similar to the COLOR_EDIT procedure, except that the color wheel has been replaced by two additional slider bars. This allows better control of HSV colors near zero percent saturation.
The C_EDIT window contains the following items:
Pixel Value
slider bar, click with the left mouse button at the position where you want that particular color to be. The range on this bar begins at 0 and ends with the maximum value for your color table.
Windows Users: If you have a two-button mouse, use Alt in combination with the left mouse button to erase the tie point.
Pixel Value
slider bar.
You may select as many tie points as desired, with the understanding that each tie point is associated with the color system parameters in effect when the selection is made.
Note that when the HSV color system is being used, a Value of 1.0 is maximum brightness of the selected hue. In the HLS color system, a Lightness of 0.5 is the maximum brightness of a chromatic hue; 0.0 is black, and 1.0 is bright white. Also, in the HLS system, which models a double-ended cone, the Saturation has no effect at the extreme ends of the cone (i.e., Lightness equals 0 or 1).
TVSCL, DIST(200) C_EDIT, rgb_arry
SAVE, filename = 'my_colortable', rgb_array LOADCT, 5 RESTORE, 'my_colortable' rgb_array = REFORM(rgb_array, $ N_ELEMENTS(rgb_array)/3,3) TVLCT, rgb_array(*,0),rgb_array(*,1), $ rgb_array(*,2)
TVSCL, DIST(200) C_EDIT
TVLCT, r, g, b, /Get SAVE, filename = 'my_colortable_ 2', r, g, b LOADCT, 8 RESTORE, 'my_colortable_2' TVLCT, r, g, b
For more background information about color systems, see the PV-WAVE User's Guide.