diff options
author | Anilforextra <anilforextra@gmail.com> | 2021-09-25 14:46:45 +0545 |
---|---|---|
committer | Anilforextra <anilforextra@gmail.com> | 2021-09-25 14:46:45 +0545 |
commit | cdd912c48eab15f581459afc2cda8fdcfabf92db (patch) | |
tree | d2d4ce59b2e55c8947103fc40ce1258728a8dc65 /servers/rendering/renderer_rd/renderer_compositor_rd.cpp | |
parent | 5e4a71200e25811d8e570d87f08f0878dabb8bb9 (diff) |
Construct values only when necessary.
Diffstat (limited to 'servers/rendering/renderer_rd/renderer_compositor_rd.cpp')
-rw-r--r-- | servers/rendering/renderer_rd/renderer_compositor_rd.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/servers/rendering/renderer_rd/renderer_compositor_rd.cpp b/servers/rendering/renderer_rd/renderer_compositor_rd.cpp index c53c202bab..559e6d5ad7 100644 --- a/servers/rendering/renderer_rd/renderer_compositor_rd.cpp +++ b/servers/rendering/renderer_rd/renderer_compositor_rd.cpp @@ -197,7 +197,7 @@ void RendererCompositorRD::set_boot_image(const Ref<Image> &p_image, const Color } } else { screenrect = imgrect; - screenrect.position += ((Size2(window_size.width, window_size.height) - screenrect.size) / 2.0).floor(); + screenrect.position += ((window_size - screenrect.size) / 2.0).floor(); } screenrect.position /= window_size; |