animationUpscaler

Enlarges animation with a small neural network trained on line art and flat colour, which is what a photographic kernel renders soft.

It runs only where the picture is drawn at more than 1.2 times its own size on both axes, which is the network's own rule: below that it would cost every frame and change little. It doubles the picture, and scaler then takes the doubled picture the rest of the way, up or down, so the two compose rather than compete. It works on the transfer curve's code values, which is what the network was trained on, so linearLight reaches only that second step. Debanding runs before it, on the source, where the bands are.

The intermediate pictures are half-float textures at the source's size, and the doubled picture is one more at twice that size, so this costs memory as well as time: about 50 MB for a 720p film with AnimationUpscaler.Fast, and several times that for 1080p with AnimationUpscaler.Quality. A GPU that cannot render to half floats skips it.

The Android GPU renderer runs it. The Metal renderer ignores it until #421.