summaryrefslogtreecommitdiffstats
path: root/include/core/Defs.hpp
diff options
context:
space:
mode:
authorMarc <marc.gilleron@gmail.com>2021-01-31 20:06:56 +0000
committerGitHub <noreply@github.com>2021-01-31 20:06:56 +0000
commitb400dba87534640eeddbcdb6b319335a6a7639d8 (patch)
tree286a8e2e25c18fe11f346835b3021afae2e9b77f /include/core/Defs.hpp
parentfb71edd45b2473bf0ac502c777a1850fb564087e (diff)
parent05ba977cc60653952b73dc03498ebc7a93cef120 (diff)
downloadredot-cpp-b400dba87534640eeddbcdb6b319335a6a7639d8.tar.gz
Merge branch 'master' into container_leaks
Diffstat (limited to 'include/core/Defs.hpp')
-rw-r--r--include/core/Defs.hpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/include/core/Defs.hpp b/include/core/Defs.hpp
index 67e3279..e90f6ce 100644
--- a/include/core/Defs.hpp
+++ b/include/core/Defs.hpp
@@ -70,9 +70,12 @@ enum class Error {
typedef float real_t;
-#define CMP_EPSILON 0.00001
+// This epsilon should match the one used by Godot for consistency.
+// Using `f` when `real_t` is float.
+#define CMP_EPSILON 0.00001f
#define CMP_EPSILON2 (CMP_EPSILON * CMP_EPSILON)
-#define Math_PI 3.14159265358979323846
+
+#define Math_PI 3.1415926535897932384626433833
#define Math_TAU 6.2831853071795864769252867666
#define _PLANE_EQ_DOT_EPSILON 0.999