summaryrefslogtreecommitdiff
path: root/servers/rendering/renderer_rd/storage_rd
diff options
context:
space:
mode:
authorclayjohn <claynjohn@gmail.com>2022-12-12 14:10:06 -0800
committerclayjohn <claynjohn@gmail.com>2022-12-13 10:22:18 -0800
commitbdd4001ef012c9e7a95b501225c3f6540a0299f3 (patch)
treeffd6b82a1eb19c0f322c8898e52962e1f6f8682e /servers/rendering/renderer_rd/storage_rd
parentba4bd7f00971a94c20d90e7d2c665d5eb0ae1b90 (diff)
Various fixes and documentation for CanvasGroup
Properly apply custom materials with CanvasGroups in the GLES3 backend Properly blur backbuffer when using a partial rect in forward_plus and gl_compatibility renderers Properly set fit_margin when clear_margin is set Fix shader error during backbuffer clear in mobile renderer
Diffstat (limited to 'servers/rendering/renderer_rd/storage_rd')
-rw-r--r--servers/rendering/renderer_rd/storage_rd/texture_storage.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/servers/rendering/renderer_rd/storage_rd/texture_storage.cpp b/servers/rendering/renderer_rd/storage_rd/texture_storage.cpp
index 15c5687665..543eb0cb72 100644
--- a/servers/rendering/renderer_rd/storage_rd/texture_storage.cpp
+++ b/servers/rendering/renderer_rd/storage_rd/texture_storage.cpp
@@ -3140,13 +3140,13 @@ void TextureStorage::render_target_copy_to_back_buffer(RID p_render_target, cons
region.position.y >>= 1;
region.size.x = MAX(1, region.size.x >> 1);
region.size.y = MAX(1, region.size.y >> 1);
+ texture_size.x = MAX(1, texture_size.x >> 1);
+ texture_size.y = MAX(1, texture_size.y >> 1);
RID mipmap = rt->backbuffer_mipmaps[i];
if (RendererSceneRenderRD::get_singleton()->_render_buffers_can_be_storage()) {
- copy_effects->gaussian_blur(prev_texture, mipmap, region, true);
+ copy_effects->gaussian_blur(prev_texture, mipmap, region, texture_size, true);
} else {
- texture_size.x = MAX(1, texture_size.x >> 1);
- texture_size.y = MAX(1, texture_size.y >> 1);
copy_effects->gaussian_blur_raster(prev_texture, mipmap, region, texture_size);
}
prev_texture = mipmap;
@@ -3179,7 +3179,7 @@ void TextureStorage::render_target_clear_back_buffer(RID p_render_target, const
if (RendererSceneRenderRD::get_singleton()->_render_buffers_can_be_storage()) {
copy_effects->set_color(rt->backbuffer_mipmap0, p_color, region, true);
} else {
- copy_effects->set_color(rt->backbuffer_mipmap0, p_color, region, true);
+ copy_effects->set_color_raster(rt->backbuffer_mipmap0, p_color, region);
}
}
@@ -3213,14 +3213,14 @@ void TextureStorage::render_target_gen_back_buffer_mipmaps(RID p_render_target,
region.position.y >>= 1;
region.size.x = MAX(1, region.size.x >> 1);
region.size.y = MAX(1, region.size.y >> 1);
+ texture_size.x = MAX(1, texture_size.x >> 1);
+ texture_size.y = MAX(1, texture_size.y >> 1);
RID mipmap = rt->backbuffer_mipmaps[i];
if (RendererSceneRenderRD::get_singleton()->_render_buffers_can_be_storage()) {
- copy_effects->gaussian_blur(prev_texture, mipmap, region, true);
+ copy_effects->gaussian_blur(prev_texture, mipmap, region, texture_size, true);
} else {
- texture_size.x = MAX(1, texture_size.x >> 1);
- texture_size.y = MAX(1, texture_size.y >> 1);
copy_effects->gaussian_blur_raster(prev_texture, mipmap, region, texture_size);
}
prev_texture = mipmap;