summaryrefslogtreecommitdiff
path: root/src/lib/embryo
diff options
context:
space:
mode:
authorCedric BAIL <cedric@osg.samsung.com>2017-01-06 09:57:46 -0800
committerCedric BAIL <cedric@osg.samsung.com>2017-01-06 15:58:46 -0800
commit8f1c071d6adbf6f8e2002eeeabdc7f3d7be9ef22 (patch)
tree17bddaa85bcdead8807053b009d1adf1c9eda71c /src/lib/embryo
parentf9928b75c8c4a2e6c3f02aafb68c8a569a47ab04 (diff)
eina: rename EINA_{FLT,DBL}_CMP to EINA_{FLT,DBL}_EQ.
Diffstat (limited to 'src/lib/embryo')
-rw-r--r--src/lib/embryo/embryo_float.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/lib/embryo/embryo_float.c b/src/lib/embryo/embryo_float.c
index 0d16e62965..f1e51df96d 100644
--- a/src/lib/embryo/embryo_float.c
+++ b/src/lib/embryo/embryo_float.c
@@ -125,9 +125,9 @@ _embryo_fp_div(Embryo_Program *ep EINA_UNUSED, Embryo_Cell *params)
125 if (params[0] != (2 * sizeof(Embryo_Cell))) return 0; 125 if (params[0] != (2 * sizeof(Embryo_Cell))) return 0;
126 f = EMBRYO_CELL_TO_FLOAT(params[1]); 126 f = EMBRYO_CELL_TO_FLOAT(params[1]);
127 ff = EMBRYO_CELL_TO_FLOAT(params[2]); 127 ff = EMBRYO_CELL_TO_FLOAT(params[2]);
128 if (EINA_FLT_CMP(ff, 0.0)) 128 if (EINA_FLT_EQ(ff, 0.0))
129 { 129 {
130 if (EINA_FLT_CMP(f, 0.0)) 130 if (EINA_FLT_EQ(f, 0.0))
131 return EMBRYO_FLOAT_TO_CELL(0.0f); 131 return EMBRYO_FLOAT_TO_CELL(0.0f);
132 else if (f < 0.0) 132 else if (f < 0.0)
133 return EMBRYO_FLOAT_TO_CELL(-MAXFLOAT); 133 return EMBRYO_FLOAT_TO_CELL(-MAXFLOAT);
@@ -217,7 +217,7 @@ _embryo_fp_cmp(Embryo_Program *ep EINA_UNUSED, Embryo_Cell *params)
217 if (params[0] != (2 * sizeof(Embryo_Cell))) return 0; 217 if (params[0] != (2 * sizeof(Embryo_Cell))) return 0;
218 f = EMBRYO_CELL_TO_FLOAT(params[1]); 218 f = EMBRYO_CELL_TO_FLOAT(params[1]);
219 ff = EMBRYO_CELL_TO_FLOAT(params[2]); 219 ff = EMBRYO_CELL_TO_FLOAT(params[2]);
220 if (EINA_FLT_CMP(f, ff)) return 0; 220 if (EINA_FLT_EQ(f, ff)) return 0;
221 else if (f > ff) 221 else if (f > ff)
222 return 1; 222 return 1;
223 return -1; 223 return -1;
@@ -269,14 +269,14 @@ _embryo_fp_log(Embryo_Program *ep, Embryo_Cell *params)
269 embryo_program_error_set(ep, EMBRYO_ERROR_DOMAIN); 269 embryo_program_error_set(ep, EMBRYO_ERROR_DOMAIN);
270 return 0; 270 return 0;
271 } 271 }
272 if (EINA_FLT_CMP(ff, 10.0)) 272 if (EINA_FLT_EQ(ff, 10.0))
273 f = log10f(f); 273 f = log10f(f);
274 else if (EINA_FLT_CMP(ff, 2.0)) 274 else if (EINA_FLT_EQ(ff, 2.0))
275 f = log2f(f); 275 f = log2f(f);
276 else 276 else
277 { 277 {
278 tf = logf(ff); 278 tf = logf(ff);
279 if (EINA_FLT_CMP(tf, 0.0)) 279 if (EINA_FLT_EQ(tf, 0.0))
280 f = 0.0; 280 f = 0.0;
281 else f = (logf(f) / tf); 281 else f = (logf(f) / tf);
282 } 282 }