Explorar o código

WebGLShadowMap: Stop support of Geometry when using morph targets.

Mugen87 %!s(int64=5) %!d(string=hai) anos
pai
achega
c89c4e23f1
Modificáronse 1 ficheiros con 2 adicións e 10 borrados
  1. 2 10
      src/renderers/webgl/WebGLShadowMap.js

+ 2 - 10
src/renderers/webgl/WebGLShadowMap.js

@@ -297,17 +297,9 @@ function WebGLShadowMap( _renderer, _objects, maxTextureSize ) {
 
 			var useMorphing = false;
 
-			if ( material.morphTargets === true ) {
+			if ( material.morphTargets === true && geometry.isBufferGeometry === true ) {
 
-				if ( geometry.isBufferGeometry === true ) {
-
-					useMorphing = geometry.morphAttributes && geometry.morphAttributes.position && geometry.morphAttributes.position.length > 0;
-
-				} else if ( geometry.isGeometry === true ) {
-
-					useMorphing = geometry.morphTargets && geometry.morphTargets.length > 0;
-
-				}
+				useMorphing = geometry.morphAttributes && geometry.morphAttributes.position && geometry.morphAttributes.position.length > 0;
 
 			}