Mercurial > libavcodec.hg
changeset 11404:a744eb5328b2 libavcodec
targeenc: fix rgb555 encoding on big endian systems.
Patch by Alexis Ballier gmail_address(name, surname)
author | benoit |
---|---|
date | Mon, 08 Mar 2010 08:43:20 +0000 |
parents | 128f82b41fc1 |
children | 8de15f200be8 |
files | targaenc.c |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/targaenc.c Mon Mar 08 06:52:33 2010 +0000 +++ b/targaenc.c Mon Mar 08 08:43:20 2010 +0000 @@ -104,7 +104,7 @@ outbuf[2] = 3; /* uncompressed grayscale image */ outbuf[16] = 8; /* bpp */ break; - case PIX_FMT_RGB555: + case PIX_FMT_RGB555LE: outbuf[2] = 2; /* uncompresses true-color image */ outbuf[16] = 16; /* bpp */ break; @@ -158,6 +158,6 @@ .priv_data_size = sizeof(TargaContext), .init = targa_encode_init, .encode = targa_encode_frame, - .pix_fmts= (const enum PixelFormat[]){PIX_FMT_BGR24, PIX_FMT_RGB555, PIX_FMT_GRAY8, PIX_FMT_NONE}, + .pix_fmts= (const enum PixelFormat[]){PIX_FMT_BGR24, PIX_FMT_RGB555LE, PIX_FMT_GRAY8, PIX_FMT_NONE}, .long_name= NULL_IF_CONFIG_SMALL("Truevision Targa image"), };