[gegl] operations: motion-blur-circular talks in degrees



commit e8b91e9c09f3a9c2a931120d492b5d74e2efff92
Author: Téo Mazars <teo mazars ensimag fr>
Date:   Mon Jun 3 20:47:00 2013 +0200

    operations: motion-blur-circular talks in degrees
    
    clearer than 0..1

 operations/common/motion-blur-circular.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/operations/common/motion-blur-circular.c b/operations/common/motion-blur-circular.c
index 9ab82cc..12a459e 100644
--- a/operations/common/motion-blur-circular.c
+++ b/operations/common/motion-blur-circular.c
@@ -38,8 +38,8 @@ gegl_chant_double_ui (center_y, _("Y"),
                       _("Vertical center position"))
 
 gegl_chant_double_ui (angle, _("Angle"),
-                      0.0, 1.0, 0.02,
-                      0.0, 1.0, 2.0,
+                      0.0, 180.0, 5.0,
+                      0.0, 90.0, 2.0,
                       _("Rotation blur angle"))
 
 #else
@@ -61,7 +61,7 @@ prepare (GeglOperation *operation)
   GeglOperationAreaFilter *op_area = GEGL_OPERATION_AREA_FILTER (operation);
   GeglChantO              *o       = GEGL_CHANT_PROPERTIES (operation);
   GeglRectangle           *whole_region;
-  gdouble                  angle   = o->angle * G_PI;
+  gdouble                  angle   = o->angle * G_PI / 180.0;
 
   whole_region = gegl_operation_source_get_bounding_box (operation, "input");
 
@@ -159,7 +159,7 @@ process (GeglOperation       *operation,
   gegl_buffer_get (input, &src_rect, 1.0, babl_format ("RaGaBaA float"),
                    in_buf, GEGL_AUTO_ROWSTRIDE, GEGL_ABYSS_NONE);
 
-  angle = o->angle * G_PI;
+  angle = o->angle * G_PI / 180.0;
 
   for (y = roi->y; y < roi->height + roi->y; ++y)
     {


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