Browse Source

- improve failsafeness of GeometryBatchFactory

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@8984 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
nor..67 14 years ago
parent
commit
fbf42ffbca
1 changed files with 2 additions and 2 deletions
  1. 2 2
      engine/src/tools/jme3tools/optimize/GeometryBatchFactory.java

+ 2 - 2
engine/src/tools/jme3tools/optimize/GeometryBatchFactory.java

@@ -158,10 +158,10 @@ public class GeometryBatchFactory {
                 VertexBuffer inBuf = inMesh.getBuffer(Type.values()[bufType]);
                 VertexBuffer outBuf = outMesh.getBuffer(Type.values()[bufType]);
 
-                if (outBuf == null) {
+                if (inBuf == null || outBuf == null) {
                     continue;
                 }
-
+                
                 if (Type.Index.ordinal() == bufType) {
                     int components = compsForBuf[bufType];