[gegl] map-{absolute,relative}: add abyss-policy property
- From: N/A <ell src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gegl] map-{absolute,relative}: add abyss-policy property
- Date: Fri, 19 May 2017 22:28:26 +0000 (UTC)
commit c1328588bad65002071da86f40e342756de1de77
Author: Ell <ell_se yahoo com>
Date: Fri May 19 13:56:00 2017 -0400
map-{absolute,relative}: add abyss-policy property
... which controls the abyss policy for the input buffer, instead
of a hardcoded NONE.
operations/common/map-absolute.c | 8 ++++++--
operations/common/map-relative.c | 8 ++++++--
2 files changed, 12 insertions(+), 4 deletions(-)
---
diff --git a/operations/common/map-absolute.c b/operations/common/map-absolute.c
index ce80a07..6b3abb9 100644
--- a/operations/common/map-absolute.c
+++ b/operations/common/map-absolute.c
@@ -23,6 +23,10 @@ property_enum (sampler_type, _("Resampling method"),
GeglSamplerType, gegl_sampler_type,
GEGL_SAMPLER_CUBIC)
+property_enum (abyss_policy, _("Abyss policy"),
+ GeglAbyssPolicy, gegl_abyss_policy,
+ GEGL_ABYSS_NONE)
+
#else
#define GEGL_OP_COMPOSER
@@ -84,7 +88,7 @@ process (GeglOperation *operation,
index_coords = gegl_buffer_iterator_add (it, aux, result, level, format_coords,
GEGL_ACCESS_READ, GEGL_ABYSS_NONE);
index_in = gegl_buffer_iterator_add (it, input, result, level, format_io,
- GEGL_ACCESS_READ, GEGL_ABYSS_NONE);
+ GEGL_ACCESS_READ, o->abyss_policy);
while (gegl_buffer_iterator_next (it))
{
@@ -108,7 +112,7 @@ process (GeglOperation *operation,
}
else
{
- gegl_sampler_get (sampler, coords[0], coords[1], NULL, out, GEGL_ABYSS_NONE);
+ gegl_sampler_get (sampler, coords[0], coords[1], NULL, out, o->abyss_policy);
}
coords += 2;
diff --git a/operations/common/map-relative.c b/operations/common/map-relative.c
index 6ad1963..74dac78 100644
--- a/operations/common/map-relative.c
+++ b/operations/common/map-relative.c
@@ -28,6 +28,10 @@ property_double (scaling, _("Scaling"), 1.0)
property_enum (sampler_type, _("Resampling method"),
GeglSamplerType, gegl_sampler_type, GEGL_SAMPLER_CUBIC)
+property_enum (abyss_policy, _("Abyss policy"),
+ GeglAbyssPolicy, gegl_abyss_policy,
+ GEGL_ABYSS_NONE)
+
#else
#define GEGL_OP_COMPOSER
@@ -88,7 +92,7 @@ process (GeglOperation *operation,
index_coords = gegl_buffer_iterator_add (it, aux, result, level, format_coords,
GEGL_ACCESS_READ, GEGL_ABYSS_NONE);
index_in = gegl_buffer_iterator_add (it, input, result, level, format_io,
- GEGL_ACCESS_READ, GEGL_ABYSS_NONE);
+ GEGL_ACCESS_READ, o->abyss_policy);
while (gegl_buffer_iterator_next (it))
{
@@ -117,7 +121,7 @@ process (GeglOperation *operation,
gegl_sampler_get (sampler, x + coords[0] * scaling + 0.5,
y + coords[1] * scaling + 0.5,
NULL, out,
- GEGL_ABYSS_NONE);
+ o->abyss_policy);
}
coords += 2;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]