Kaynağa Gözat

removed "test code".

javasabr 7 yıl önce
ebeveyn
işleme
7d5fcd0d40

+ 1 - 1
jme3-core/src/main/java/com/jme3/material/Material.java

@@ -828,7 +828,7 @@ public class Material implements CloneableSmartAsset, Cloneable, Savable {
             MatParam param = paramValues.getValue(i);
             VarType type = param.getVarType();
 
-            if(isBO(type)) {
+            if (isBO(type)) {
 
                 final ShaderBufferBlock bufferBlock = shader.getBufferBlock(param.getPrefixedName());
                 bufferBlock.setBufferObject((BufferObject) param.getValue());

+ 1 - 0
jme3-core/src/main/java/com/jme3/renderer/opengl/GL.java

@@ -66,6 +66,7 @@ public interface GL {
     public static final int GL_DST_ALPHA = 0x0304;
     public static final int GL_DST_COLOR = 0x306;
     public static final int GL_DYNAMIC_DRAW = 0x88E8;
+    public static final int GL_DYNAMIC_COPY = 0x88EA;
     public static final int GL_ELEMENT_ARRAY_BUFFER = 0x8893;
     public static final int GL_EQUAL = 0x202;
     public static final int GL_EXTENSIONS = 0x1F03;

+ 0 - 21
jme3-core/src/test/java/com/jme3/SetupTest.java

@@ -31,13 +31,6 @@
  */
 package com.jme3;
 
-import com.jme3.material.Material;
-import com.jme3.math.ColorRGBA;
-import com.jme3.shader.BufferObject;
-import com.jme3.shader.BufferObject.Layout;
-import com.jme3.shader.BufferObjectField;
-import com.jme3.shader.UniformBufferObject;
-import com.jme3.shader.VarType;
 import org.junit.Test;
 
 /**
@@ -48,20 +41,6 @@ public class SetupTest {
     
    @Test(expected=AssertionError.class)
    public void testAssertionEnabled() {
-
-       Material material;
-
-       final UniformBufferObject ubo = new UniformBufferObject(3, Layout.std140,
-           new BufferObjectField("light_1", VarType.Vector4),
-           new BufferObjectField("light_2", VarType.Vector4),
-           new BufferObjectField("array", VarType.FloatArray)
-       );
-       ubo.setValue("light_1", ColorRGBA.Black);
-       ubo.setValue("light_2", ColorRGBA.Gray);
-       ubo.setValue("array", new float[] {1F, 2F, 3F});
-
-       material.setBufferObject("uboTest", ubo);
-
        assert false;
    }
 }