[MPlayer-dev-eng] [PATCH] vo_tga: fix blue channel on little endian machines
Reimar Döffinger
Reimar.Doeffinger at gmx.de
Wed Jun 9 23:58:57 CEST 2010
On Wed, Jun 09, 2010 at 09:16:57PM +0200, Marton Balint wrote:
> + while (dy-- > 0) {
> + if (fwrite(buf, wb, 1, fo) != 1) {
> + er = 4;
> + break;
> }
> -
> + buf += stride;
> }
> - else {
> - while (dy-- > 0) {
> - if (fwrite(buf, wb, 1, fo) != 1) {
> - er = 4;
> - break;
> - }
> - buf += stride;
Please don't change indentation, it's easier to check for mistakes without it
and then fix the indentation later.
> @@ -236,7 +196,11 @@
> switch(format){
> case IMGFMT_BGR|15:
> case IMGFMT_BGR|24:
> - case IMGFMT_BGR|32:
> + #if HAVE_BIGENDIAN
> + case IMGFMT_ARGB:
> + #else
> + case IMGFMT_BGRA:
> + #endif
That's just a more complicated way of writing the same thing actually,
so this part should be unnecessary.
More information about the MPlayer-dev-eng
mailing list