On Fri, Nov 8, 2019 at 7:53 PM Liam R E Quin <liam@xxxxxxxxxxx> wrote: > On Fri, 2019-11-08 at 18:40 -0800, Dan Hitt via gimp-developer-list > wrote: > > But i don't > > see > > how you can mark an image as dirty. > > Write some data to the image? > > E.g. read a pixel and write it back again? > > > I'm using gimp 2.10.8 on debian 10. > You might want to update to 2.10.14. the current version. > > slave ankh > > -- > Liam Quin - web slave for https://www.fromoldbooks.org/ > with fabulous vintage art and fascinating texts to read. > Hi Liam, Thanks for your mail. Your method sounds like it should work, and i absolutely have to be able to read and write pixels in order for my plugin to do what i want. Now, for the limited purpose of just having the image show up as dirty when metadata is written as a parasite, i eventually discovered that it suffices to pass in the flag GIMP_PARASITE_UNDOABLE in when the parasite is created by gimp_parasite_new(....). And the comments in the internals (gimpimage.c) advise you to never call (in all caps) gimp_image_dirty() directly, and that instead, push an undo operation on the stack. It makes sense i guess, and certainly explains why there seems to be no external interface to directly set the image dirty. So that leaves me with two holes. One is that although i've declared my parasite to be undoable, i haven't provided any means to actually undo it. So that's kind of bad, although the parasite info is not the main event that i hope to do in my plugin. The other hole is that i find that so far i cannot read and write a pixel. The obvious looking calls, for example, as used in the basic tutorial https://developer.gimp.org/writing-a-plug-in/2/index.html, are now marked deprecated. So to properly do this simple operation of reading and writing a pixel, one should go through the gegl interface. That i have not done, but obviously i need to. Anyhow, thanks again for your help, and if you or anybody knows of some easy tutorials on using the gegl apparatus, please let me know and tia. (And glad you get to mess around with scanning and enjoying old books --- the mustiness may not be so great, but it sounds like a great way to be in touch with your roots!) dan _______________________________________________ gimp-developer-list mailing list List address: gimp-developer-list@xxxxxxxxx List membership: https://mail.gnome.org/mailman/listinfo/gimp-developer-list List archives: https://mail.gnome.org/archives/gimp-developer-list