summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Sauermann <6299227+Sauermann@users.noreply.github.com>2022-10-04 11:48:39 +0200
committerMarkus Sauermann <6299227+Sauermann@users.noreply.github.com>2022-10-04 11:48:39 +0200
commit650cc16b05120ea36aba8ff7cb2c0f56e9cbf910 (patch)
treeaf5f3711660e9fad560d7ed09a85069005e996a1
parent34e0e7de58ba4e7f2e4954266de8f13d5eb44c56 (diff)
Fix Transform2D det == 0 spam for SubViewports
-rw-r--r--scene/main/viewport.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/main/viewport.cpp b/scene/main/viewport.cpp
index 05b4f181c2..363da0ce1e 100644
--- a/scene/main/viewport.cpp
+++ b/scene/main/viewport.cpp
@@ -4135,7 +4135,7 @@ Transform2D SubViewport::_stretch_transform() {
Transform2D transform = Transform2D();
Size2i view_size_2d_override = _get_size_2d_override();
if (size_2d_override_stretch && view_size_2d_override.width > 0 && view_size_2d_override.height > 0) {
- Size2 scale = _get_size() / view_size_2d_override;
+ Size2 scale = Size2(_get_size()) / Size2(view_size_2d_override);
transform.scale(scale);
}