From 5b4b51ba7ae69285b74b0c8422a33cbafd234fc1 Mon Sep 17 00:00:00 2001 From: Tomas Frydrych Date: Mon, 1 Oct 2007 15:26:09 +0000 Subject: [PATCH] 2007-10-01 Tomas Frydrych * clutter/clutter-actor.c: (clutter_actor_set_scale_with_gravityx): Use CLUTTER_QMUL for better precission (#532, patch by Gwenole Beauchesne). * clutter/clutter-color.c: (clutter_color_to_hlsx): Added missing CLUTTER_INT_TO_FIXED conversion (#544, patch by Neil Roberts). --- ChangeLog | 12 ++++++++++++ clutter/clutter-actor.c | 8 ++++---- clutter/clutter-color.c | 2 +- 3 files changed, 17 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 4854344..274113e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,15 @@ +2007-10-01 Tomas Frydrych + + * clutter/clutter-actor.c: + (clutter_actor_set_scale_with_gravityx): + Use CLUTTER_QMUL for better precission (#532, patch by Gwenole + Beauchesne). + + * clutter/clutter-color.c: + (clutter_color_to_hlsx): + Added missing CLUTTER_INT_TO_FIXED conversion (#544, patch by Neil + Roberts). + 2007-10-01 Neil J. Patel Patch by: Tommi Komulainen diff --git a/clutter/clutter-actor.c b/clutter/clutter-actor.c index cf84eea..a69d960 100644 --- a/clutter/clutter-actor.c +++ b/clutter/clutter-actor.c @@ -2085,10 +2085,10 @@ clutter_actor_set_scale_with_gravityx (ClutterActor *self, clutter_actor_query_coords (self, &box); - w = CFX_MUL (box.x2 - box.x1, old_scale_x); - h = CFX_MUL (box.y2 - box.y1, old_scale_y); - sw = CFX_MUL (box.x2 - box.x1, scale_x); - sh = CFX_MUL (box.y2 - box.y1, scale_y); + w = CFX_QMUL (box.x2 - box.x1, old_scale_x); + h = CFX_QMUL (box.y2 - box.y1, old_scale_y); + sw = CFX_QMUL (box.x2 - box.x1, scale_x); + sh = CFX_QMUL (box.y2 - box.y1, scale_y); x = box.x1; diff --git a/clutter/clutter-color.c b/clutter/clutter-color.c index 3218ca6..17219a9 100644 --- a/clutter/clutter-color.c +++ b/clutter/clutter-color.c @@ -189,7 +189,7 @@ clutter_color_to_hlsx (const ClutterColor *src, if (l <= CFX_ONE/2) s = CFX_DIV ((max - min), (max + min)); else - s = CFX_DIV ((max - min), (2 - max - min)); + s = CFX_DIV ((max - min), (CLUTTER_INT_TO_FIXED (2) - max - min)); delta = max - min; if (red == max) -- 2.7.4