aboutsummaryrefslogtreecommitdiffstats
path: root/src/classes
diff options
context:
space:
mode:
Diffstat (limited to 'src/classes')
-rw-r--r--src/classes/share/javax/media/j3d/LightBin.java29
-rw-r--r--src/classes/share/javax/media/j3d/RenderBin.java8
2 files changed, 18 insertions, 19 deletions
diff --git a/src/classes/share/javax/media/j3d/LightBin.java b/src/classes/share/javax/media/j3d/LightBin.java
index ff79c57..7423254 100644
--- a/src/classes/share/javax/media/j3d/LightBin.java
+++ b/src/classes/share/javax/media/j3d/LightBin.java
@@ -81,11 +81,10 @@ class LightBin extends Object implements ObjectUpdate {
*/
EnvironmentSet environmentSetList = null;
- /**
- * List of envSet to be added for the next iteration
- */
- ArrayList insertEnvSet = new ArrayList();
-
+/**
+ * List of envSet to be added for the next iteration
+ */
+ArrayList<EnvironmentSet> insertEnvSet = new ArrayList<EnvironmentSet>();
/**
@@ -105,11 +104,11 @@ class LightBin extends Object implements ObjectUpdate {
*/
int lightDirtyMask = 0;
- /**
- * List of pointLts in this lightbin
- * Need to reload these lights when vworld scale changes
- */
- ArrayList pointLts = new ArrayList();
+/**
+ * List of pointLts in this lightbin Need to reload these lights when vworld
+ * scale changes
+ */
+ArrayList<PointLightRetained> pointLts = new ArrayList<PointLightRetained>();
int[] pointLtsSlotIndex;
// OrderedGroup info
@@ -212,7 +211,7 @@ class LightBin extends Object implements ObjectUpdate {
lights[j] = light;
lightsRef[j] = 1;
if (light instanceof PointLightRetained) {
- pointLts.add(light);
+ pointLts.add((PointLightRetained)light);
// save the destinated light slot for point
// so that point light can be updated without
@@ -255,13 +254,13 @@ class LightBin extends Object implements ObjectUpdate {
}
public void updateObject() {
- int i, j;
+ int i;
EnvironmentSet e ;
// Handle insertion
if (insertEnvSet.size() > 0) {
- e = (EnvironmentSet)insertEnvSet.get(0);
+ e = insertEnvSet.get(0);
if (environmentSetList == null) {
environmentSetList = e;
}
@@ -271,7 +270,7 @@ class LightBin extends Object implements ObjectUpdate {
environmentSetList = e;
}
for (i = 1; i < insertEnvSet.size(); i++) {
- e = (EnvironmentSet)insertEnvSet.get(i);
+ e = insertEnvSet.get(i);
e.next = environmentSetList;
environmentSetList.prev = e;
environmentSetList = e;
@@ -459,7 +458,7 @@ class LightBin extends Object implements ObjectUpdate {
renderBin.infVworldToVpc);
}
for (i = 0; i < pointLts.size(); i++) {
- LightRetained lt = (LightRetained) pointLts.get(i);
+ PointLightRetained lt = pointLts.get(i);
lt.update(cv.ctx, pointLtsSlotIndex[i], scale);
cv.lights[pointLtsSlotIndex[i]] = lt;
cv.frameCount[pointLtsSlotIndex[i]] = frameCount;
diff --git a/src/classes/share/javax/media/j3d/RenderBin.java b/src/classes/share/javax/media/j3d/RenderBin.java
index 2478674..962cb03 100644
--- a/src/classes/share/javax/media/j3d/RenderBin.java
+++ b/src/classes/share/javax/media/j3d/RenderBin.java
@@ -4152,7 +4152,7 @@ System.err.println("......tb.soleUser= " +
if (eNew == null) {
int size = currentBin.insertEnvSet.size();
for (i = 0; i < size; i++) {
- newBin = (EnvironmentSet)currentBin.insertEnvSet.get(i);
+ newBin = currentBin.insertEnvSet.get(i);
if (newBin.equals(ra, lights, fog, modelClip)) {
eNew = newBin;
break;
@@ -4175,7 +4175,7 @@ System.err.println("......tb.soleUser= " +
// Check the "to-be-added" list of environmentSets for a match
int size = currentBin.insertEnvSet.size();
for (i = 0; i < size; i++) {
- newBin = (EnvironmentSet)currentBin.insertEnvSet.get(i);
+ newBin = currentBin.insertEnvSet.get(i);
if (newBin.equals(ra, lights, fog, modelClip)) {
eNew = newBin;
break;
@@ -4968,7 +4968,7 @@ System.err.println("......tb.soleUser= " +
}
// Check the "to-be-added" list of environmentSets for a match
for (i = 0; i < currentBin.insertEnvSet.size(); i++) {
- newBin = (EnvironmentSet)currentBin.insertEnvSet.get(i);
+ newBin = currentBin.insertEnvSet.get(i);
if (newBin.equals(ra, ra.lights, ra.fog, ra.modelClip)) {
return(newBin);
}
@@ -4987,7 +4987,7 @@ System.err.println("......tb.soleUser= " +
// Check the "to-be-added" list of environmentSets for a match
for (i = 0; i < currentBin.insertEnvSet.size(); i++) {
- newBin = (EnvironmentSet)currentBin.insertEnvSet.get(i);
+ newBin = currentBin.insertEnvSet.get(i);
if (newBin.equals(ra, ra.lights, ra.fog, ra.modelClip)) {
return(newBin);
}