Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ pset_colr_rep(3g) — PHIGS 5.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

pset_colr_rep(3g)  —  Subroutines

Name

pset_colr_rep − Associates the color index with the color triplet values in the color table. 

 
Operating States: PHOP, WSOP, ∗, ∗
PHIGS standard function

Syntax

 

void pset_colr_rep (
  Pint               wsid,    /∗ (I) Workstation identifier ∗/
  Pint               index,   /∗ (I) Color index ∗/
  const Pcolr_rep   ∗rep      /∗ (I) Color representation ∗/
)

Data Structures

typedef union {
    Prgb        rgb;       /∗ red, green, and blue color specification ∗/
    Pcieluv     cieluv;    /∗ CIELUV color specification ∗/
    Phls        hls;       /∗ hue, lightness, and saturation color
                              specification ∗/
    Phsv        hsv;       /∗ hue, saturation, and value color
                              specification ∗/
    Pdata       unsupp;    /∗ color in an unsupported color model ∗/
    int         impl_dep;  /∗ implementation-defined ∗/
} Pcolr_rep;
    typedef struct {
        Pfloat    red;     /∗ red intensity ∗/
        Pfloat    green;   /∗ green intensity ∗/
        Pfloat    blue;    /∗ blue intensity ∗/
    } Prgb;
    typedef struct {
        Pfloat    cieluv_x;      /∗ x coefficient ∗/
        Pfloat    cieluv_y;      /∗ y coefficient ∗/
        Pfloat    cieluv_y_lum;  /∗ y luminance ∗/
    } Pcieluv;
    typedef struct {
        Pfloat    hue;         /∗ hue ∗/
        Pfloat    lightness;   /∗ lightness ∗/
        Pfloat    satur;       /∗ saturation ∗/
    } Phls;
    typedef struct {
        Pfloat    hue;      /∗ hue ∗/
        Pfloat    satur;    /∗ saturation ∗/
        Pfloat    value;    /∗ value ∗/
    } Phsv;
    typedef struct {
        size_t    size;     /∗ size of data ∗/
        void     ∗data;     /∗ pointer to the data ∗/
    } Pdata;

Description

pset_colr_rep associates the color index with the color triplet values in the color table.  The color table is in the workstation state list of the workstation specified by the workstation identifier. 

  This function allows you to create or redefine an entry for the workstation color table.  To determine the predefined bundle table entries, which are provided for all workstations of type OUTPUT and OUTIN, and which are derived from the workstation description table, run the program phigs_predef. 

The color triplet argument specifies the coordinates of the current color model at the workstation.  See the pset_colr_model function for a description of the color models. 

Digital PHIGS provides at least two predefined entries (index 0 and 1) for the color bundle tables for every OUTPUT and OUTIN category workstation.  Entry values are derived from the workstation description table and maintained in the workstation state list. 

When Digital PHIGS displays primitives during structure traversal, the applicable current color index entry in the PHIGS traversal state list points to an entry in the color table on the workstation.  If Digital PHIGS does not find the specified color index, it uses the index value 1 for the foreground color, and the index value 0 for the background color. 

See Also

pinq_colr_facs
pinq_colr_model
pinq_colr_rep
pinq_pred_colr_rep
pset_colr_model
pset_edge_colr
pset_int_colr
pset_line_colr
pset_marker_colr
pset_rend_colr_model
pset_text_colr

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