openexr/openexr — pull request #143 by karlrasche (2014-11-20 16:39:41+00:00)
Title: Wrong zig-zag ordering used for DWAx decode optimization

When decoding DWAx, there's an optimization which looks at the position of the last non-zero AC component coming from the RLE decoder. From that, we can tell that certain rows of the block are all zero, and choose a suitable inverse DCT implementation.

Somewhere along the line, I wrote down the wrong zig-zag order and used that to derive the logic of which rows are all zero. Instead of a zig-zag, I had used a 'diagonal stripe' order.

This fixes the ordering, both in the logic and the explanation comment.

The visual impact is not very much, which probably explains why this problem has lurked for a long time without being called out.