[ Previous | Next | Contents | Glossary | Home | Search ]
The graPHIGS Programming Interface : Subroutine Reference

GPDCR - Set Depth Cue Representation

GPDCR (wsid, index, id, value)

Purpose

Use GPDCR to set one group of the specified entry in the workstation's depth cue table.

The values in the entry are applied during traversal when the current depth cue index is set to the specified entry. Each entry of the depth cue table is initially set to a depth cue mode of 1=SUPPRESSED

The depth cue table is 0 based, however, entry 0 of the table cannot be changed. It always contains a depth cue mode of 1=SUPPRESSED

Parameters

wsid -- specified by user, fullword integer

Workstation identifier.

index -- specified by user, fullword integer

Depth cue table index (>=1)

id -- specified by user, fullword integer

Group identifier (1=DEPTH_CUE_MODE, 2=DEPTH_CUE_REFERENCE_PLANE, 3=DEPTH_CUE_SCALE_FACTOR, 4=DEPTH_CUE_COLOR )

value -- specified by user, array of fullword quantities

Value(s) to be set in the group of the specified group id The values for each group identifier (id) have a unique data format, listed as follows:

Group Identifier 1 -Depth cue mode

A fullword integer (1=SUPPRESSED, 2=ALLOWED )

Group Identifier 2 -Depth cue reference planes (NPC)

Two short floating-point numbers specifying the far and near depth cue reference plane distance (0.0<=far<near<=1.0)

Group Identifier 3 -Depth cue scale factors

Two short floating-point numbers specifying two scale factors corresponding to the far and near reference planes (0.0<=factor<=1.0)

Group Identifier 4 -Depth cue color

Four fullwords of data with either of the following formats:
      indexed format                        direct format
      -------------                         -------------                          
    0 |          1| fullword integer      0 |          2| fullword integer
      |-----------|                         |-----------|
    4 |color index| fullword integer      4 |component 1| short floating-point number
      |-----------|                         |-----------|
    8 |    ignored| fullword integer      8 |component 2| short floating-point number
      |-----------|                         |-----------|
   12 |    ignored| fullword integer     12 |component 3| short floating-point number
      -------------                         ------------- 

Error Codes

25
SPECIFIED WORKSTATION DOES NOT EXIST
35
WORKSTATION HAS ONLY INPUT CAPABILITIES
92
COLOR INDEX < ZERO
93
COLOR INDEX VALUE(S) EXCEED WORKSTATION TABLE CAPACITY
96
COLOR PARAMETER OUT OF RANGE FOR CURRENT COLOR MODEL
97
COLOR FORMAT PARAMETER IS INVALID
261
DEPTH CUE INDEX < ZERO
262
DEPTH CUE INDEX EXCEEDS THE WORKSTATION TABLE CAPACITY
263
DEPTH CUE REFERENCE PLANE IS INVALID
264
DEPTH CUE SCALE FACTOR IS INVALID
272
GROUP IDENTIFIER IS INVALID
275
SPECIFIED ENTRY CANNOT BE CHANGED
281
DEPTH CUE MODE IS INVALID

Related Subroutines

GPCML
Set Color Model
GPDCI
Set Depth Cue Index
GPQDCF
Inquire Depth Cue Facilities
GPQDCR
Inquire Depth Cue Representation

RCP code

201329420 (X'0C000B0C')


[ Previous | Next | Contents | Glossary | Home | Search ]