simogl.collision
Class BoundingBox

java.lang.Object
  extended by simogl.collision.BoundingBox

public class BoundingBox
extends java.lang.Object

This class can be used as a bounding box for a mesh

Author:
Frank Bruns

Constructor Summary
BoundingBox(AbstractMesh mesh)
          Creates a bounding box for the meshes current triangle coordinates
 
Method Summary
 void draw(javax.media.opengl.GL gl)
          This method can be used to draw the bounding box
 float getHeight()
          Returns the height of the bounding box.
 float getLength()
          Returns the length of the bounding box.
 float getWidth()
          Returns the width of the bounding box.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BoundingBox

public BoundingBox(AbstractMesh mesh)
Creates a bounding box for the meshes current triangle coordinates

Parameters:
mesh - mesh to create a bounding box for
Method Detail

getWidth

public float getWidth()
Returns the width of the bounding box.

Returns:
width of the bounding box

getHeight

public float getHeight()
Returns the height of the bounding box.

Returns:
height of the bounding box

getLength

public float getLength()
Returns the length of the bounding box.

Returns:
length of the bounding box

draw

public void draw(javax.media.opengl.GL gl)
This method can be used to draw the bounding box

Parameters:
gl -