G2dScan.mesa
Copyright Ó 1988, 1992 by Xerox Corporation. All rights reserved.
Bloomenthal, July 1, 1992 7:04 pm PDT
DIRECTORY Draw2d, G2dBasic, ImagerSample, Rope, SF;
G2dScan: CEDAR DEFINITIONS
~
BEGIN
Error: ERROR [code: ATOM, reason: ROPE];
Types
ROPE: TYPE ~ Rope.ROPE;
PixelProc: TYPE ~ Draw2d.PixelProc;
IntegerPair: TYPE ~ G2dBasic.IntegerPair;
Vertex: TYPE ~ RECORD [x, y, val: INTEGER];
Procedures
ScanTriangle:
PROC [p0, p1, p2: IntegerPair, pixelProc: PixelProc];
Perform an operation upon a triangle.
FlatShade:
PROC
[map:
ImagerSample.SampleMap,
pairs:
LIST
OF
IntegerPair,
value:
INTEGER]
RETURNS [affectedRegion: SF.Box];
Flat shade the polygon.
GouraudShade:
PROC [map: ImagerSample.SampleMap, vertices:
LIST
OF Vertex]
RETURNS [affectedRegion: SF.Box];
Linearly interpolate vertex values along polygon edges.
END.