Python Fu: Creating batch path loading and saving plugin. - 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: Python Fu: Creating batch path loading and saving plugin. (/Thread-Python-Fu-Creating-batch-path-loading-and-saving-plugin) |
Python Fu: Creating batch path loading and saving plugin. - JeBe - 10-31-2018 Hi, this is my first post and I hope it’s correctly written. My ability to write scripts in Python Fu is very restricted, I have no other knowledge of “general” programing. I did adjust a .py plugin so that my workflow in GIMP 2.8.22 under windows 10 is a bit faster. It’s an automated version of “color to alpha”, name and function is “black to alpha”. I would like to create a Plugin in Python Fu with interface: It should have PF_DIRNAME for the opening path, and one for the saving path. Opening path should load all (.tga) files in the interface directory path folder and its subfolders. For each subfolder and its (.tga) files it needs to make .xcf and save this based on the name of the folder and then the subfolder in a selected saving path. Example: folder name “Gimp” Subfolder name “01”= “Gimp01.xcf”, “Gimp01.xcf”, “Gimp02.xcf”, etc... “Gimp01.xcf” needs to contain the (.tga) files from the subfolder and loads the lowest file number in the highest in layer. Example: “image0000” and “image 0525” are in subfolder. “image0000” needs to be above “image0525” in the “Gimp01.xcf” For each image per .xcf it needs to run “black to alpha”. I hope this is possible with Python-Fu. And if I could get some guidance. JeBe RE: Python Fu: Creating batch path loading and saving plugin. - Ofnuts - 10-31-2018 Yes, it is doable. Steep learning curve if you need to learn both Python and Gimp scripting. Some hints:
RE: Python Fu: Creating batch path loading and saving plugin. - JeBe - 11-07-2018 Thanks for the advice, i am still a long way from creating my plugin, I did find your “Flatten visible layers group…” plugin and it’s saving me a lot of work. |