Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ inquire_col(3G) — HP-UX 5.20

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

define_color_table(3g)

INQUIRE_COLOR_TABLE(3G)

NAME

inquire_color_table − return the current color table settings for the specified graphic device. 

SYNOPSIS

C SYNTAX

void inquire_color_table(fildes,start,count,response);
int fildes,start,count;
float response[][3];

FORTRAN77 SYNTAX

        subroutine inquire_color_table(fildes,start,count,response)
        integer*4 fildes,start,count
        real response(3,count)

PASCAL SYNTAX

procedure inquire_color_table(fildes,start,count:integer;
var response:array[lo..hi:integer]of rgb_color);

HP-UX COMPATIBILITY

Level: HP-UX/STANDARD

Origin: ANSI Computer Graphics Interface

DESCRIPTION

INPUT PARAMETERS

fildes
is an integer file descriptor returned by gopen when an I/O path to a graphic device is opened. 
start
is an integer index into the device color table at which to start the color table report. The first item in the color table is at index 0 (zero).
count
is the integer number of color table entries to report. This value can be any positive number less than the number of colors available on the device. To find the number of colors table entries available on a device, use the inquire_size procedure. 

OUTPUT PARAMETERS

response
returns the red, green, and blue values for each color table entry (values are in the range of zero (0.0) to one (1.0), where one is full intensity). In C terminology-
 
   response[0][0] = color_table[start][0];   /* red   */
   response[0][1] = color_table[start][1];   /* green */
   response[0][2] = color_table[start][2];   /* blue  */
   ...
   response[count-1][2] = color_table[start+count-1][2];

DISCUSSION

Each file descriptor opened as an output device has a color table associated with it.  When this procedure is called, the color table is returned.  If multiple file descriptors are open to the same device, the color table and the device’s color map may not always be identical. 
 
Some device drivers have a gescape that will read the current color map into the color table.  See the appropriate device driver description for more information. 

SEE ALSO

Starbase Device Drivers Library, define_color_table(3g). 

Hewlett-Packard Company  —  May 11, 2021

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026