From 5818959e543041fdff8965e71e52d55a05ee22de Mon Sep 17 00:00:00 2001 From: Fernando Sahmkow Date: Thu, 11 Jul 2019 15:15:21 -0400 Subject: Texture_Cache: Force Framebuffer reset if an active render target is unregistered. --- src/video_core/texture_cache/surface_base.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/video_core/texture_cache/surface_base.h') diff --git a/src/video_core/texture_cache/surface_base.h b/src/video_core/texture_cache/surface_base.h index 8ba386a8a..fb6378bc7 100644 --- a/src/video_core/texture_cache/surface_base.h +++ b/src/video_core/texture_cache/surface_base.h @@ -200,8 +200,9 @@ public: modification_tick = tick; } - void MarkAsRenderTarget(const bool is_target) { + void MarkAsRenderTarget(const bool is_target, const u32 index) { this->is_target = is_target; + this->index = index; } void MarkAsPicked(const bool is_picked) { @@ -221,6 +222,10 @@ public: return is_target; } + u32 GetRenderTarget() const { + return index; + } + bool IsRegistered() const { return is_registered; } @@ -311,6 +316,7 @@ private: bool is_target{}; bool is_registered{}; bool is_picked{}; + u32 index{0xFFFFFFFF}; u64 modification_tick{}; }; -- cgit v1.2.3