SET INTERIOR SHADING METHOD(3P+) — Kubota Pacfic Computer Inc. (29 February 1991)
NAME
SET INTERIOR SHADING METHOD − create a structure element that sets the current interior shading method
SYNOPSIS
C Syntax
void
pset_int_shad_meth ( method )
Pintmethod;shading method
Required PHIGS Operating States
(PHOP, ∗, STOP, ∗)
DESCRIPTION
Purpose
SET INTERIOR SHADING METHOD places a structure element with the value shading method into the open structure. When the current interior shading method Aspect Source Flag (ASF) is set to INDIVIDUAL, the current value of this attribute applies to the following output primitives:
• FILL AREA
• FILL AREA SET
• FILL AREA SET 3 WITH DATA
• GENERALIZED DRAWING PRIMITIVE (Fill Area Primitives)
• GENERALIZED DRAWING PRIMITIVE 3 (Fill Area Primitives)
• QUADRILATERAL MESH 3 WITH DATA
• TRIANGLE STRIP 3 WITH DATA
• SET OF FILL AREA SET 3 WITH DATA
• NON-UNIFORM B-SPLINE SURFACE
C Input Parameters
method
The interior shading method.
1PSD_NONENo Shading
2PSD_COLOURColour Interpolation Shading
3PSD_DOT_PRODUCTDot Product Interpolation Shading
4PSD_NORMALNormal Interpolation Shading
Execution
Depending on the edit mode, a SET INTERIOR SHADING METHOD element is inserted into the open structure after the element pointer, or replaces the element pointed to by the element pointer. In either case, the element pointer is updated to point to the newly created SET INTERIOR SHADING METHOD element.
When the structure is traversed, the current interior shading method entry in the traversal state list is set to the specified value. This value is used with subsequent filled area output primitives when the current interior shading method ASF entry in the traversal state list is INDIVIDUAL. During traversal, if the specified shading method is not available on a workstation, method one (None) will be used on that workstation.
When the current interior shading method ASF is set to BUNDLED, the interior shading method is taken from the workstation extended representation indicated by the current interior index. In this case, the interior shading method set with SET INTERIOR SHADING METHOD has no effect.
The interior shading methods supported by a workstation type can be determined with the function INQUIRE INTERIOR FACILITIES PLUS.
When the shading method is NONE, each fill area or fill area set will be rendered in a single colour (this is sometimes called flat shading). If the shading method is NONE and the primitive data implies different colours for each vertex of the primitive, such as when vertex colour is specified or when lighting is active, the colour of the first vertex will be used for all the vertices of the primitive.
When the shading method is COLOUR and the workstation is in index colour mode, then the colours will be interpolated as colour indices instead of direct colours.
ERRORS
005Ignoring function, function requires state (PHOP, ∗, STOP, ∗)
SEE ALSO
FILL AREA (3P)
FILL AREA SET (3P)
FILL AREA SET 3 WITH DATA (3P+)
QUADRILATERAL MESH 3 WITH DATA (3P+)
TRIANGLE STRIP 3 WITH DATA (3P+)
SET OF FILL AREA SET 3 WITH DATA (3P+)
SET BACK INTERIOR SHADING METHOD (3P+)
SET INDIVIDUAL ASF (3P)
SET INTERIOR REPRESENTATION PLUS (3P+)
INQUIRE INTERIOR FACILITIES PLUS (3P+)
NON-UNIFORM B-SPLINE SURFACE (3P+)
September 02, 1992