DIRECTORY G3dBasic, G3dQuaternion, G3dScene, G3dShape, G3dSweep, G3dRender, Random, Rope; G3dBuild: CEDAR DEFINITIONS ~ BEGIN AxisAngle: TYPE ~ G3dQuaternion.AxisAngle; BlendType: TYPE ~ G3dSweep.BlendType; Context3d: TYPE ~ G3dRender.Context3d; ParseState: TYPE ~ G3dScene.ParseState; RandomStream: TYPE ~ Random.RandomStream; ROPE: TYPE ~ Rope.ROPE; SceneProc: TYPE ~ G3dScene.SceneProc; Shape: TYPE ~ G3dShape.Shape; Triple: TYPE ~ G3dBasic.Triple; TripleSequence: TYPE ~ G3dBasic.TripleSequence; SweepPaths: TYPE ~ REF SweepPathsRep; SweepPathsRep: TYPE ~ RECORD [ shapeFile: ROPE ¬ NIL, shapeBlend: BlendType ¬ smooth, scaleFile: ROPE ¬ NIL, scaleBlend: BlendType ¬ smooth, rotateFile: ROPE ¬ NIL, rotateBlend: BlendType ¬ smooth, translateFile: ROPE ¬ NIL, translateBlend: BlendType ¬ smooth, pathFile: ROPE ¬ NIL, pathBlend: BlendType ¬ smooth ]; Field: TYPE ~ REF FieldRep; FieldRep: TYPE ~ RECORD [ on: BOOL ¬ FALSE, center: Triple ¬ [0.0, 0.0, 0.0], amplitude: REAL ¬ 1.0, radius: REAL ¬ 1.0, power: REAL ¬ 1.0, offset: REAL ¬ 0.0 ]; State: TYPE ~ REF StateRep; StateRep: TYPE ~ RECORD [ field: Field ¬ NIL, sweepPaths: SweepPaths ¬ NIL, randomStream: RandomStream ]; pi: REAL = 3.141593; piOver2: REAL = 1.570796; piTimes2: REAL = 6.283186; degToRad: REAL = 1.745329e-2; radToDeg: REAL = 57.29577; GetBuildState: PUBLIC PROC [ps: ParseState] RETURNS [State]; TranslateShapeAlongZ : PUBLIC PROC [ shape: Shape, distance: REAL ¬ 1.0, anchor: BOOL ¬ FALSE ] RETURNS [Shape]; TranslateShape: PUBLIC PROC [ shape: Shape, lo, hi: Triple, anchor: BOOL ¬ FALSE ] RETURNS [Shape]; RevolveShape: PUBLIC PROC [ shape: Shape, steps: INT ¬ 10, loAngle: REAL ¬ 0.0, -- angle extreme in degrees hiAngle: REAL ¬ 360.0, -- angle extreme in degrees axis: Triple ¬ [0.0, 0.0, 1.0], anchor: BOOL ¬ FALSE, objClosed: BOOL ¬ FALSE ] RETURNS [Shape]; MakeSphere: PUBLIC SceneProc; MakeCylinder: PUBLIC SceneProc; MakeCone: PUBLIC SceneProc; MakeTorus: PUBLIC SceneProc; MakeNGon: PUBLIC SceneProc; MakeAnnulus: PUBLIC SceneProc; ShapeFromTripleSequence: PUBLIC PROC [ts: TripleSequence] RETURNS [Shape]; ShapeFromTripleList: PUBLIC PROC [tl: LIST OF Triple] RETURNS [Shape]; ResampleTriples: PUBLIC PROC [ts: TripleSequence, steps: INT, close: BOOL, curved: BOOL ¬ TRUE] RETURNS [TripleSequence]; LoadShape: PUBLIC PROC [ps: ParseState, state: State, shape: Shape]; UpdateShape: PUBLIC PROC [ps: ParseState, state: State, shape: Shape]; AutoName: PUBLIC PROC [context3d: Context3d, type: ROPE] RETURNS [ROPE]; AutoUTexture: PUBLIC PROC [shape: Shape]; ClearSweepPaths: PUBLIC SceneProc; ChangeSweepPaths: PUBLIC SceneProc; MakeSweep: PUBLIC SceneProc; PolyStellate: PUBLIC SceneProc; PolyFrame: PUBLIC SceneProc; PolyDilate: PUBLIC SceneProc; PolyRotate: PUBLIC SceneProc; PolyExplodeP: PUBLIC SceneProc; PolyInscribe: PUBLIC SceneProc; PolyCorners: PUBLIC SceneProc; PolyCutCorners: PUBLIC SceneProc; PolySplotch: PUBLIC SceneProc; PolyFan: PUBLIC SceneProc; PolyStar: PUBLIC SceneProc; StellateShape: PUBLIC PROC [shape: Shape, factor: REAL ¬ 1.0, bases: BOOL ¬ TRUE]; FrameShape: PUBLIC PROC [shape: Shape, factor: REAL ¬ 1.0]; DilateShape: PUBLIC PROC [shape: Shape, factor: REAL ¬ 1.0]; RotateShape: PUBLIC PROC [shape: Shape, theta: REAL ¬ piOver2]; ExplodePShape: PUBLIC PROC [shape: Shape, factor: REAL ¬ 1.0, f: Field]; InscribeShape: PUBLIC PROC [shape: Shape, alpha: REAL ¬ 0.5]; CutCornersShape: PUBLIC PROC [shape: Shape, alpha: REAL ¬ 0.5, corners: BOOL ¬ TRUE]; SplotchShape: PUBLIC PROC [shape: Shape, sides: INT ¬ 10, size: REAL ¬ 1.0]; FanShape: PUBLIC PROC [shape: Shape, alpha: REAL ¬ 0.5]; StarShape: PUBLIC PROC [shape: Shape, factor: REAL ¬ 0.5]; ExplodeV: PUBLIC SceneProc; ExplodeVShape: PUBLIC PROC [shape: Shape, factor: REAL ¬ 1.0, f: Field]; END.  G3dBuild.mesa Copyright Σ 1984, 1992 by Xerox Corporation. All rights reserved. Glassner, September 21, 1989 5:38:13 pm PDT Bloomenthal, July 15, 1992 11:32 pm PDT Basic Types Local Types the all-pervading field Constants ImplA Procs Get Build State Instantiates a state for the build system if one is not already present Primitive Sweep Convenience Procedures Timesaver for simple translations Timesaver for translations Timesaver for rotations Polygonal Surface Procedures Shape Saving and Book-keeping Procedures Construct a shape from a sequence of triples Construct a shape from a list of triples Interpolate a TripleSequence into a new TripleSequence with the specified number of points. Build's Private Procedures Save a shape that has been constructed Inherit material and other information in the ParseState Construct a name of the given type by appending the current shape number Apply texture coordinates to the object as a function of Z Sweep Surface Procedures ImplB Procs Calls for Polygon-by-polygon Procedures Impls for Polygon-by-polygon Procedures These procedures simply provide a client interface for the above shape hacks. Calls for Vertex-by-vertex Procedures Impls for Vertex-by-vertex Procedures These procedures simply provide a client interface for the above vertex hacks. Κ•NewlineDelimiter –"cedarcode" style™šœ ™ Jšœ Οeœ6™BJšœ+™+J™'J˜—šΟk œP˜YJ˜—JšΡblnœžœž ˜Jšœž˜headšΟl ™ Jšœžœ˜-Jšœžœ˜(Jšœžœ˜)Jšœžœ˜*Jšœžœ˜+Jšžœžœžœ˜Jšœžœ˜(Jšœ žœ˜!Jšœ žœ˜#Jšœžœ˜1—š  ™ Jšœžœžœ˜(šœžœžœ˜ Jšœžœžœ˜J˜$Jšœžœžœ˜J˜$Jšœžœžœ˜J˜%Jšœžœžœ˜J˜'Jšœžœžœ˜J˜"J˜J˜—Jšœ žœžœ ˜ šœžœžœ˜šœ™Jšœ žœžœ˜J˜&Jšœžœ˜Jšœ žœ˜Jšœ žœ˜Jšœ žœ˜—Jšœ˜J˜—Jšœ žœžœ ˜ šœžœžœ˜Jšœžœ˜Jšœžœ˜"J˜J˜——š  ™ Jšœžœ ˜Jšœ žœ ˜Jšœ žœ ˜Jšœ žœ˜Jšœ žœ ˜—š  ™ Jš ™š Πbn œΟsž’ž’œžœ ˜