From 1080f64df9abd7af7ed762668e4fc9a300ae30f2 Mon Sep 17 00:00:00 2001
From: gdkchan <gab.dark.100@gmail.com>
Date: Thu, 4 Aug 2022 18:30:08 -0300
Subject: Implement HLE macros for render target clears (#3528)

* Implement HLE macros for render target clears

* Add constants for the offsets
---
 Ryujinx.Graphics.OpenGL/Framebuffer.cs | 10 ++++++++++
 1 file changed, 10 insertions(+)

(limited to 'Ryujinx.Graphics.OpenGL/Framebuffer.cs')

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];
-- 
cgit v1.2.3-70-g09d2