raster pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=668e6091fb4c35835c32c219192cbacad69eaea3

commit 668e6091fb4c35835c32c219192cbacad69eaea3
Author: Carsten Haitzler (Rasterman) <[email protected]>
Date:   Sat May 21 23:35:12 2016 +0900

    eina vector inline header - replace last equal with approx macro
    
    rthis replaces double a == double b with a macro that keeps a close
    enough range using epsilon (which is the error range for a dobule).
    
    this fixes T3245
---
 src/lib/eina/eina_inline_vector.x | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/lib/eina/eina_inline_vector.x 
b/src/lib/eina/eina_inline_vector.x
index 67f2e33..939dc9e 100644
--- a/src/lib/eina/eina_inline_vector.x
+++ b/src/lib/eina/eina_inline_vector.x
@@ -328,7 +328,9 @@ eina_vector3_homogeneous_position_transform(Eina_Vector3 
*out, const Eina_Matrix
         return;
      }
 
-   if (((m->xw * v->x) + (m->yw * v->y) + (m->zw * v->z) + m->ww) == 0.0)
+   if (EINA_DOUBLE_EQUAL((m->xw * v->x) + (m->yw * v->y) +
+                         (m->zw * v->z) + m->ww,
+                         0.0))
      return;
 
    tmp.x = (m->xx * v->x) + (m->yx * v->y) + (m->zx * v->z) + m->wx;

-- 


Reply via email to