[gimp/soc-2009-dynamics] Remove the silly ratio limit from scale and just make sure that transformation result is at least 1p
- From: Alexia Death <alexiade src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gimp/soc-2009-dynamics] Remove the silly ratio limit from scale and just make sure that transformation result is at least 1p
- Date: Sun, 11 Oct 2009 07:57:21 +0000 (UTC)
commit 265687595378f93e39b603e3d0e0daf91fb20cd5
Author: Alexia Death <alexiadeath gmail com>
Date: Sun Oct 11 10:57:13 2009 +0300
Remove the silly ratio limit from scale and just make sure that transformation result is at least 1px
app/core/gimpbrush.c | 4 ++++
app/core/gimpdynamics.c | 5 +----
2 files changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/app/core/gimpbrush.c b/app/core/gimpbrush.c
index 90fa78d..8a7dc83 100644
--- a/app/core/gimpbrush.c
+++ b/app/core/gimpbrush.c
@@ -479,6 +479,10 @@ gimp_brush_transform_size (GimpBrush *brush,
}
GIMP_BRUSH_GET_CLASS (brush)->transform_size (brush, scale, aspect_ratio, angle, width, height);
+ /*Transform size can not be less than 1 px*/
+ width = MAX(1, width);
+ height = MAX(1, height);
+
}
TempBuf *
diff --git a/app/core/gimpdynamics.c b/app/core/gimpdynamics.c
index e0f39b7..5af55ae 100644
--- a/app/core/gimpdynamics.c
+++ b/app/core/gimpdynamics.c
@@ -1207,10 +1207,7 @@ gimp_dynamics_get_scale_output_val (GimpDynamicsOutput *output, GimpCoords coord
if (factors > 0)
scale = total / factors;
- if (scale < 1 / 64.0)
- scale = 1 / 8.0;
- else
- scale = sqrt (scale);
+ scale = sqrt (scale);
/* printf("Dynamics queried(scale). Result: %f, factors: %f, total: %f \n", result, factors, total);*/
return scale;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]