zrle: Fix endianness

tight-png
Andri Yngvason 2019-09-08 14:41:22 +00:00
parent 66498bccf8
commit 2e359e734d
1 changed files with 3 additions and 3 deletions

View File

@ -124,9 +124,9 @@ void pixel32_to_cpixel(uint8_t *restrict dst,
CONVERT_PIXELS(cpx, px) CONVERT_PIXELS(cpx, px)
*dst++ = (cpx >> (0 ^ dst_endian_correction)) & 0xff;
*dst++ = (cpx >> 8) & 0xff;
*dst++ = (cpx >> (16 ^ dst_endian_correction)) & 0xff; *dst++ = (cpx >> (16 ^ dst_endian_correction)) & 0xff;
*dst++ = (cpx >> 8) & 0xff;
*dst++ = (cpx >> (0 ^ dst_endian_correction)) & 0xff;
} }
break; break;
case 2: case 2:
@ -137,8 +137,8 @@ void pixel32_to_cpixel(uint8_t *restrict dst,
CONVERT_PIXELS(cpx, px) CONVERT_PIXELS(cpx, px)
*dst++ = (cpx >> (0 ^ dst_endian_correction)) & 0xff;
*dst++ = (cpx >> (8 ^ dst_endian_correction)) & 0xff; *dst++ = (cpx >> (8 ^ dst_endian_correction)) & 0xff;
*dst++ = (cpx >> (0 ^ dst_endian_correction)) & 0xff;
} }
break; break;
case 1: case 1: