1
0
mirror of https://github.com/mpv-player/mpv synced 2024-12-18 12:55:16 +00:00

Native MPEG4 SP/ASP/AP support in Matroska.

Patch by Aurelien Jacobs and myself.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@19159 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
rathann 2006-07-22 14:35:49 +00:00
parent c4d02071c2
commit 02362913a7
2 changed files with 16 additions and 0 deletions

View File

@ -1825,6 +1825,19 @@ demux_mkv_open_video (demuxer_t *demuxer, mkv_track_t *track)
bih->biCompression = mmioFOURCC('m', 'p', 'g', '2'); bih->biCompression = mmioFOURCC('m', 'p', 'g', '2');
track->reorder_timecodes = !correct_pts; track->reorder_timecodes = !correct_pts;
} }
else if (!strcmp(track->codec_id, MKV_V_MPEG4_SP) ||
!strcmp(track->codec_id, MKV_V_MPEG4_ASP) ||
!strcmp(track->codec_id, MKV_V_MPEG4_AP))
{
bih->biCompression = mmioFOURCC('m', 'p', '4', 'v');
if (track->private_data && (track->private_size > 0))
{
bih->biSize += track->private_size;
bih = (BITMAPINFOHEADER *) realloc (bih, bih->biSize);
memcpy (bih + 1, track->private_data, track->private_size);
}
track->reorder_timecodes = !correct_pts;
}
else if (!strcmp(track->codec_id, MKV_V_MPEG4_AVC)) else if (!strcmp(track->codec_id, MKV_V_MPEG4_AVC))
{ {
bih->biCompression = mmioFOURCC('a', 'v', 'c', '1'); bih->biCompression = mmioFOURCC('a', 'v', 'c', '1');

View File

@ -48,6 +48,9 @@
#define MKV_V_QUICKTIME "V_QUICKTIME" #define MKV_V_QUICKTIME "V_QUICKTIME"
#define MKV_V_MPEG1 "V_MPEG1" #define MKV_V_MPEG1 "V_MPEG1"
#define MKV_V_MPEG2 "V_MPEG2" #define MKV_V_MPEG2 "V_MPEG2"
#define MKV_V_MPEG4_SP "V_MPEG4/ISO/SP"
#define MKV_V_MPEG4_ASP "V_MPEG4/ISO/ASP"
#define MKV_V_MPEG4_AP "V_MPEG4/ISO/AP"
#define MKV_V_MPEG4_AVC "V_MPEG4/ISO/AVC" #define MKV_V_MPEG4_AVC "V_MPEG4/ISO/AVC"
#define MKV_S_TEXTASCII "S_TEXT/ASCII" #define MKV_S_TEXTASCII "S_TEXT/ASCII"