File: SVBoundSphere.mesa
Last edited by: Eric Bier on August 9, 1984 1:05:39 pm PDT
Contents: Computes a sphere which is guaranteed to bound a given polyhedron. Implements operations on such spheres.
DIRECTORY
Graphics,
SV3d,
SVModelTypes;
SVBoundSphere: DEFINITIONS =
BEGIN
BoundHedron: TYPE = SVModelTypes.BoundHedron;
BoundSphere: TYPE = SVModelTypes.BoundSphere;
Camera: TYPE = SVModelTypes.Camera;
CoordSystem: TYPE = SVModelTypes.CoordSystem;
Point3d: TYPE = SV3d.Point3d;
Vector: TYPE = SV3d.Vector;
CopyBoundSphere: PROC [boundSphere: BoundSphere] RETURNS [newBS: BoundSphere];
BoundSphereFromBoundHedron: PROC [bh: BoundHedron, worldCS: CoordSystem, localCS: CoordSystem] RETURNS [boundSphere: BoundSphere];
BoundSphereFromValues: PROC [centerWORLD: Point3d, radius: REAL] RETURNS [boundSphere: BoundSphere];
UnionCombineBoundSpheres: PROC [bs1, bs2: BoundSphere] RETURNS [newBS: BoundSphere];
IntersectionCombineBoundSpheres: PROC [bs1, bs2: BoundSphere] RETURNS [newBS: BoundSphere];
DifferenceCombineBoundSpheres: PROC [bs1, bs2: BoundSphere] RETURNS [newBS: BoundSphere];
DrawBoundSphere: PROC [dc: Graphics.Context, boundSphere: BoundSphere, camera: Camera];
END.