all public facing renderer functions take an RT
parent
56cdffdff6
commit
665ff6dd44
|
@ -178,6 +178,7 @@ namespace Kav
|
|||
}
|
||||
|
||||
public void DeferredRender(
|
||||
RenderTarget2D renderTarget,
|
||||
PerspectiveCamera camera,
|
||||
IEnumerable<(Model, Matrix)> modelTransforms,
|
||||
AmbientLight ambientLight,
|
||||
|
@ -200,8 +201,7 @@ namespace Kav
|
|||
|
||||
DirectionalLightRender(camera, modelTransforms, directionalLight);
|
||||
|
||||
GraphicsDevice.SetRenderTarget(null);
|
||||
GraphicsDevice.Clear(Color.Black);
|
||||
GraphicsDevice.SetRenderTarget(renderTarget);
|
||||
SpriteBatch.Begin(SpriteSortMode.Deferred, BlendState.Opaque, null, null, null, ToneMapEffect);
|
||||
SpriteBatch.Draw(ColorRenderTarget, Vector2.Zero, Color.White);
|
||||
SpriteBatch.End();
|
||||
|
|
Loading…
Reference in New Issue