mirror of
https://github.com/brl/mutter.git
synced 2025-04-25 03:09:39 +00:00
* clutter/clutter-fixed.c: (clutter_sinx):
Fix clutter_sinx for angles > CFX_2PI - CFX_ONE. Also add note to documentation about being able to use modulus with ClutterFixed
This commit is contained in:
parent
49c5c97dd8
commit
631277be44
@ -1,3 +1,9 @@
|
|||||||
|
2008-06-25 Chris Lord <chris@openedhand.com>
|
||||||
|
|
||||||
|
* clutter/clutter-fixed.c: (clutter_sinx):
|
||||||
|
Fix clutter_sinx for angles > CFX_2PI - CFX_ONE. Also add note to
|
||||||
|
documentation about being able to use modulus with ClutterFixed
|
||||||
|
|
||||||
2008-06-25 Emmanuele Bassi <ebassi@openedhand.com>
|
2008-06-25 Emmanuele Bassi <ebassi@openedhand.com>
|
||||||
|
|
||||||
* clutter/clutter-backend.h:
|
* clutter/clutter-backend.h:
|
||||||
|
@ -50,8 +50,8 @@
|
|||||||
*
|
*
|
||||||
* <itemizedlist>
|
* <itemizedlist>
|
||||||
* <listitem>
|
* <listitem>
|
||||||
* <para>Two fixed point numbers can be directly added and
|
* <para>Two fixed point numbers can be directly added,
|
||||||
* subtracted.</para>
|
* subtracted and have their modulus taken.</para>
|
||||||
* </listitem>
|
* </listitem>
|
||||||
* <listitem>
|
* <listitem>
|
||||||
* <para>To add other numerical type to a fixed point number it has to
|
* <para>To add other numerical type to a fixed point number it has to
|
||||||
@ -264,11 +264,7 @@ clutter_sinx (ClutterFixed angle)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* reduce to <0, 2*pi) */
|
/* reduce to <0, 2*pi) */
|
||||||
if (angle >= CFX_2PI)
|
angle = angle % CFX_2PI;
|
||||||
{
|
|
||||||
ClutterFixed f = CLUTTER_FIXED_DIV (angle, CFX_2PI);
|
|
||||||
angle = angle - f;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* reduce to first quadrant and sign */
|
/* reduce to first quadrant and sign */
|
||||||
if (angle > CFX_PI)
|
if (angle > CFX_PI)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user