diff options
author | Harvey Harrison <[email protected]> | 2012-09-23 21:48:42 -0700 |
---|---|---|
committer | Harvey Harrison <[email protected]> | 2012-09-23 21:48:42 -0700 |
commit | 12988b2f17bcbebc32ed8640fa48c73332adb91a (patch) | |
tree | 16ffd9dbd70fb3dc6f0c784e76ac50cb246dc072 /src | |
parent | 4bf917a7c1fed0768fd320c2a507122c63d5992a (diff) |
j3dcore: remove some trivially unused variables and casting
Signed-off-by: Harvey Harrison <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/classes/share/javax/media/j3d/BoundingPolytope.java | 13 | ||||
-rw-r--r-- | src/classes/share/javax/media/j3d/CachedFrustum.java | 2 |
2 files changed, 7 insertions, 8 deletions
diff --git a/src/classes/share/javax/media/j3d/BoundingPolytope.java b/src/classes/share/javax/media/j3d/BoundingPolytope.java index 7774104..ab74ae6 100644 --- a/src/classes/share/javax/media/j3d/BoundingPolytope.java +++ b/src/classes/share/javax/media/j3d/BoundingPolytope.java @@ -384,7 +384,6 @@ public class BoundingPolytope extends Bounds { */ public void set(Bounds boundsObject) { int i,k; - double dis; // no polytope exists yet so initialize one using the boundsObject if( boundsObject == null ) { @@ -806,15 +805,15 @@ public class BoundingPolytope extends Bounds { } if( boundsObject.boundId == BOUNDING_SPHERE ) { - BoundingSphere sphere = new BoundingSphere((BoundingSphere)boundsObject); + BoundingSphere sphere = new BoundingSphere(boundsObject); sphere.transform(matrix); this.set(sphere); } else if( boundsObject.boundId == BOUNDING_BOX){ - BoundingBox box = new BoundingBox( (BoundingBox)boundsObject); + BoundingBox box = new BoundingBox(boundsObject); box.transform(matrix); this.set(box); } else if(boundsObject.boundId == BOUNDING_POLYTOPE) { - BoundingPolytope polytope = new BoundingPolytope( (BoundingPolytope)boundsObject); + BoundingPolytope polytope = new BoundingPolytope(boundsObject); polytope.transform(matrix); this.set(polytope); } else { @@ -930,7 +929,7 @@ public class BoundingPolytope extends Bounds { boolean intersect(Point3d origin, Vector3d direction, Point4d position ) { double t,v0,vd,x,y,z,invMag; double dx, dy, dz; - int i,j; + int i; if( boundsIsEmpty ) { return false; @@ -1021,7 +1020,7 @@ public class BoundingPolytope extends Bounds { */ boolean intersect( Point3d start, Point3d end, Point4d position ) { double t,v0,vd,x,y,z; - int i,j; + int i; //System.err.println("line segment intersect : planes.length " + planes.length); @@ -1092,7 +1091,7 @@ public class BoundingPolytope extends Bounds { // compute intersection point of ray and each plane then test if point is in polytope double t,v0,vd,x,y,z; - int i,j; + int i; if( boundsIsEmpty ) { return false; diff --git a/src/classes/share/javax/media/j3d/CachedFrustum.java b/src/classes/share/javax/media/j3d/CachedFrustum.java index 8f7f37a..be04e98 100644 --- a/src/classes/share/javax/media/j3d/CachedFrustum.java +++ b/src/classes/share/javax/media/j3d/CachedFrustum.java @@ -198,7 +198,7 @@ class CachedFrustum { } private void computeVertex( int a, int b, int c, Point3d vert) { - double det,x,y,z; + double det; det = clipPlanes[a].x*clipPlanes[b].y*clipPlanes[c].z + clipPlanes[a].y*clipPlanes[b].z*clipPlanes[c].x + clipPlanes[a].z*clipPlanes[b].x*clipPlanes[c].y - clipPlanes[a].z*clipPlanes[b].y*clipPlanes[c].x - |