[gimp] plug-ins: migrate psd plug-ins to new iterator api
- From: Øyvind "pippin" Kolås <ok src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] plug-ins: migrate psd plug-ins to new iterator api
- Date: Wed, 12 Sep 2018 11:55:17 +0000 (UTC)
commit 3a2014984d35377067a83e86465979d43a6a152d
Author: Øyvind Kolås <pippin gimp org>
Date: Tue Sep 11 02:02:50 2018 +0200
plug-ins: migrate psd plug-ins to new iterator api
plug-ins/file-psd/psd-load.c | 5 +++--
plug-ins/file-psd/psd-save.c | 5 +++--
2 files changed, 6 insertions(+), 4 deletions(-)
---
diff --git a/plug-ins/file-psd/psd-load.c b/plug-ins/file-psd/psd-load.c
index bab190a975..690321a145 100644
--- a/plug-ins/file-psd/psd-load.c
+++ b/plug-ins/file-psd/psd-load.c
@@ -18,6 +18,7 @@
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
+#define GEGL_ITERATOR2_API
#include "config.h"
#include <string.h>
@@ -1872,11 +1873,11 @@ add_merged_image (gint32 image_id,
iter = gegl_buffer_iterator_new (buffer, NULL, 0,
babl_format ("R'G'B'A float"),
GEGL_ACCESS_READWRITE,
- GEGL_ABYSS_NONE);
+ GEGL_ABYSS_NONE, 1);
while (gegl_buffer_iterator_next (iter))
{
- gfloat *data = iter->data[0];
+ gfloat *data = iter->items[0].data;
for (i = 0; i < iter->length; i++)
{
diff --git a/plug-ins/file-psd/psd-save.c b/plug-ins/file-psd/psd-save.c
index 1952d6cd5f..dc643ef96e 100644
--- a/plug-ins/file-psd/psd-save.c
+++ b/plug-ins/file-psd/psd-save.c
@@ -63,6 +63,7 @@
* BUGS:
*/
+#define GEGL_ITERATOR2_API
#include "config.h"
#include <errno.h>
@@ -1467,11 +1468,11 @@ create_merged_image (gint32 image_id)
GeglBufferIterator *iter;
iter = gegl_buffer_iterator_new (buffer, NULL, 0, format,
- GEGL_ACCESS_READWRITE, GEGL_ABYSS_NONE);
+ GEGL_ACCESS_READWRITE, GEGL_ABYSS_NONE, 1);
while (gegl_buffer_iterator_next (iter))
{
- guchar *d = iter->data[0];
+ guchar *d = iter->items[0].data;
gint i;
for (i = 0; i < iter->length; i++)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]