summaryrefslogtreecommitdiffstats
path: root/core/math
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2017-07-30 22:53:40 +0200
committerRémi Verschelde <rverschelde@gmail.com>2017-07-30 22:53:40 +0200
commit76005a8e75d4e63ad0477e11dbc8cc1c86666875 (patch)
treee177bf6b716fe267ac39ec3047ff0a2156e0a59b /core/math
parent55494073081bd111dc6af8502f77cf344c64b56c (diff)
downloadredot-engine-76005a8e75d4e63ad0477e11dbc8cc1c86666875.tar.gz
Style: Apply clang-format on all files
Thus fixing some invalid changes that had still made it to the master branch.
Diffstat (limited to 'core/math')
-rw-r--r--core/math/face3.h24
1 files changed, 12 insertions, 12 deletions
diff --git a/core/math/face3.h b/core/math/face3.h
index 1cc94321c3..3d02ae4014 100644
--- a/core/math/face3.h
+++ b/core/math/face3.h
@@ -115,20 +115,20 @@ bool Face3::intersects_aabb2(const Rect3 &p_aabb) const {
if (dist_a * dist_b > 0)
return false; //does not intersect the plane
-#define TEST_AXIS(m_ax) \
- { \
+#define TEST_AXIS(m_ax) \
+ { \
real_t aabb_min = p_aabb.position.m_ax; \
real_t aabb_max = p_aabb.position.m_ax + p_aabb.size.m_ax; \
- real_t tri_min, tri_max; \
- for (int i = 0; i < 3; i++) { \
- if (i == 0 || vertex[i].m_ax > tri_max) \
- tri_max = vertex[i].m_ax; \
- if (i == 0 || vertex[i].m_ax < tri_min) \
- tri_min = vertex[i].m_ax; \
- } \
- \
- if (tri_max < aabb_min || aabb_max < tri_min) \
- return false; \
+ real_t tri_min, tri_max; \
+ for (int i = 0; i < 3; i++) { \
+ if (i == 0 || vertex[i].m_ax > tri_max) \
+ tri_max = vertex[i].m_ax; \
+ if (i == 0 || vertex[i].m_ax < tri_min) \
+ tri_min = vertex[i].m_ax; \
+ } \
+ \
+ if (tri_max < aabb_min || aabb_max < tri_min) \
+ return false; \
}
TEST_AXIS(x);