diff --git a/engine/src/core/com/jme3/animation/Bone.java b/engine/src/core/com/jme3/animation/Bone.java index 3c61805a8..014b41309 100644 --- a/engine/src/core/com/jme3/animation/Bone.java +++ b/engine/src/core/com/jme3/animation/Bone.java @@ -72,7 +72,7 @@ public final class Bone implements Savable { */ private Vector3f initialPos; private Quaternion initialRot; - private Vector3f initialScale = new Vector3f(1.0f, 1.0f, 1.0f); + private Vector3f initialScale; /** * The inverse world bind transform. * BONE SPACE -> MODEL SPACE @@ -92,6 +92,9 @@ public final class Bone implements Savable { private Vector3f worldPos = new Vector3f(); private Quaternion worldRot = new Quaternion(); private Vector3f worldScale = new Vector3f(); + + // TODO: Get rid of this temp variable + private Matrix3f rotMat = new Matrix3f(); /** * Creates a new bone with the given name. @@ -103,7 +106,7 @@ public final class Bone implements Savable { initialPos = new Vector3f(); initialRot = new Quaternion(); - initialScale = new Vector3f(); + initialScale = new Vector3f(1,1,1); worldBindInversePos = new Vector3f(); worldBindInverseRot = new Quaternion(); @@ -321,8 +324,6 @@ public final class Bone implements Savable { } } - //Temp 3x3 rotation matrix for transform computation - Matrix3f rotMat=new Matrix3f(); /** * Stores the skinning transform in the specified Matrix4f. * The skinning transform applies the animation of the bone to a vertex. @@ -395,7 +396,7 @@ public final class Bone implements Savable { * Used internally after model cloning. * @param attachNode */ - public void setAttachmentsNode(Node attachNode) { + void setAttachmentsNode(Node attachNode) { this.attachNode = attachNode; } diff --git a/engine/src/core/com/jme3/animation/BoneTrack.java b/engine/src/core/com/jme3/animation/BoneTrack.java index b2b42b1c2..f76b18e8d 100644 --- a/engine/src/core/com/jme3/animation/BoneTrack.java +++ b/engine/src/core/com/jme3/animation/BoneTrack.java @@ -56,6 +56,7 @@ public final class BoneTrack implements Savable { private CompactQuaternionArray rotations; private CompactVector3Array scales; private float[] times; + // temp vectors for interpolation private transient final Vector3f tempV = new Vector3f(); private transient final Quaternion tempQ = new Quaternion(); diff --git a/engine/src/core/com/jme3/light/Light.java b/engine/src/core/com/jme3/light/Light.java index 4c08f3111..ef4c5ed66 100644 --- a/engine/src/core/com/jme3/light/Light.java +++ b/engine/src/core/com/jme3/light/Light.java @@ -76,8 +76,6 @@ public abstract class Light implements Savable, Cloneable { * If light is disabled, it will not take effect. */ protected boolean enabled = true; - /** The light's name. */ - protected String name; /** * @return The color of the light. @@ -102,22 +100,6 @@ public abstract class Light implements Savable, Cloneable { return enabled; } - /** - * This method sets the light's name. - * @param name the light's name - */ - public void setName(String name) { - this.name = name; - } - - /** - * This method returns the light's name. - * @return the light's name - */ - public String getName() { - return name; - } - @Override public Light clone(){ try { diff --git a/engine/src/core/com/jme3/util/IntMap.java b/engine/src/core/com/jme3/util/IntMap.java index cce44d31d..252b000ad 100644 --- a/engine/src/core/com/jme3/util/IntMap.java +++ b/engine/src/core/com/jme3/util/IntMap.java @@ -40,7 +40,7 @@ import java.util.Iterator; * * @author Nate */ -public final class IntMap implements Iterable, Cloneable { +public final class IntMap implements Iterable>, Cloneable { private Entry[] table; private final float loadFactor; @@ -193,11 +193,11 @@ public final class IntMap implements Iterable, Cloneable { size = 0; } - public Iterator iterator() { - return (Iterator) new IntMapIterator(); + public Iterator> iterator() { + return (Iterator>) new IntMapIterator(); } - final class IntMapIterator implements Iterator { + final class IntMapIterator implements Iterator> { /** * Current entry.