Introduce Renderer.WorldBufferSnapshot().

This commit is contained in:
Paul Chote
2023-12-04 17:11:02 +00:00
committed by Gustas
parent 6a86a99fce
commit 6c56ea4c55
5 changed files with 18 additions and 14 deletions

View File

@@ -42,9 +42,9 @@ namespace OpenRA.Mods.Common.Traits
PostProcessPassType IRenderPostProcessPass.Type => type;
bool IRenderPostProcessPass.Enabled => Enabled;
void IRenderPostProcessPass.Draw(WorldRenderer wr, ITexture worldTexture)
void IRenderPostProcessPass.Draw(WorldRenderer wr)
{
shader.SetTexture("WorldTexture", worldTexture);
shader.SetTexture("WorldTexture", Game.Renderer.WorldBufferSnapshot());
PrepareRender(wr, shader);
shader.PrepareRender();
renderer.DrawBatch(buffer, shader, 0, 6, PrimitiveType.TriangleList);