Not sure about RawTherapee’s implementation but retinex
has been around for a long time. There is no shortage of literature on the topic.
- Color constancy - Wikipedia
- IPOL Journal · Multiscale Retinex
- Fred's ImageMagick Scripts: RETINEX
- http://docs.opencv.org/3.2.0/d2/d94/bioinspired_retina.html
- And refer to citations or do a web search…