mirror of
https://gitlab.gnome.org/GNOME/gimp.git
synced 2025-07-03 17:33:25 +00:00
plug-ins: migrate screenshot-x11 to new iterator api
This commit is contained in:
parent
49c53568d7
commit
cc10af72cc
1 changed files with 4 additions and 3 deletions
|
@ -20,6 +20,7 @@
|
||||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#define GEGL_ITERATOR2_API
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
|
||||||
#include <libgimp/gimp.h>
|
#include <libgimp/gimp.h>
|
||||||
|
@ -478,13 +479,13 @@ add_cursor_image (gint32 image,
|
||||||
gimp_drawable_width (layer),
|
gimp_drawable_width (layer),
|
||||||
gimp_drawable_height (layer)),
|
gimp_drawable_height (layer)),
|
||||||
0, babl_format ("R'G'B'A u8"),
|
0, babl_format ("R'G'B'A u8"),
|
||||||
GEGL_ACCESS_READWRITE, GEGL_ABYSS_NONE);
|
GEGL_ACCESS_READWRITE, GEGL_ABYSS_NONE, 1);
|
||||||
roi = &iter->roi[0];
|
roi = &iter->items[0].roi;
|
||||||
|
|
||||||
while (gegl_buffer_iterator_next (iter))
|
while (gegl_buffer_iterator_next (iter))
|
||||||
{
|
{
|
||||||
const gulong *src = cursor->pixels + roi->y * cursor->width + roi->x;
|
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;
|
gint x, y;
|
||||||
|
|
||||||
for (y = 0; y < roi->height; y++)
|
for (y = 0; y < roi->height; y++)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue