XJRT Rendering Toolkit 1.0b06

org.autochthonous.graphics.rt.objects
Class Metaball

java.lang.Object
  extended byorg.autochthonous.graphics.rt.objects.Metaball
All Implemented Interfaces:
java.lang.Cloneable, Partitionable, Traceable

public class Metaball
extends java.lang.Object
implements Partitionable

a metaball.

Example:

    <Metaball strength="0.8" radius="1" center="0, 0, 0"/>
 
Note that the strength may be negative.

Document Type Definition:

     <!ENTITY %Float   "CDATA">
     <!ENTITY %Point3f "CDATA">

     <!ELEMENT Metaball EMPTY>
     <!ATTLIST Metaball
         center   %Point3f; "0, 0, 0"
         radius   %Float;   "1"
         strength %Float;   "1">
 


Constructor Summary
Metaball(Point3f center, double radius, double strength)
          basic constructor.
 
Method Summary
 BBox bBox()
           
 java.lang.Object clone()
           
static Metaball getInstance(RMLReader in)
           
 HitList intersections(Ray r)
           
 boolean isIntersected(Ray r)
           
 boolean isShadowing(Ray r)
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Metaball

public Metaball(Point3f center,
                double radius,
                double strength)
basic constructor.

Parameters:
center - the center.
radius - the radius.
strength - the strength (can be negative or positive).
Method Detail

getInstance

public static Metaball getInstance(RMLReader in)
                            throws java.io.IOException
Throws:
java.io.IOException

bBox

public BBox bBox()
Specified by:
bBox in interface Partitionable

isIntersected

public boolean isIntersected(Ray r)
Specified by:
isIntersected in interface Traceable

intersections

public HitList intersections(Ray r)
Specified by:
intersections in interface Traceable

isShadowing

public boolean isShadowing(Ray r)
Specified by:
isShadowing in interface Traceable

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Specified by:
clone in interface Traceable
Throws:
java.lang.CloneNotSupportedException

XJRT Rendering Toolkit 1.0b06