summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorVaxry <vaxry@vaxry.net>2024-02-05 22:37:24 +0000
committerVaxry <vaxry@vaxry.net>2024-02-05 22:37:34 +0000
commit181f651de2e67917c7fcc72f7a69e6f4707954e5 (patch)
tree0dfcb61a97898b38f41da333b22140d512d1dd9f /src
parent8a6e428d32f170737110a2184c4d59c98f317422 (diff)
vector: avoid min0 clamps without a max being invalid
Diffstat (limited to 'src')
-rw-r--r--src/helpers/Vector2D.hpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/helpers/Vector2D.hpp b/src/helpers/Vector2D.hpp
index c56e8a04..44eae3f3 100644
--- a/src/helpers/Vector2D.hpp
+++ b/src/helpers/Vector2D.hpp
@@ -88,7 +88,7 @@ class Vector2D {
double distance(const Vector2D& other) const;
double size() const;
- Vector2D clamp(const Vector2D& min, const Vector2D& max = Vector2D()) const;
+ Vector2D clamp(const Vector2D& min, const Vector2D& max = Vector2D{-1, -1}) const;
Vector2D floor() const;
Vector2D round() const;