소스 검색

move fxaa to end of pipeline to avoid issues with bloom for now

Trevor Baron 7 년 전
부모
커밋
ef54caea5f
1개의 변경된 파일6개의 추가작업 그리고 7개의 파일을 삭제
  1. 6 7
      src/PostProcess/RenderPipeline/Pipelines/babylon.defaultRenderingPipeline.ts

+ 6 - 7
src/PostProcess/RenderPipeline/Pipelines/babylon.defaultRenderingPipeline.ts

@@ -413,13 +413,6 @@
             this._prevPostProcess = null;
             this._prevPrevPostProcess = null;
 
-            if (this.fxaaEnabled) {
-                this.fxaa = new FxaaPostProcess("fxaa", 1.0, null, Texture.BILINEAR_SAMPLINGMODE, engine, false, this._defaultPipelineTextureType);
-                this.addEffect(new PostProcessRenderEffect(engine, this.FxaaPostProcessId, () => { return this.fxaa; }, true));
-                this._setAutoClearAndTextureSharing(this.fxaa);
-                
-            }
-
             if (this.sharpenEnabled) {
                 this.addEffect(this._sharpenEffect);
                 this._setAutoClearAndTextureSharing(this.sharpen);
@@ -509,6 +502,12 @@
                 }
             }
 
+            if (this.fxaaEnabled) {
+                this.fxaa = new FxaaPostProcess("fxaa", 1.0, null, Texture.BILINEAR_SAMPLINGMODE, engine, false, this._defaultPipelineTextureType);
+                this.addEffect(new PostProcessRenderEffect(engine, this.FxaaPostProcessId, () => { return this.fxaa; }, true));
+                this._setAutoClearAndTextureSharing(this.fxaa);
+            }
+
             if (this.chromaticAberrationEnabled) {
                 this.addEffect(this._chromaticAberrationEffect);
                 this._setAutoClearAndTextureSharing(this.chromaticAberration);