Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Dithering Script-Fu
#1
I'm using GIMP 2.10.6 on Ubuntu 18.10.  
I'm trying to script an automatic image manipulation, and for part of the workflow I need to dither a layer in my image.

I can't find anything that exposes the functionality provided by the dialogue located at Colors > Dither...
[Image: IkRkuYe.png]

Am I missing something?  Or does it just not exist?
Reply
#2
You're right : currently there is no way to call the dither filter from the API.
Reply
#3
Go to Help, Search and Run a Command (/), and click "dither".
You will get access
Reply
#4
(06-22-2019, 05:29 AM)dinasset Wrote: Go to Help, Search and Run a Command (/), and click "dither".
You will get access

We are in the "Scripting questions" section here.
Reply
#5
GEGL operation so not yet scriptable.

There is a script-fu dither16.scm with pre-set options but then it depends how much colour reduction is required.

A couple of quick tests & the script option ARGB4444 is roughly equivalent to the GEGL filter with RGB values = 15

Maybe you can take the principles and incorporate in your plugin.


Attached Files
.zip   dither16.zip (Size: 3.34 KB / Downloads: 232)
Reply


Forum Jump: