From this dialog box, you can set the colormap policy. This policy controls how the Render extension allocates colors when it draws pictures in dynamic, indexed visual types (specifically, GrayScale and PseudoColor).
A picture consists of a drawing surface (a core X window or pixmap), and a picture format that controls how pixel data is interpreted. If the surface is a window, the picture format always corresponds to the window's visual. If the surface is a pixmap, the picture format can correspond to any visual, or it can be just Alpha data used in conjunction with another picture.
Picture formats that correspond to indexed visuals have a colormap associated with them. If the visual is the same as the screen's default visual, the screen's default colormap is used. In this case, the Render extension allocates colors based on the colormap policy setting and the number of available (unallocated) pixels in the colormap. If the visual is not the same as the screen's default visual, a new colormap is allocated for use by all pictures of that visual type, and colors are allocated as if the setting were
.Colormap policy
|
The Render extension chooses an appropriate colormap policy according to the depth and type of the associated visual (see the individual colormap policy descriptions for more information): |
|
|
For this visual/depth type |
This colormap policy is used |
|
8 or higher/PseudoColor |
|
|
8 or higher/GrayScale |
|
|
All others |
|
|
Allocates only black and white colors (two entries). |
|
|
Extends to include 11 intermediate grayscale colors between black and white (13 entries). |
|
|
Extends to include colors found in a 4x4x4 color cube. This color cube includes combinations of red, green, and blue at four intensities between fully off and fully on.The intensities (over the range of 0x00 - 0xFF) are 00, 55, AA, and FF. The color cube overlaps the and colors at RGB=000000, 555555, AAAAAA, and FFFFFF. Sixty-four colors are allocated for the color cube plus nine other intermediate grayscale colors (73 entries). |
|
|
Allocates the largest possible color cube (up to 6x6x6) and then allocates as many additional grayscale colors within the cube as possible. For example, a depth 8 visual (with 256 colormap entries available) would be allocated as follows:
On the grayscale, then, the following RGB values are allocated (rounding to 8-bit quantities):
|