|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecttracer.Traceable
tracer.Sphere
A 3D roundish traceable thingy with a center and a radius
Constructor Summary | |
Sphere()
|
|
Sphere(Vec3 o,
float r)
|
Method Summary | |
boolean |
hit(Ray r)
Returns a boolean indicating whether the line segment (r.origin + t*r.direction) with 0 <= t <= 1 intersects the object. |
IntersectionInfo |
intersect(Ray r)
Returns an IntersectionInfo object indicating whether the ray r intersects this object or not. |
void |
parse(Parser p)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Sphere(Vec3 o, float r)
public Sphere()
Method Detail |
public void parse(Parser p) throws java.io.IOException
java.io.IOException
public IntersectionInfo intersect(Ray r)
Traceable
intersect
in class Traceable
IntersectionInfo
public boolean hit(Ray r)
Traceable
hit
in class Traceable
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |