aboutsummaryrefslogtreecommitdiff
path: root/Ryujinx.Graphics.OpenGL/Framebuffer.cs
diff options
context:
space:
mode:
authorgdkchan <gab.dark.100@gmail.com>2022-08-08 14:39:22 -0300
committerGitHub <noreply@github.com>2022-08-08 17:39:22 +0000
commit66e7fdb8710ff24bfb80c9c638ce2e6fa9563068 (patch)
tree7be487e2abc0e8069944b40965e5d2cd5d0cea05 /Ryujinx.Graphics.OpenGL/Framebuffer.cs
parent2bb9b33da1f872dc7e52b92c9f282e3d971d2cdf (diff)
OpenGL: Fix clears of unbound color targets (#3564)1.1.209
Diffstat (limited to 'Ryujinx.Graphics.OpenGL/Framebuffer.cs')
-rw-r--r--Ryujinx.Graphics.OpenGL/Framebuffer.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Ryujinx.Graphics.OpenGL/Framebuffer.cs b/Ryujinx.Graphics.OpenGL/Framebuffer.cs
index d132e9c4..b180b857 100644
--- a/Ryujinx.Graphics.OpenGL/Framebuffer.cs
+++ b/Ryujinx.Graphics.OpenGL/Framebuffer.cs
@@ -147,7 +147,7 @@ namespace Ryujinx.Graphics.OpenGL
public int GetColorLayerCount(int index)
{
- return _colors[index].Info.GetDepthOrLayers();
+ return _colors[index]?.Info.GetDepthOrLayers() ?? 0;
}
public int GetDepthStencilLayerCount()