aboutsummaryrefslogtreecommitdiff
path: root/Ryujinx.Graphics.OpenGL/Framebuffer.cs
diff options
context:
space:
mode:
authorgdkchan <gab.dark.100@gmail.com>2022-08-04 18:30:08 -0300
committerGitHub <noreply@github.com>2022-08-04 21:30:08 +0000
commit1080f64df9abd7af7ed762668e4fc9a300ae30f2 (patch)
treedc6c882fe3254c9966b916f29e3783de0c61f2b2 /Ryujinx.Graphics.OpenGL/Framebuffer.cs
parentc48a75979fad2cf7909f128e265086ff83c2ba55 (diff)
Implement HLE macros for render target clears (#3528)1.1.207
* Implement HLE macros for render target clears * Add constants for the offsets
Diffstat (limited to 'Ryujinx.Graphics.OpenGL/Framebuffer.cs')
-rw-r--r--Ryujinx.Graphics.OpenGL/Framebuffer.cs10
1 files changed, 10 insertions, 0 deletions
diff --git a/Ryujinx.Graphics.OpenGL/Framebuffer.cs b/Ryujinx.Graphics.OpenGL/Framebuffer.cs
index dafa7672..d132e9c4 100644
--- a/Ryujinx.Graphics.OpenGL/Framebuffer.cs
+++ b/Ryujinx.Graphics.OpenGL/Framebuffer.cs
@@ -145,6 +145,16 @@ namespace Ryujinx.Graphics.OpenGL
return format == Format.D16Unorm || format == Format.D32Float;
}
+ public int GetColorLayerCount(int index)
+ {
+ return _colors[index].Info.GetDepthOrLayers();
+ }
+
+ public int GetDepthStencilLayerCount()
+ {
+ return _depthStencil?.Info.GetDepthOrLayers() ?? 0;
+ }
+
public void AttachColorLayerForClear(int index, int layer)
{
TextureView color = _colors[index];