From ed94e3eb7944c79b23e744c9e12dfcf3bb21f2a1 Mon Sep 17 00:00:00 2001 From: Bastiaan Olij Date: Mon, 7 Aug 2023 20:26:48 +1000 Subject: [PATCH] Fix issue with four subpasses always been requested in mobile renderer (cherry picked from commit 414df467cdf34d88c0612c57c520ca8c28683149) --- .../renderer_rd/forward_mobile/render_forward_mobile.cpp | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/servers/rendering/renderer_rd/forward_mobile/render_forward_mobile.cpp b/servers/rendering/renderer_rd/forward_mobile/render_forward_mobile.cpp index 98a26ac36e1..9222da7b3d9 100644 --- a/servers/rendering/renderer_rd/forward_mobile/render_forward_mobile.cpp +++ b/servers/rendering/renderer_rd/forward_mobile/render_forward_mobile.cpp @@ -746,16 +746,9 @@ void RenderForwardMobile::_render_scene(RenderDataRD *p_render_data, const Color using_subpass_post_process = false; } - // We do this last because our get_color_fbs creates and caches the framebuffer if we need it. - RID four_subpasses = rb_data->get_color_fbs(RenderBufferDataForwardMobile::FB_CONFIG_FOUR_SUBPASSES); - if (using_subpass_post_process && four_subpasses.is_null()) { - // can't do blit subpass because we don't have all subpasses - using_subpass_post_process = false; - } - if (using_subpass_post_process) { // all as subpasses - framebuffer = four_subpasses; + framebuffer = rb_data->get_color_fbs(RenderBufferDataForwardMobile::FB_CONFIG_FOUR_SUBPASSES); } else if (using_subpass_transparent) { // our tonemap pass is separate framebuffer = rb_data->get_color_fbs(RenderBufferDataForwardMobile::FB_CONFIG_THREE_SUBPASSES);