浏览代码

fix weight accumulation.

Ben Houston 9 年之前
父节点
当前提交
9e625f4248
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      examples/js/postprocessing/MSAAPass.js

+ 1 - 1
examples/js/postprocessing/MSAAPass.js

@@ -92,7 +92,7 @@ THREE.MSAAPass.prototype = {
 
 
       // this accumulation strategy is used to prevent decimation at low bit depths with lots of samples.
       // this accumulation strategy is used to prevent decimation at low bit depths with lots of samples.
       this.uniforms[ "scale" ].value = weight;
       this.uniforms[ "scale" ].value = weight;
-      weight *= 0.5;
+      weight = 1.0 / (i+1);
 
 
     // clear on the first render, accumulate the others
     // clear on the first render, accumulate the others
       var autoClear = renderer.autoClear;
       var autoClear = renderer.autoClear;