From 7610bfb7aa8599aaa10b6d8bbd4d05fc6df3a418 Mon Sep 17 00:00:00 2001 From: "Kae..pl" Date: Mon, 13 May 2013 11:56:22 +0000 Subject: [PATCH] Bugfix: fixes to strip box indices and normals computation. git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@10612 75d07b2b-3a1a-0410-a2c5-0572b91ccdca --- .../core/com/jme3/scene/shape/StripBox.java | 28 +++++++++---------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/engine/src/core/com/jme3/scene/shape/StripBox.java b/engine/src/core/com/jme3/scene/shape/StripBox.java index 8efa2161f..312650caa 100644 --- a/engine/src/core/com/jme3/scene/shape/StripBox.java +++ b/engine/src/core/com/jme3/scene/shape/StripBox.java @@ -46,18 +46,18 @@ import java.nio.FloatBuffer; public class StripBox extends AbstractBox { private static final short[] GEOMETRY_INDICES_DATA = - { 1, 0, 4, - 5, - 7, - 0, - 3, - 1, - 2, - 4, - 6, - 7, - 2, - 3 }; + { 0, 1, 4, + 2, + 6, + 7, + 4, + 5, + 0, + 7, + 3, + 2, + 0, + 1}; private static final float[] GEOMETRY_TEXTURE_DATA = { 1, 0, @@ -155,8 +155,8 @@ public class StripBox extends AbstractBox { norm.set(vert[i]).normalizeLocal(); normals[i * 3 + 0] = norm.x; - normals[i * 3 + 1] = norm.x; - normals[i * 3 + 2] = norm.x; + normals[i * 3 + 1] = norm.y; + normals[i * 3 + 2] = norm.z; } setBuffer(Type.Normal, 3, BufferUtils.createFloatBuffer(normals));