A explanation of the buildup method in FDP

15 Nov 1997 - Raph Levien - raph@acm.org

I said in the brush architecture document that FDP's buildup modes are basically the same as using a multiply mode. Actually, things are a little more complicated.

As explained in the patent, the buildup mode is based on taking the logarithm of the existing pixel values, adding the dab linearly to these values, then taking the exponent to get back to pixel values.

If you weren't asleep in your algebra class, you'd realize that's basically the same as multiplying the dab into the pixel values. However, there is one subtlety: where the dab is partially opaque, it's really the paint color to the exponent of the brush mask. In short, the brush mask is being used as gamma, rather than as alpha.

In practice, the most relevant consequence is that the colors at the edge of a stroke tend to be a little more saturated with FDP's buildup method than with a plain multiply combine method.

It's not actually feasible to do it FDP's way, because that seems to be covered by their patent. But if the extra color saturation was considered important, it would be possible to write a buildup combine mode, similar to multiply except that the alpha channel is used as a gamma rather than alpha. It should even be reasonably efficient - you can store a 64k LUT containing all values of xy for 8-bit x and y.