diff options
author | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2008-04-05 08:49:07 +0000 |
---|---|---|
committer | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2008-04-05 08:49:07 +0000 |
commit | 75535bba65e49f712bd95e6be5310411ebf2e2eb (patch) | |
tree | 25549728c1ea291c10e37a69cfd4a7e97d659d3e /libmpdemux | |
parent | e20c28296b6227cf6d94e62bd48bbe1dc6b3ce48 (diff) |
Set correct codec tag for raw rgb in mov, fixes
http://samples.mplayerhq.hu/mov/rawbgr24.mov
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26326 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux')
-rw-r--r-- | libmpdemux/demux_lavf.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/libmpdemux/demux_lavf.c b/libmpdemux/demux_lavf.c index dfa39bfb18..0b243cdd18 100644 --- a/libmpdemux/demux_lavf.c +++ b/libmpdemux/demux_lavf.c @@ -360,6 +360,12 @@ static void handle_stream(demuxer_t *demuxer, AVFormatContext *avfc, int i) { priv->video_streams++; bih=calloc(sizeof(BITMAPINFOHEADER) + codec->extradata_size,1); + if(codec->codec_id == CODEC_ID_RAWVIDEO) { + switch (codec->pix_fmt) { + case PIX_FMT_RGB24: + codec->codec_tag= MKTAG(24, 'B', 'G', 'R'); + } + } if(!codec->codec_tag) codec->codec_tag= av_codec_get_tag(mp_bmp_taglists, codec->codec_id); bih->biSize= sizeof(BITMAPINFOHEADER) + codec->extradata_size; |