com.jme.light
Class LightManagement

java.lang.Object
  extended by com.jme.light.LightManagement
All Implemented Interfaces:
Savable, java.io.Serializable

Deprecated.

@Deprecated
public class LightManagement
extends java.lang.Object
implements java.io.Serializable, Savable

The LightStateCreator class is used to sort lights in a scene. The utility allows the user to place multiple lights in a single container and the best eight lights (those lights that most directly affect a Spatial) will be applied.
This class should not be used anymore, use Node.sortLights() instead.

Author:
Badmi, Mark Powell (cleaning, savable)
See Also:
jmetest.util.TestManyLights, Serialized Form

Field Summary
static boolean LIGHTS_ENABLED
          Deprecated.  
 
Constructor Summary
LightManagement()
          Deprecated. Creates a new instance of LightStateCreator
 
Method Summary
 void addLight(Light l)
          Deprecated. Adds a light for the controller to sort into a spatial.
 boolean contains(Light l)
          Deprecated.  
 LightState createLightState(Spatial sp)
          Deprecated. Creates a new LightState for a spatial placing the "best" eight lights currently maintained by the LightStateCreator.
 Light get(int i)
          Deprecated. Gets the Ith light from the creator.
 java.lang.Class getClassTag()
          Deprecated.  
protected  float getColorValue(Light l)
          Deprecated.  
 java.util.ArrayList<Light> getLights()
          Deprecated.  
protected  float getValueFor(Light l, BoundingVolume val)
          Deprecated.  
(package private)  float getValueFor(PointLight l, BoundingVolume val)
          Deprecated.  
(package private)  float getValueFor(SpotLight l, BoundingVolume val)
          Deprecated.  
protected  float max(ColorRGBA a)
          Deprecated.  
 int numberOfLights()
          Deprecated. Returns the number of lights in the creator.
 void read(JMEImporter im)
          Deprecated.  
 boolean removeLight(Light l)
          Deprecated.  
 void reset()
          Deprecated.  
 void resortLightsFor(LightState ls, Spatial sp)
          Deprecated. Gives the LightState the best possible lights for the Spatial.
 void setLights(java.util.ArrayList<Light> lights)
          Deprecated.  
protected  void sort(Spatial sp)
          Deprecated. Sort the lightList in descending order according to the getValueFor(Light, BoundingVolume) method.
 void write(JMEExporter ex)
          Deprecated.  
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LIGHTS_ENABLED

public static boolean LIGHTS_ENABLED
Deprecated. 
Constructor Detail

LightManagement

public LightManagement()
Deprecated. 
Creates a new instance of LightStateCreator

Method Detail

addLight

public void addLight(Light l)
Deprecated. 
Adds a light for the controller to sort into a spatial. All the lights must be added before the lights could be sorted.


contains

public boolean contains(Light l)
Deprecated. 

removeLight

public boolean removeLight(Light l)
Deprecated. 

get

public Light get(int i)
Deprecated. 
Gets the Ith light from the creator. The placement of the light is subject to change.


numberOfLights

public int numberOfLights()
Deprecated. 
Returns the number of lights in the creator.


createLightState

public LightState createLightState(Spatial sp)
Deprecated. 
Creates a new LightState for a spatial placing the "best" eight lights currently maintained by the LightStateCreator.


resortLightsFor

public void resortLightsFor(LightState ls,
                            Spatial sp)
Deprecated. 
Gives the LightState the best possible lights for the Spatial. The spatial must be using bounding volumes for this process to work properly.


sort

protected void sort(Spatial sp)
Deprecated. 
Sort the lightList in descending order according to the getValueFor(Light, BoundingVolume) method.

Parameters:
sp - spatial to pass to getValueFor

max

protected float max(ColorRGBA a)
Deprecated. 

getColorValue

protected float getColorValue(Light l)
Deprecated. 

getValueFor

protected float getValueFor(Light l,
                            BoundingVolume val)
Deprecated. 

getValueFor

float getValueFor(PointLight l,
                  BoundingVolume val)
Deprecated. 

getValueFor

float getValueFor(SpotLight l,
                  BoundingVolume val)
Deprecated. 

read

public void read(JMEImporter im)
          throws java.io.IOException
Deprecated. 
Specified by:
read in interface Savable
Throws:
java.io.IOException

write

public void write(JMEExporter ex)
           throws java.io.IOException
Deprecated. 
Specified by:
write in interface Savable
Throws:
java.io.IOException

getClassTag

public java.lang.Class getClassTag()
Deprecated. 
Specified by:
getClassTag in interface Savable

getLights

public java.util.ArrayList<Light> getLights()
Deprecated. 

setLights

public void setLights(java.util.ArrayList<Light> lights)
Deprecated. 

reset

public void reset()
Deprecated.