1
0
Fork 0

actor: Use CLUTTER_NEARBYINT instead of C integer casting

Otherwise we break because of rounding.
This commit is contained in:
Emmanuele Bassi 2015-07-10 14:33:25 +01:00
parent b0e785c6c2
commit 3e14d87188

View file

@ -15183,7 +15183,7 @@ clutter_actor_transform_stage_point (ClutterActor *self,
dy2 = v[2].y - v[3].y;
det = DET (dx1, dx2, dy1, dy2);
if ((int) det == 0)
if (CLUTTER_NEARBYINT (det) == 0)
return FALSE;
RQ[0][2] = DET (px, dx2, py, dy2) / det;
@ -15229,7 +15229,7 @@ clutter_actor_transform_stage_point (ClutterActor *self,
det = (RQ[0][0] * ST[0][0])
+ (RQ[0][1] * ST[0][1])
+ (RQ[0][2] * ST[0][2]);
if ((int) det == 0)
if (CLUTTER_NEARBYINT (det) == 0)
return FALSE;
/*