DIRECTORY CedarProcess, Controls, CtBasic, Draw2d, G3dBasic, G3dControl, G3dMatrix, G3dOctree, G3dRayTrace, Rope, ImplicitDefs, ViewerClasses; ImplicitRayTrace: CEDAR DEFINITIONS ~ BEGIN Process: TYPE ~ CedarProcess.Process; ButtonList: TYPE ~ Controls.ButtonList; ControlList: TYPE ~ Controls.ControlList; OuterData: TYPE ~ Controls.OuterData; RGB: TYPE ~ CtBasic.RGB; DrawProc: TYPE ~ Draw2d.DrawProc; Ray: TYPE ~ G3dBasic.Ray; Triple: TYPE ~ G3dBasic.Triple; Camera: TYPE ~ G3dControl.Camera; Matrix: TYPE ~ G3dMatrix.Matrix; Intersection: TYPE ~ G3dOctree.Intersection; Octree: TYPE ~ G3dOctree.Octree; RayData: TYPE ~ G3dRayTrace.RayData; RayProc: TYPE ~ G3dRayTrace.RayProc; NormalProc: TYPE ~ ImplicitDefs.NormalProc; ValueProc: TYPE ~ ImplicitDefs.ValueProc; ROPE: TYPE ~ Rope.ROPE; Viewer: TYPE ~ ViewerClasses.Viewer; xAxis: Triple ~ G3dBasic.xAxis; yAxis: Triple ~ G3dBasic.yAxis; zAxis: Triple ~ G3dBasic.zAxis; RayHit: TYPE ~ RECORD [ point: Triple ฌ [], value: REAL ฌ 0.0, t: REAL ฌ 0.0, type: {entering, leaving, empty} ฌ empty ]; RayHitList: TYPE ~ LIST OF RayHit; SurfacePoint: TYPE ~ RECORD [point, normal: Triple, value: REAL]; Error: ERROR [reason: ROPE]; GetRayHit: PROC [ i0, i1: Intersection, valueProc: ValueProc, threshold: REAL ฌ 1.0, clientData: REF ANY ฌ NIL, epsilon: REAL ฌ 0.0] RETURNS [RayHit]; GetRayHits: PROC [ i0, i1: Intersection, valueProc: ValueProc, threshold: REAL ฌ 1.0, clientData: REF ANY ฌ NIL, epsilon: REAL ฌ 0.0] RETURNS [hits: RayHitList]; RayIntersection: PROC [ ray: Ray, octree: Octree, valueProc: ValueProc, threshold: REAL ฌ 1.0, clientData: REF ANY ฌ NIL] RETURNS [RayHit]; RayIntersections: PROC [ ray: Ray, octree: Octree, valueProc: ValueProc, threshold: REAL ฌ 1.0, clientData: REF ANY ฌ NIL] RETURNS [RayHitList]; RayAtSurface: PROC [ ray: Ray, octree: Octree, valueProc: ValueProc, threshold: REAL ฌ 1.0, normalProc: NormalProc ฌ NIL, clientData: REF ANY ฌ NIL] RETURNS [SurfacePoint]; RayThroughSurface: PROC [ ray: Ray, octree: Octree, valueProc: ValueProc, threshold: REAL ฌ 1.0, clientData: REF ANY ฌ NIL] RETURNS [thickness: REAL, firstHit: RayHit]; InShadow: PROC [ octree: Octree, surfacePoint, lightDirection: Triple, valueProc: ValueProc, threshold: REAL ฌ 1.0, clientData: REF ANY ฌ NIL] RETURNS [BOOL]; AnyHit: PROC [ i0, i1: Intersection, valueProc: ValueProc, threshold: REAL ฌ 1.0, clientData: REF ANY ฌ NIL] RETURNS [BOOL]; END. ธ ImplicitRayTrace.mesa Copyright ำ 1985, 1990 by Xerox Corporation. All rights reserved. Bloomenthal, August 11, 1992 4:07 pm PDT Imported Types Local Types Ray Tracing Implicit Functions Converge along the line segment between i0.point and i1.point and return the ray hit. (i0.value > 0.0) is presumed # (i1.value > 0.0). Epsilon is the minimum distance allowed in the convergence. Recursion depth limited to 15. Return a list of hits between i0 and i1. Return the first ray hit of the surface. Can raise Error["No intersection"]; Return a list of all ray hits with the surface. Return location and normal at first ray hit of surface. Can raise Error["No intersection"]; Return accumulated thickness of ray through the surface. ray is presumed normalized (so that 2t is in distance units). True if ray from the surfacePoint towards the lightDirection is interupted by the surface. True if any surface exists between the two intersections. สH•NewlineDelimiter ™™JšœB™BJ™(J˜Jšฯk œ…˜ŽJ˜—Jšะblœœ ˜#J˜Jšœ˜headšฯl™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šœœœ œ˜C—šŸ™šฯnœœ œ˜J˜—š  œœ˜J˜J˜Jšœ œ˜Jšœ œœœ˜Jšœ œ˜Jšœ ˜J™UJ™0J™[J˜—š  œœ˜J˜J˜Jšœ œ˜Jšœ œœœ˜Jšœ œ˜Jšœ˜J™(J˜—š œœ˜J˜ J˜J˜Jšœ œ˜Jšœ œœœ˜Jšœ ˜J™MJ˜—š œœ˜J˜ J˜J˜Jšœ œ˜Jšœ œœœ˜Jšœ˜J™/J˜—š  œœ˜J˜ J˜J˜Jšœ œ˜Jšœœ˜Jšœ œœœ˜Jšœ˜J™\J˜—š œœ˜J˜ J˜J˜Jšœ œ˜Jšœ œœœ˜Jšœ œ˜,J™8Jšœ$ะcmฯcœ™=J™—š œœ˜J˜J˜%J˜Jšœ œ˜Jšœ œœœ˜Jšœœ˜J™ZJ˜—š œœ˜Jšœ˜Jšœ˜Jšœ œ˜Jšœ œœœ˜Jšœœ˜J™9——J˜šœ˜J™——…— าา