Riccardo Balbo 2 年之前
父節點
當前提交
8aea6a82e3
共有 1 個文件被更改,包括 1 次插入2 次删除
  1. 1 2
      jme3-core/src/main/resources/Common/ShaderLib/Shadows.glsllib

+ 1 - 2
jme3-core/src/main/resources/Common/ShaderLib/Shadows.glsllib

@@ -177,8 +177,7 @@ float Shadow_DoPCF(in SHADOWMAP tex,in vec4 projCoord){
     if (border > 0.0)
     if (border > 0.0)
         return 1.0;
         return 1.0;
 
 
-    float bound = KERNEL * 0.5 - 0.5;
-    bound *= PCFEDGE;
+    const float bound = (KERNEL * 0.5 - 0.5 ) * PCFEDGE;
     for (float y = -bound; y <= bound; y += PCFEDGE){
     for (float y = -bound; y <= bound; y += PCFEDGE){
         for (float x = -bound; x <= bound; x += PCFEDGE){
         for (float x = -bound; x <= bound; x += PCFEDGE){
             #if __VERSION__ < 130
             #if __VERSION__ < 130