org.wilmascope.light
Class WilmaLight

java.lang.Object
  extended by org.wilmascope.light.WilmaLight

public class WilmaLight
extends java.lang.Object

The class serves as a memory for the light and it's parent branch group. The light's parent branchgroup cannot be returned using java3d's method once the light is turned 'live'. It's necessary to create a reference for the light's parent branchgroup so that the light can be deleted after it is turned 'live'.


Constructor Summary
WilmaLight()
           
 
Method Summary
 void deleteObj()
          Detaches the 3D shape
 Arrow getArrow()
           
 javax.media.j3d.BranchGroup getBranchGroup()
           
 SpotLightCone getCone()
           
 javax.media.j3d.Light getLight()
           
 javax.media.j3d.BranchGroup getObjGroup()
           
 PointLightSphere getSphere()
           
 void setBranchGroup(javax.media.j3d.BranchGroup b)
          Registers the light's parent BranchGroup
 void setLight(javax.media.j3d.Light l)
          Registers the light and create a 3D Shape to represent the light
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WilmaLight

public WilmaLight()
Method Detail

getLight

public javax.media.j3d.Light getLight()

getBranchGroup

public javax.media.j3d.BranchGroup getBranchGroup()
Returns:
The parent BranchGroup

setLight

public void setLight(javax.media.j3d.Light l)
Registers the light and create a 3D Shape to represent the light


setBranchGroup

public void setBranchGroup(javax.media.j3d.BranchGroup b)
Registers the light's parent BranchGroup


getSphere

public PointLightSphere getSphere()
Returns:
The Sphere that represents the point light

getCone

public SpotLightCone getCone()
Returns:
The Cone that represents the spot light

deleteObj

public void deleteObj()
Detaches the 3D shape


getObjGroup

public javax.media.j3d.BranchGroup getObjGroup()
Returns:
The branchgroup the 3D shape attached

getArrow

public Arrow getArrow()
Returns:
the arrow that represent the directional light