javax.media.j3d
Class LightBin

java.lang.Object
  extended by javax.media.j3d.LightBin
All Implemented Interfaces:
ObjectUpdate

 class LightBin
extends java.lang.Object
implements ObjectUpdate

The LightBin manages a collection of EnvironmentSet objects. The number of objects managed depends upon the number of Lights in each EnvironmentSet and the number of lights supported by the underlying rendering layer.


Field Summary
(package private)  int canvasDirty
          cache of the canvasDirty
(package private)  EnvironmentSet environmentSetList
          The list of EnvironmentSets in this LightBin.
(package private)  BackgroundRetained geometryBackground
           
(package private)  java.util.ArrayList insertEnvSet
          List of envSet to be added for the next iteration
(package private)  int lightDirtyMask
          lightDirty Mask used during rendering
(package private)  int lightDirtyMaskCache
          lightDirty Mask cache , used to mark the lightdirty bits for next frame
(package private)  LightRetained[] lights
          The Array of Light references in this LightBin.
(package private)  int[] lightsRef
          An Array of reference counts for shared lights in among EnvirionmentSets
(package private)  int maxLights
          The maximum number of lights in a LightBin
(package private)  LightBin next
          The references to the next and previous LightBins in the list.
(package private)  int numEmptySlots
          The number of empty light slots in this LightBin
(package private)  boolean onUpdateList
           
(package private)  OrderedCollection orderedCollection
           
(package private)  java.util.ArrayList pointLts
          List of pointLts in this lightbin Need to reload these lights when vworld scale changes
(package private)  int[] pointLtsSlotIndex
           
(package private)  LightBin prev
           
(package private)  RenderBin renderBin
          The RenderBin for this object
 
Constructor Summary
LightBin(int maxLights, RenderBin rb, boolean isOpaque)
           
 
Method Summary
(package private)  void addEnvironmentSet(EnvironmentSet e, RenderBin rb)
          Adds the new EnvironmentSet to this LightBin.
(package private)  void removeEnvironmentSet(EnvironmentSet e)
          Removes the given EnvironmentSet from this LightBin.
(package private)  void render(Canvas3D cv)
          Renders this LightBin
(package private)  void reset(boolean inOpaque)
           
(package private)  void setOrderedInfo(OrderedCollection oc)
           
(package private)  void updateAttributes(Canvas3D cv)
           
 void updateObject()
          The actual update function.
(package private)  boolean willEnvironmentSetFit(EnvironmentSet e)
          Checks to see if an EnvironmentSet will fit into this LightBin.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

maxLights

int maxLights
The maximum number of lights in a LightBin


lights

LightRetained[] lights
The Array of Light references in this LightBin. This array is always maxLights in length.


lightsRef

int[] lightsRef
An Array of reference counts for shared lights in among EnvirionmentSets


numEmptySlots

int numEmptySlots
The number of empty light slots in this LightBin


renderBin

RenderBin renderBin
The RenderBin for this object


next

LightBin next
The references to the next and previous LightBins in the list.


prev

LightBin prev

environmentSetList

EnvironmentSet environmentSetList
The list of EnvironmentSets in this LightBin.


insertEnvSet

java.util.ArrayList insertEnvSet
List of envSet to be added for the next iteration


canvasDirty

int canvasDirty
cache of the canvasDirty


lightDirtyMaskCache

int lightDirtyMaskCache
lightDirty Mask cache , used to mark the lightdirty bits for next frame


lightDirtyMask

int lightDirtyMask
lightDirty Mask used during rendering


pointLts

java.util.ArrayList pointLts
List of pointLts in this lightbin Need to reload these lights when vworld scale changes


pointLtsSlotIndex

int[] pointLtsSlotIndex

orderedCollection

OrderedCollection orderedCollection

onUpdateList

boolean onUpdateList

geometryBackground

BackgroundRetained geometryBackground
Constructor Detail

LightBin

LightBin(int maxLights,
         RenderBin rb,
         boolean isOpaque)
Method Detail

reset

void reset(boolean inOpaque)

setOrderedInfo

void setOrderedInfo(OrderedCollection oc)

willEnvironmentSetFit

boolean willEnvironmentSetFit(EnvironmentSet e)
Checks to see if an EnvironmentSet will fit into this LightBin. It takes into account shared lights.


addEnvironmentSet

void addEnvironmentSet(EnvironmentSet e,
                       RenderBin rb)
Adds the new EnvironmentSet to this LightBin.


updateObject

public void updateObject()
Description copied from interface: ObjectUpdate
The actual update function.

Specified by:
updateObject in interface ObjectUpdate

removeEnvironmentSet

void removeEnvironmentSet(EnvironmentSet e)
Removes the given EnvironmentSet from this LightBin.


render

void render(Canvas3D cv)
Renders this LightBin


updateAttributes

void updateAttributes(Canvas3D cv)


Copyright 1996-2008 Sun Microsystems, Inc. All Rights Reserved. Use is subject to license terms.