Post

I've been working on a Kotlin/Compose Multiplatform to interpolate sRGB colors as mixtures of paints/pigments. It can produce results that are more appealing than the traditional sRGB interpolation that Composes uses (see screenshot). Not quite ready for release yet. github.com/romainguy/vi...

The implementation is based on the extended Kubelka-Munk theory, using a fixed paint layer thickness and a fixed substrate reflectance. The latent space is based on the great paper Practical Pigment Mixing for Digital Painting. The main difference is that my implementation uses two small MLPs.

The first neural net is used to avoid using a ~50 MiB 3D LUT. The second one encodes the spectral integration and is more precise than a polynomial fit. I get excellent performance results on 5 years old Pixel phone. Still need to tweak the training though.

Bluesky is ruining my nicely dithered gradients πŸ˜…

0 reposts6 likes

No replies yet.