浏览代码

fixed Final pass blit

/main
Felipe Lira 7 年前
当前提交
c13ab97d
共有 1 个文件被更改,包括 7 次插入9 次删除
  1. 16
      ScriptableRenderPipeline/LightweightPipeline/LWRP/Passes/ForwardLitPass.cs

16
ScriptableRenderPipeline/LightweightPipeline/LWRP/Passes/ForwardLitPass.cs


// TODO: Move these to separate passes
if (cameraData.postProcessEnabled)
PostProcessPass(ref context, ref cameraData);
// No blit to backbuffer if camera is offscreen render.
if (!cameraData.isOffscreenRender && !cameraData.postProcessEnabled && colorAttachmentHandle != -1)
else if (!cameraData.isOffscreenRender && colorAttachmentHandle != -1)
FinalBlitPass(ref context, ref cameraData);
if (cameraData.isStereoEnabled)

CommandBuffer cmd = CommandBufferPool.Get("Final Blit Pass");
cmd.SetGlobalTexture("_BlitTex", sourceRT);
if (cameraData.isStereoEnabled || cameraData.isDefaultViewport)
{
cmd.Blit(GetSurface(colorAttachmentHandle), BuiltinRenderTextureType.CameraTarget, material);
}
else
if (!cameraData.isDefaultViewport)
}
else
{
cmd.Blit(GetSurface(colorAttachmentHandle), BuiltinRenderTextureType.CameraTarget, material);
}
context.ExecuteCommandBuffer(cmd);

正在加载...
取消
保存