removed unneeded check for macro defined variable EPSILON

This commit is contained in:
user 2025-08-07 20:47:29 +03:00
parent c6171d339c
commit 27473b5c0f

View File

@ -1197,10 +1197,6 @@ RMAPI Vector3 Vector3ClampValue(Vector3 v, float min, float max)
// Check whether two given vectors are almost equal // Check whether two given vectors are almost equal
RMAPI int Vector3Equals(Vector3 p, Vector3 q) RMAPI int Vector3Equals(Vector3 p, Vector3 q)
{ {
#if !defined(EPSILON)
#define EPSILON 0.000001f
#endif
int result = ((fabsf(p.x - q.x)) <= (EPSILON*fmaxf(1.0f, fmaxf(fabsf(p.x), fabsf(q.x))))) && int result = ((fabsf(p.x - q.x)) <= (EPSILON*fmaxf(1.0f, fmaxf(fabsf(p.x), fabsf(q.x))))) &&
((fabsf(p.y - q.y)) <= (EPSILON*fmaxf(1.0f, fmaxf(fabsf(p.y), fabsf(q.y))))) && ((fabsf(p.y - q.y)) <= (EPSILON*fmaxf(1.0f, fmaxf(fabsf(p.y), fabsf(q.y))))) &&
((fabsf(p.z - q.z)) <= (EPSILON*fmaxf(1.0f, fmaxf(fabsf(p.z), fabsf(q.z))))); ((fabsf(p.z - q.z)) <= (EPSILON*fmaxf(1.0f, fmaxf(fabsf(p.z), fabsf(q.z)))));