Browse Source

Revert "Added onCreateCallback for WebGLAttributes #11882"

This reverts commit 152c85f1bdcb787725e04bf9a94dc1997aef3bca.
Luis Blanco 7 years ago
parent
commit
7aed6c9f12
1 changed files with 3 additions and 13 deletions
  1. 3 13
      src/renderers/webgl/WebGLAttributes.js

+ 3 - 13
src/renderers/webgl/WebGLAttributes.js

@@ -11,20 +11,10 @@ function WebGLAttributes( gl ) {
 		var array = attribute.array;
 		var usage = attribute.dynamic ? gl.DYNAMIC_DRAW : gl.STATIC_DRAW;
 
-		var buffer;
+		var buffer = gl.createBuffer();
 
-		if (attribute.onCreateCallback) {
-
-			buffer = attribute.onCreateCallback();
-
-		} else {
-
-			buffer = gl.createBuffer();
-
-			gl.bindBuffer( bufferType, buffer );
-			gl.bufferData( bufferType, array, usage );
-
-		}
+		gl.bindBuffer( bufferType, buffer );
+		gl.bufferData( bufferType, array, usage );
 
 		attribute.onUploadCallback();