[gimp/gimp-2-10] plug-ins: migrate screenshot-x11 to new iterator api



commit a5bbf913a49c4cced66394b5ee1e47e9becba48e
Author: Øyvind Kolås <pippin gimp org>
Date:   Tue Sep 11 02:05:13 2018 +0200

    plug-ins: migrate screenshot-x11 to new iterator api
    
    (cherry picked from commit cc10af72ccdd6c916fcb52407670c22aa32a1ae9)

 plug-ins/screenshot/screenshot-x11.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/plug-ins/screenshot/screenshot-x11.c b/plug-ins/screenshot/screenshot-x11.c
index 0cf8253742..d6f5d74248 100644
--- a/plug-ins/screenshot/screenshot-x11.c
+++ b/plug-ins/screenshot/screenshot-x11.c
@@ -20,6 +20,7 @@
  * along with this program.  If not, see <https://www.gnu.org/licenses/>.
  */
 
+#define GEGL_ITERATOR2_API
 #include "config.h"
 
 #include <libgimp/gimp.h>
@@ -475,13 +476,13 @@ add_cursor_image (gint32      image,
                                                    gimp_drawable_width  (layer),
                                                    gimp_drawable_height (layer)),
                                    0, babl_format ("R'G'B'A u8"),
-                                   GEGL_ACCESS_READWRITE, GEGL_ABYSS_NONE);
-  roi = &iter->roi[0];
+                                   GEGL_ACCESS_READWRITE, GEGL_ABYSS_NONE, 1);
+  roi = &iter->items[0].roi;
 
   while (gegl_buffer_iterator_next (iter))
     {
       const gulong *src  = cursor->pixels + roi->y * cursor->width + roi->x;
-      guchar       *dest = iter->data[0];
+      guchar       *dest = iter->items[0].data;
       gint          x, y;
 
       for (y = 0; y < roi->height; y++)


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