public class BoundingSphere
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
Vec3 |
center
The sphere's center point.
|
double |
radius
The sphere's radius.
|
Constructor and Description |
---|
BoundingSphere() |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o) |
int |
hashCode() |
boolean |
intersectsFrustum(Frustum frustum)
Indicates whether this bounding sphere intersects a specified frustum.
|
BoundingSphere |
set(Vec3 center,
double radius)
Sets this bounding sphere to the specified center point and radius.
|
java.lang.String |
toString() |
public final Vec3 center
public double radius
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public BoundingSphere set(Vec3 center, double radius)
center
- the new center pointradius
- the new radiusjava.lang.IllegalArgumentException
- If the center is null, or if the radius is negativepublic boolean intersectsFrustum(Frustum frustum)
frustum
- the frustum of interestjava.lang.IllegalArgumentException
- If the frustum is null