summaryrefslogtreecommitdiff
path: root/core/math/aabb.h
diff options
context:
space:
mode:
authorAaron Franke <arnfranke@yahoo.com>2022-08-14 21:48:13 -0500
committerAaron Franke <arnfranke@yahoo.com>2022-09-04 23:03:36 -0500
commit817ae9566723fd28be9dc5bb199001dc50ca6b54 (patch)
tree71b8b0c4a5b5c133415d66bb8c96e99ccf253b06 /core/math/aabb.h
parente7a0a97c0bc5d86644e62d537503e3b05313a01c (diff)
Replace AABB has_no_volume with has_volume
Also replace has_no_surface with has_surface
Diffstat (limited to 'core/math/aabb.h')
-rw-r--r--core/math/aabb.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/core/math/aabb.h b/core/math/aabb.h
index e88ba33531..acf903eeba 100644
--- a/core/math/aabb.h
+++ b/core/math/aabb.h
@@ -47,12 +47,12 @@ struct _NO_DISCARD_ AABB {
Vector3 size;
real_t get_volume() const;
- _FORCE_INLINE_ bool has_no_volume() const {
- return (size.x <= 0 || size.y <= 0 || size.z <= 0);
+ _FORCE_INLINE_ bool has_volume() const {
+ return size.x > 0.0f && size.y > 0.0f && size.z > 0.0f;
}
- _FORCE_INLINE_ bool has_no_surface() const {
- return (size.x <= 0 && size.y <= 0 && size.z <= 0);
+ _FORCE_INLINE_ bool has_surface() const {
+ return size.x > 0.0f || size.y > 0.0f || size.z > 0.0f;
}
const Vector3 &get_position() const { return position; }