Gimp-Forum.net
Script-Fu: gimp-image-convert-precision - Printable Version

+- Gimp-Forum.net (https://www.gimp-forum.net)
+-- Forum: GIMP (https://www.gimp-forum.net/Forum-GIMP)
+--- Forum: Extending the GIMP (https://www.gimp-forum.net/Forum-Extending-the-GIMP)
+---- Forum: Scripting questions (https://www.gimp-forum.net/Forum-Scripting-questions)
+---- Thread: Script-Fu: gimp-image-convert-precision (/Thread-Script-Fu-gimp-image-convert-precision)



Script-Fu: gimp-image-convert-precision - Marcel - 07-30-2018

Hey guys,

is it possible to enable dithering when reducing the image's color precision with
Code:
gimp-image-convert-precision
in Script-Fu?

Image → Precision offers such an option.


RE: Script-Fu: gimp-image-convert-precision - Ofnuts - 07-30-2018

(07-30-2018, 10:46 AM)Marcel Wrote: Hey guys,

is it possible to enable dithering when reducing the image's color precision with
Code:
gimp-image-convert-precision
in Script-Fu?

Image → Precision offers such an option.

I don't see any API for this either. I see these options in Edit>Preferences>Interface>Dialog defaults which leads me to think that if these options existed, they would be in the "context".  There are missing values in the context (for instance, the Fade length), so these could be missing as well.

PS: still using Script-fu? Do you know you can use Python?


RE: Script-Fu: gimp-image-convert-precision - Marcel - 07-30-2018

Thanks for your reply. Actually I didn't realize python to be an option Big Grin Generally I would much prefer python over scheme's rather quirky syntax.

As far as my initial question is concerned, GIMP's API does not seem to differ between the two scripting languages.


I've issued a bug report on this.


RE: Script-Fu: gimp-image-convert-precision - Ofnuts - 07-30-2018

(07-30-2018, 12:20 PM)Marcel Wrote: As far as my initial question is concerned, GIMP's API does not seem to differ between the two scripting languages.

Actually it does, you can do more thing in Python, like having a direct access to the pixel values.


RE: Script-Fu: gimp-image-convert-precision - Marcel - 08-03-2018

Quote: [...] like having a direct access to the pixel values.

I didn't know that. Thank you for pointing that out. Might come in quite handy. Smile