[gimp] Bug 567262 – Black pixels appear in "Spread" filter preview
- From: Sven Neumann <neo src gnome org>
- To: svn-commits-list gnome org
- Subject: [gimp] Bug 567262 – Black pixels appear in "Spread" filter preview
- Date: Tue,  7 Jul 2009 15:12:37 +0000 (UTC)
commit 34ccca92a5cdb273ec93dd94c3a91d7920384646
Author: Massimo Valentini <sixtysix inwind it>
Date:   Tue Jul 7 17:07:12 2009 +0200
    Bug 567262 â?? Black pixels appear in "Spread" filter preview
    
    The plug-in makes use of a GimpPixelFetcher to access the source image.
    And a GimpPixelFetcher in its default state only returns pixels inside
    the bounding box of the selection. Setting its edge-mode to whatever
    but GIMP_PIXEL_FETCHER_EDGE_NONE allows to read pixels outside of the
    selection.
 plug-ins/common/noise-spread.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/plug-ins/common/noise-spread.c b/plug-ins/common/noise-spread.c
index 54f73f5..74e70b7 100644
--- a/plug-ins/common/noise-spread.c
+++ b/plug-ins/common/noise-spread.c
@@ -272,6 +272,7 @@ spread (GimpDrawable *drawable)
   param.width    = drawable->width;
   param.height   = drawable->height;
 
+  gimp_pixel_fetcher_set_edge_mode(param.pft, GIMP_PIXEL_FETCHER_EDGE_BLACK);
   iter = gimp_rgn_iterator_new (drawable, 0);
   gimp_rgn_iterator_dest (iter, spread_func, ¶m);
   gimp_rgn_iterator_free (iter);
@@ -301,6 +302,7 @@ spread_preview_update (GimpPreview *preview,
                                                 1) + 1) / 2;
   param.width    = drawable->width;
   param.height   = drawable->height;
+  gimp_pixel_fetcher_set_edge_mode(param.pft, GIMP_PIXEL_FETCHER_EDGE_BLACK);
 
   gimp_preview_get_size (preview, &width, &height);
 
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]