Browse Source

Update CSMShader SpotLight for 147 (#25116)

vSpotShadowCoord seems to have been replaced with vSpotLightCoord in r147. CSMShader.js needed to be updated.
Kevin 2 years ago
parent
commit
2cd85413b8
1 changed files with 1 additions and 1 deletions
  1. 1 1
      examples/jsm/csm/CSMShader.js

+ 1 - 1
examples/jsm/csm/CSMShader.js

@@ -58,7 +58,7 @@ IncidentLight directLight;
 
 		#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_SPOT_LIGHT_SHADOWS )
 		spotLightShadow = spotLightShadows[ i ];
-		directLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getShadow( spotShadowMap[ i ], spotLightShadow.shadowMapSize, spotLightShadow.shadowBias, spotLightShadow.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;
+		directLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getShadow( spotShadowMap[ i ], spotLightShadow.shadowMapSize, spotLightShadow.shadowBias, spotLightShadow.shadowRadius, vSpotLightCoord[ i ] ) : 1.0;
 		#endif
 
 		RE_Direct( directLight, geometry, material, reflectedLight );