diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2023-02-13 23:44:24 +0100 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2023-02-13 23:44:24 +0100 |
commit | 81bfc8c7d65c30aa65c8820eb03dd6edda45db2a (patch) | |
tree | 73edb081430fe157794901ff415e8b6ad4c92b88 /scene | |
parent | 02a9a31b1bef87207986b7cdc34b6a9f596a3caf (diff) | |
parent | 8b1de103a88e4298b94f2f3b63ce1469ef660684 (diff) |
Merge pull request #61492 from Calinou/decal-clamp-extents
Clamp Decal size to positive values
Diffstat (limited to 'scene')
-rw-r--r-- | scene/3d/decal.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/3d/decal.cpp b/scene/3d/decal.cpp index e122adcc8c..6f2717fd41 100644 --- a/scene/3d/decal.cpp +++ b/scene/3d/decal.cpp @@ -31,7 +31,7 @@ #include "decal.h" void Decal::set_size(const Vector3 &p_size) { - size = p_size; + size = Vector3(MAX(0.001, p_size.x), MAX(0.001, p_size.y), MAX(0.001, p_size.z)); RS::get_singleton()->decal_set_size(decal, p_size); update_gizmos(); } |