No.  But it's there if anyone wants to.  I don't know how often swapping 16-bit samples is requested anyway.  There might be some other opportunities for speeding things up, like RGBA -> ARGB which could be done as a couple of 32-bit shifts, but would have to be done differently for little-endian and big-endian integers, so there's also opportunity for messing things up.

On Sun, Apr 6, 2014 at 7:02 PM, Bob Friesenhahn <> wrote:
On Sun, 6 Apr 2014, Glenn Randers-Pehrson wrote:

I forgot to put

      Optionally use  __builtin_bswap16() in png_do_swap()

Did you try timing the code with the option enabled to see what difference it makes (if any)?

Bob Friesenhahn,
GraphicsMagick Maintainer,


png-mng-implement mailing list