aboutsummaryrefslogtreecommitdiffstats
path: root/ardor3d-extras
diff options
context:
space:
mode:
authorJulien Gouesse <[email protected]>2014-08-08 18:41:35 +0200
committerJulien Gouesse <[email protected]>2014-08-08 18:41:35 +0200
commit2972862acc1462a00a162a934f6f02821d53db52 (patch)
tree189f88a0708063f0d456efd8e0a87987777e10cb /ardor3d-extras
parent50b35bdd3e0de2113bd086eb8c3020ac6122394e (diff)
Drives the source code compatible with Java 1.6 anew (I thank Matt Eskridge for reminding me my mistake)
Diffstat (limited to 'ardor3d-extras')
-rw-r--r--ardor3d-extras/src/main/java/com/ardor3d/extension/model/obj/ObjExporter.java11
1 files changed, 9 insertions, 2 deletions
diff --git a/ardor3d-extras/src/main/java/com/ardor3d/extension/model/obj/ObjExporter.java b/ardor3d-extras/src/main/java/com/ardor3d/extension/model/obj/ObjExporter.java
index 0078067..c1c2230 100644
--- a/ardor3d-extras/src/main/java/com/ardor3d/extension/model/obj/ObjExporter.java
+++ b/ardor3d-extras/src/main/java/com/ardor3d/extension/model/obj/ObjExporter.java
@@ -18,7 +18,6 @@ import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
-import java.util.Objects;
import java.util.logging.Logger;
import com.ardor3d.extension.model.util.KeyframeController;
@@ -207,7 +206,7 @@ public class ObjExporter {
&& mtl.forceBlend == currentMtl.forceBlend && mtl.d == currentMtl.d
&& Arrays.equals(mtl.Ka, currentMtl.Ka) && Arrays.equals(mtl.Kd, currentMtl.Kd)
&& Arrays.equals(mtl.Ks, currentMtl.Ks)
- && Objects.equals(mtl.textureName, currentMtl.textureName)) {
+ && equals(mtl.textureName, currentMtl.textureName)) {
sameObjMtl = mtl;
break;
}
@@ -351,6 +350,14 @@ public class ObjExporter {
}
}
+ public boolean equals(final Object a, final Object b) {
+ if (a == b) {
+ return true;
+ } else {
+ return a != null && a.equals(b);
+ }
+ }
+
private String getLocalMeshTextureName(final Mesh mesh) {
final String textureName;
if (mesh.getLocalRenderState(StateType.Texture) != null) {