summaryrefslogtreecommitdiffstats
path: root/core/math/quaternion.h
diff options
context:
space:
mode:
authorlawnjelly <lawnjelly@gmail.com>2022-02-24 07:17:00 +0000
committerlawnjelly <lawnjelly@gmail.com>2022-02-24 08:15:10 +0000
commit1485924a2b90d15949fe544097ce8d00d527e9e7 (patch)
tree0f1dff59ef994a9b0ea640d3745858b114128fdd /core/math/quaternion.h
parentcfc7c78732198a7ebc43b92ed24e7025fdf4bc11 (diff)
downloadredot-engine-1485924a2b90d15949fe544097ce8d00d527e9e7.tar.gz
Float literals - fix main primitives to use real_t casting
Uses (real_t) casting to ensure appropriate calculations are done in 32 bit where real_t is compiled as 32 bit.
Diffstat (limited to 'core/math/quaternion.h')
-rw-r--r--core/math/quaternion.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/math/quaternion.h b/core/math/quaternion.h
index f8a2c6456e..38729ac3df 100644
--- a/core/math/quaternion.h
+++ b/core/math/quaternion.h
@@ -145,7 +145,7 @@ struct _NO_DISCARD_ Quaternion {
Vector3 c = v0.cross(v1);
real_t d = v0.dot(v1);
- if (d < -1.0f + CMP_EPSILON) {
+ if (d < -1.0f + (real_t)CMP_EPSILON) {
x = 0;
y = 1;
z = 0;