cmode(3G)
cmode - sets color map mode as the current mode.
As shipped in IRIX 6.5. First release of IRIX 6.5.
NAME cmode - sets color map mode as the current mode. C SPECIFICATION void cmode() PARAMETERS none DESCRIPTION cmode instructs the system to treat color as a 1-component entity in the currently active drawmode. The single color component is used as an index into a table of RGB color values called the color map. Because color map mode is the default value for all GL framebuffers, it can be called in any of the framebuffer drawmodes (NORMALDRAW, PUPDRAW, OVERDRAW, and UNDERDRAW). To return the normal framebuffer to color map mode, however, you must call cmode while in drawmode NORMALDRAW. You must call gconfig for cmode to take effect. While in color map mode, a framebuffer is configured to store a single color index at each pixel location. The framebuffer is displayed by continually translating color indices into RGB triples using the framebuffer's color map, a table of index-to-RGB mappings. The red, green, and blue components stored in the color map are used (after correction for monitor non-linearity) to directly control the color guns of the monitor. Colors and writemasks must be specified using color map-compatible commands such as color, colorf, and writemask. Many advanced rendering features, such as texture mapping, polygon antialiasing, and fog, are available only in RGB mode. Color map mode lighting, while functional, is substantially less robust than its RGB mode counterpart. Since cmode is the default, you do not have to call it unless the normal framebuffer was previously set to RGB mode. SEE ALSO color, drawmode, gconfig, getdisplaymode, getgdesc, multimap, onemap, RGBmode, writemask NOTE Color map mode is available in all framebuffers of all hardware configurations. getgdesc can be used to determine how many bitplanes in each of the normal, popup, overlay, and underlay framebuffers are available in both single and double buffered color map mode. This routine is available only in immediate mode.