From 72be8876ea40984532d283c598dfcc267d30c829 Mon Sep 17 00:00:00 2001 From: Juan Linietsky Date: Fri, 18 Aug 2017 15:11:16 -0300 Subject: Properly manage drawing of primitives when they lack an area, fixes #8930 --- core/math/rect3.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'core/math') diff --git a/core/math/rect3.h b/core/math/rect3.h index 7c971f5ac7..4890a19d99 100644 --- a/core/math/rect3.h +++ b/core/math/rect3.h @@ -47,12 +47,12 @@ public: real_t get_area() const; /// get area _FORCE_INLINE_ bool has_no_area() const { - return (size.x <= CMP_EPSILON || size.y <= CMP_EPSILON || size.z <= CMP_EPSILON); + return (size.x <= 0 || size.y <= 0 || size.z <= 0); } _FORCE_INLINE_ bool has_no_surface() const { - return (size.x <= CMP_EPSILON && size.y <= CMP_EPSILON && size.z <= CMP_EPSILON); + return (size.x <= 0 && size.y <= 0 && size.z <= 0); } const Vector3 &get_position() const { return position; } -- cgit v1.2.3