diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2019-04-29 10:16:46 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-29 10:16:46 +0200 |
commit | 18e88c85631adb0b83114687f8c20d9b210a88bf (patch) | |
tree | 28d1817600fb497215008d08045ed4e20a8cba95 /servers/visual/visual_server_canvas.h | |
parent | 90cc1d3c1d2e77ca72c5949b21a5c40738abcd81 (diff) | |
parent | b659e1eb2b732ebc836614735438ca0bcdc8a32d (diff) |
Merge pull request #18992 from aaronfranke/mono-equal-approx
[Core] [Mono] Improve and use approximate equality methods
Diffstat (limited to 'servers/visual/visual_server_canvas.h')
-rw-r--r-- | servers/visual/visual_server_canvas.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/servers/visual/visual_server_canvas.h b/servers/visual/visual_server_canvas.h index 4e99bb3676..26424f927e 100644 --- a/servers/visual/visual_server_canvas.h +++ b/servers/visual/visual_server_canvas.h @@ -82,7 +82,7 @@ public: _FORCE_INLINE_ bool operator()(const Item *p_left, const Item *p_right) const { - if (Math::abs(p_left->ysort_pos.y - p_right->ysort_pos.y) < CMP_EPSILON) + if (Math::is_equal_approx(p_left->ysort_pos.y, p_right->ysort_pos.y)) return p_left->ysort_pos.x < p_right->ysort_pos.x; else return p_left->ysort_pos.y < p_right->ysort_pos.y; |