[gegl] operations: plasma.c uses gegl_chant_seed for the random seed
- From: Téo Mazars <teom src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gegl] operations: plasma.c uses gegl_chant_seed for the random seed
- Date: Tue, 8 Oct 2013 06:57:59 +0000 (UTC)
commit c7b6782a0e1cb305bc70452a4e9d8f51576517ee
Author: Téo Mazars <teo mazars ensimag fr>
Date: Tue Oct 8 08:54:10 2013 +0200
operations: plasma.c uses gegl_chant_seed for the random seed
... instead of gegl_chant_int
operations/common/plasma.c | 10 +++-------
1 files changed, 3 insertions(+), 7 deletions(-)
---
diff --git a/operations/common/plasma.c b/operations/common/plasma.c
index b62b452..24d5f25 100644
--- a/operations/common/plasma.c
+++ b/operations/common/plasma.c
@@ -33,9 +33,8 @@
#ifdef GEGL_CHANT_PROPERTIES
-gegl_chant_int (seed, _("Seed"), -1, G_MAXINT, -1,
- _("Random seed. "
- "Passing -1 implies that the seed is randomly chosen."))
+gegl_chant_seed (seed, _("Random seed"), _("Random seed"))
+
gegl_chant_double (turbulence, _("Turbulence"), 0.0, 7.0, 1.0,
_("The value of the turbulence"))
@@ -337,10 +336,7 @@ process (GeglOperation *operation,
x = result->x + result->width;
y = result->y + result->height;
- if (context->o->seed == -1)
- context->gr = g_rand_new ();
- else
- context->gr = g_rand_new_with_seed (context->o->seed);
+ context->gr = g_rand_new_with_seed (context->o->seed);
do_plasma (context, result->x, result->y, x-1, y-1, -1, 0);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]