Extending RawTherapee (new module) - support for IR channel of scanned negatives (digital ICE)

Hi,
I’ve been using RT for some time as my main negative film processing software. I scan my negatives with vuescan and save the “raw” tiffs which are processed with the “Film Negative” module on RT.
What I’ve looking for is to be able to process the extra data produced by “digital ICE” capable scanners in order to correct the image for dust and scratches. Basically the scanner performs the RGB scan and then an IR scan. The resulting file is a 64-bit (RGB + IR channel). While RT can process the negative into a positive, this extra channel is not used. What I’ve done instead is to write a python script which takes the raw (negative) and processed file (positive) obtained from RT in order to take the IR channel information from the RAW file and apply it to the processed file to do dust/scratch removal.
The algorithm is mostly thresholding the IR channel, performing some filtering and x/y alignment. From this I create a binary mask which I feed into OpenCV’s inpaint() method, which works quite well.

So, my question is basically if:
a) is it possible to write a plugin for RT somehow to add a new module which performs the dust cleaning? A python API to add modules would be ideal, but I imagine that would be quite an undertaking.
b) or should I aim to extend RT Film Negative module directly?

Thanks!

I had no idea what “digital ICE” is, so for anyone in the same boat, - Digital ICE - Wikipedia

1 Like

I would love to see a module in darktable, RawTherapee or GIMP that could handle the dust removal option from my Epson Perfection V850. The Epson software and Silverfast are both disappointing.

RawTherapee doesn’t have a plugin system, so you’ll have to add it directly.

Any hints on where should I point this feature?