Browse Source

tiny boost :)

David Catuhe 8 năm trước cách đây
mục cha
commit
83ca07188b

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 1224 - 1224
dist/preview release/babylon.d.ts


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 1224 - 1224
dist/preview release/babylon.module.d.ts


+ 4 - 0
src/Materials/babylon.materialHelper.ts

@@ -180,6 +180,10 @@
         }
 
         public static HandleFallbacksForShadows(defines: MaterialDefines, fallbacks: EffectFallbacks, maxSimultaneousLights = 4): void {
+            if (!defines["SHADOWS"]) {
+                return;
+            }
+
             for (var lightIndex = 0; lightIndex < maxSimultaneousLights; lightIndex++) {
                 if (!defines["LIGHT" + lightIndex]) {
                     break;