summaryrefslogtreecommitdiff
path: root/servers/rendering/renderer_rd/forward_clustered
diff options
context:
space:
mode:
authorclayjohn <claynjohn@gmail.com>2022-11-17 12:36:47 -0800
committerclayjohn <claynjohn@gmail.com>2022-11-17 12:51:26 -0800
commit21ac6d7d8e704eb5e624a17b8e3991d63c22e4a9 (patch)
tree17bb99e732cbd8e22e9636939b532606ceb7bc73 /servers/rendering/renderer_rd/forward_clustered
parent49cc12bf89689c35f0d867790a25fb3112899a6d (diff)
Finish implementing Canvas Background mode
Diffstat (limited to 'servers/rendering/renderer_rd/forward_clustered')
-rw-r--r--servers/rendering/renderer_rd/forward_clustered/render_forward_clustered.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/servers/rendering/renderer_rd/forward_clustered/render_forward_clustered.cpp b/servers/rendering/renderer_rd/forward_clustered/render_forward_clustered.cpp
index 2d1d0e0951..41fceac7c2 100644
--- a/servers/rendering/renderer_rd/forward_clustered/render_forward_clustered.cpp
+++ b/servers/rendering/renderer_rd/forward_clustered/render_forward_clustered.cpp
@@ -1765,6 +1765,10 @@ void RenderForwardClustered::_render_scene(RenderDataRD *p_render_data, const Co
draw_sky = true;
} break;
case RS::ENV_BG_CANVAS: {
+ if (rb.is_valid()) {
+ RID texture = RendererRD::TextureStorage::get_singleton()->render_target_get_rd_texture(rb->get_render_target());
+ copy_effects->copy_to_fb_rect(texture, color_only_framebuffer, Rect2i(), false, false, false, false, RID(), false, false, true);
+ }
keep_color = true;
} break;
case RS::ENV_BG_KEEP: {