diff options
author | Alexis Ballier <alexis.ballier@gmail.com> | 2010-03-08 11:43:20 +0300 |
---|---|---|
committer | Benoit Fouet <benoit.fouet@free.fr> | 2010-03-08 11:43:20 +0300 |
commit | da5bcafe3b728f255ad068fc406622515b435082 (patch) | |
tree | 43da9fc3d36e4c883d8a90fe7f520b6b3355cc72 /libavcodec/targaenc.c | |
parent | b5852e8a4d5c7f1069f1f113d384aab2a7950d04 (diff) |
targeenc: fix rgb555 encoding on big endian systems.
Patch by Alexis Ballier gmail_address(name, surname)
Originally committed as revision 22320 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/targaenc.c')
-rw-r--r-- | libavcodec/targaenc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/targaenc.c b/libavcodec/targaenc.c index 82d7fe3599..fa886755c1 100644 --- a/libavcodec/targaenc.c +++ b/libavcodec/targaenc.c @@ -104,7 +104,7 @@ static int targa_encode_frame(AVCodecContext *avctx, 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 @@ AVCodec targa_encoder = { .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"), }; |