Adding tRNS chunk transparency option to the PNG save dialogue
I'm working on a project that involves creating many thousands of PNG images with transparency. I've had to add multiple plugins so that the GIMP gui can perform operations on all layers, so that the full power of GIMP's image processing tools can be used on videos that have been disassembled into frames. I made a tongue-in-cheek joke on Reddit about a missing feature and somebody said I should post it here.
My problem is that I want to produce a video with transparent frames. Currently I'm using a Color to Alpha (All Layers) plugin which also adds a transparency channel, to smoothly convert black to transparent, then a Export Layers (Repeat) plugin to batch export. Adding an alpha channel converts the image to a 32-bit PNG which bloats the filesize, plus the import-convert-export steps take a lot of time. In the PNG specification (http://www.libpng.org/pub/png/spec/1.2/PNG-Chunks.html) there are several methods in which transparency can be represented, and GIMP has little to no control over these options. In particular the method I am hoping to see is the 'tRNS' chunk, which is a quick and fast way to add transparency to a PNG. Basically it tells the image viewing program that a certain color represents transparent, allowing you to quickly and easily flip a bit to convert black- or white-background images to transparent, with very little processing involved. This provides transparency to 24-bit or lower PNG's and facilitates the creation of APNG's and compositing, by reducing memory footprint and processing overhead.
I'm not a coder, just an end user with an advanced feature request. My hope is that in the PNG save dialogue, a couple more options could be added for finer control over file output. I think this will streamline the change nicely without breaking anybody's workspace as far as I'm aware. I'm fairly certain it would work well with the Export All Layers plugin that I'm using because it seems to use the built-in save feature.