It is currently 05 Mar 2021, 13:04

• Featuring Members' Works (Image Attachments) •
1: member
2: member
3: member
4: member
5: member

GIMP/GL:  Tutorials | Tips | Questions | Interests | Script Requests
Recommendations:  Index | Top 10
Resources:  🡆 Python-Fu Plug-ins | Scheme-Fu Scripts | GIMP
Python:  Lessons | Questions | Exercises
The Arts:  GIMPed | GIMPed Photos | Other | Contests | Public Domain Images | Isolated Images | Blender
Inkscape
Social:  Say Hello | Anything Goes | Shares | FCSP

Script to invert colors on many files

Share your Python Fu Scripts/plug-ins for GIMP here
Merlin72875
Newly Registered

Script to invert colors on many files

Post#1 by Merlin72875 » 21 Oct 2020, 00:39


I've got a church project where I need to invert colors on several hundred (maybe thousands?) of files.
They are lyric slides that are currently Black on White but I need them to be White on Black.
My current workflow is to open 10 files (one song) and tab through going Color -> Invert, then File -> Overwrite Slide1.png
Is this easily scriptable?

Thanks!
GIMP Learn rocks...

rich2005
GIMP Guru

Post#2 by rich2005 » 21 Oct 2020, 11:00


Must stop visiting this forum, always something that catches the eye ;)

There is already a script that inverts colours and can be used on multiple layers. The script comes from here: https://www.deviantart.com/fence-post/a ... -154242938 but a pain since deviantart started require registration, so the script is attached.

Are these greyscale images ? The script should work with your present work-flow but if you have thousands then you need the Gimp batch processor BIMP. https://alessandrofrancesconi.it/projects/bimp/

BIMP would use 'Other Gimp Procedure' as the input. A (partial) search for 'invert' will get the required script, add your image folder, set an output folder (you can overwrite but that is never a good idea). Several thousand images? Go for a walk around the block.
bimp.jpg
bimp.jpg # (89.69 KiB) Viewed 1227 times (Thumbnail | Recognize)
Attachments
fp-script-fu-color-invert-all.scm #
(1.49 KiB) Downloaded 45 times

tim
GL Blogger

Post#3 by tim » 21 Oct 2020, 15:16


rich2005 wrote:
21 Oct 2020, 11:00
Must stop visiting this forum, always something that catches the eye ;)
I am sure many people appreciate your help! :cool:
aka Tin

         


GIMP/GL:  Tutorials | Tips | Questions | Interests | Script Requests
Recommendations:  Index | Top 10
Resources:  🡆 Python-Fu Plug-ins | Scheme-Fu Scripts | GIMP
Python:  Lessons | Questions | Exercises
The Arts:  GIMPed | GIMPed Photos | Other | Contests | Public Domain Images | Isolated Images | Blender
Inkscape
Social:  Say Hello | Anything Goes | Shares | FCSP

Post Reply New Topic
  • Similar Topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: skinnyhouse and 22 guests