diff options
author | Alexander Alekseev <alexander.n.alekseev@gmail.com> | 2018-05-04 10:24:48 +0300 |
---|---|---|
committer | Alexander Alekseev <alexander.n.alekseev@gmail.com> | 2018-05-04 12:43:50 +0300 |
commit | 26963473a9d832f18e05db074577511d2477a42a (patch) | |
tree | 4aa688c35d6aaa61d544312b7b2b61de53119be6 /core/math/math_2d.h | |
parent | d6ddfdf004a1b5a334a0709e87e2e427624e616b (diff) |
Vector3::round, Vector2::round & Vector2::ceil methods were added.
Now both structs (Vector2 & Vector3) have round, floor & ceil methods.
(see #18603)
Diffstat (limited to 'core/math/math_2d.h')
-rw-r--r-- | core/math/math_2d.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/core/math/math_2d.h b/core/math/math_2d.h index e7188da85b..611d47e3ff 100644 --- a/core/math/math_2d.h +++ b/core/math/math_2d.h @@ -162,6 +162,8 @@ struct Vector2 { } Vector2 floor() const; + Vector2 ceil() const; + Vector2 round() const; Vector2 snapped(const Vector2 &p_by) const; real_t aspect() const { return width / height; } |