de.grogra.vecmath.geom
Class UnionBase

java.lang.Object
  extended by de.grogra.vecmath.geom.VolumeBase
      extended by de.grogra.vecmath.geom.CompoundVolume
          extended by de.grogra.vecmath.geom.UnionBase
All Implemented Interfaces:
Volume
Direct Known Subclasses:
CSGUnion, OctreeUnion, SimpleUnion

public abstract class UnionBase
extends CompoundVolume

This abstract class is the base class for unions of volumes.

Author:
Ole Kniemeyer

Field Summary
 
Fields inherited from class de.grogra.vecmath.geom.CompoundVolume
volumes
 
Constructor Summary
UnionBase()
           
 
Method Summary
 boolean contains(Tuple3d point, boolean open)
          Determines if the given point lies within this object.
 void getExtent(Tuple3d min, Tuple3d max, Variables temp)
          Computes the extent of this volume, i.e., an axis-aligned bounding box between min and max.
 
Methods inherited from class de.grogra.vecmath.geom.CompoundVolume
boxContainsBoundary, computeNormal, computeTangents, computeUV
 
Methods inherited from class de.grogra.vecmath.geom.VolumeBase
addConvexIntersections, getId, operator$and, operator$com, operator$or, operator$sub, setId
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface de.grogra.vecmath.geom.Volume
computeIntersections
 

Constructor Detail

UnionBase

public UnionBase()
Method Detail

contains

public boolean contains(Tuple3d point,
                        boolean open)
Description copied from interface: Volume
Determines if the given point lies within this object. If open is true, the interior of the volume is considered (the largest open set contained in the volume, i.e., excluding the boundary), otherwise the closure of the volume.

Parameters:
point - a point in global world coordinates
open - consider open or closed set
Returns:
true iff point is an element of the set

getExtent

public void getExtent(Tuple3d min,
                      Tuple3d max,
                      Variables temp)
Description copied from interface: Volume
Computes the extent of this volume, i.e., an axis-aligned bounding box between min and max.

Parameters:
min - minimum coordinates of bounding box are placed in here
max - maximum coordinates of bounding box are placed in here
temp - has to be provided by the invoker, may be used in implementations