From 4ebb5396511eb220f3bce31a05bdd94d6d607f69 Mon Sep 17 00:00:00 2001 From: Harvey Harrison Date: Sat, 7 Jan 2012 18:43:52 -0800 Subject: j3dcore: annotate list in AttributeBin, remove unused vars and unneeded cast Signed-off-by: Harvey Harrison --- src/classes/share/javax/media/j3d/AttributeBin.java | 15 +++++++-------- src/classes/share/javax/media/j3d/RenderBin.java | 2 +- 2 files changed, 8 insertions(+), 9 deletions(-) (limited to 'src/classes') diff --git a/src/classes/share/javax/media/j3d/AttributeBin.java b/src/classes/share/javax/media/j3d/AttributeBin.java index 183d463..913e6c0 100644 --- a/src/classes/share/javax/media/j3d/AttributeBin.java +++ b/src/classes/share/javax/media/j3d/AttributeBin.java @@ -67,10 +67,10 @@ class AttributeBin extends Object implements ObjectUpdate { */ ShaderBin shaderBinList = null; - /** - * List of shaderBins to be added next frame - */ - ArrayList addShaderBins = new ArrayList(); +/** + * List of shaderBins to be added next frame + */ +ArrayList addShaderBins = new ArrayList(); /** * If the RenderingAttribute component of the appearance will be changed @@ -157,7 +157,7 @@ class AttributeBin extends Object implements ObjectUpdate { if (soleUser || (ra.geometryAtom.source.appearance != null && ((ra.geometryAtom.source.appearance.changedFrequent & AppearanceRetained.RENDERING) != 0))) { - if (app == (Object)ra.geometryAtom.source.appearance) { + if (app == ra.geometryAtom.source.appearance) { // if this AttributeBin is currently on a zombie state, // we'll need to put it on the update list to reevaluate @@ -214,12 +214,11 @@ class AttributeBin extends Object implements ObjectUpdate { public void updateObject() { ShaderBin sb; - TextureBin t; int i, size; size = addShaderBins.size(); if (size > 0) { - sb = (ShaderBin)addShaderBins.get(0); + sb = addShaderBins.get(0); if (shaderBinList == null) { shaderBinList = sb; } @@ -230,7 +229,7 @@ class AttributeBin extends Object implements ObjectUpdate { } for (i = 1; i < size ; i++) { - sb = (ShaderBin)addShaderBins.get(i); + sb = addShaderBins.get(i); sb.next = shaderBinList; shaderBinList.prev = sb; shaderBinList = sb; diff --git a/src/classes/share/javax/media/j3d/RenderBin.java b/src/classes/share/javax/media/j3d/RenderBin.java index a8e3438..5690a12 100644 --- a/src/classes/share/javax/media/j3d/RenderBin.java +++ b/src/classes/share/javax/media/j3d/RenderBin.java @@ -4705,7 +4705,7 @@ System.err.println("......tb.soleUser= " + // Check the "to-be-added" list of shaderBins for a match size = attributeBin.addShaderBins.size(); for (i = 0; i < size; i++) { - currentBin = (ShaderBin)attributeBin.addShaderBins.get(i); + currentBin = attributeBin.addShaderBins.get(i); if (currentBin.equals(sApp)) { return currentBin; } -- cgit v1.2.3