[clutter/msvc-support-master] test-picking.c: Use G_PI rather than M_PI



commit 2a54db4557a0e4b417535ef162590a414a8a3c5b
Author: Chun-wei Fan <fanchunwei src gnome org>
Date:   Tue Nov 15 16:29:35 2011 +0800

    test-picking.c: Use G_PI rather than M_PI
    
    M_PI is not universally available...

 tests/performance/test-picking.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/tests/performance/test-picking.c b/tests/performance/test-picking.c
index 3432166..af59600 100644
--- a/tests/performance/test-picking.c
+++ b/tests/performance/test-picking.c
@@ -40,9 +40,9 @@ do_events (ClutterActor *stage)
 
   for (i = 0; i < n_events; i++)
     {
-      angle += (2.0 * M_PI) / (gdouble)n_actors;
-      while (angle > M_PI * 2.0)
-        angle -= M_PI * 2.0;
+      angle += (2.0 * G_PI) / (gdouble)n_actors;
+      while (angle > G_PI * 2.0)
+        angle -= G_PI * 2.0;
 
       /* If we synthesized events, they would be motion compressed;
        * calling get_actor_at_position() doesn't have that problem
@@ -96,7 +96,7 @@ main (int argc, char **argv)
 
   for (i = n_actors - 1; i >= 0; i--)
     {
-      angle = ((2.0 * M_PI) / (gdouble) n_actors) * i;
+      angle = ((2.0 * G_PI) / (gdouble) n_actors) * i;
 
       color.red = (1.0 - ABS ((MAX (0, MIN (n_actors/2.0 + 0, i))) /
                   (gdouble)(n_actors/4.0) - 1.0)) * 255.0;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]