mirror of https://github.com/mpv-player/mpv
timecode scale value must be initialized before the duration is found. API change of libmatroska 0.4.2. Will not work with 0.4.1!
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@10085 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
b919d578df
commit
03b3f89ef7
|
@ -964,6 +964,8 @@ extern "C" int demux_mkv_open(demuxer_t *demuxer) {
|
|||
// General info about this Matroska file
|
||||
mp_msg(MSGT_DEMUX, MSGL_V, "[mkv] |+ segment information...\n");
|
||||
|
||||
mkv_d->tc_scale = MKVD_TIMECODESCALE;
|
||||
|
||||
l2 = es->FindNextElement(l1->Generic().Context, upper_lvl_el,
|
||||
0xFFFFFFFFL, true, 1);
|
||||
while (l2 != NULL) {
|
||||
|
@ -995,9 +997,6 @@ extern "C" int demux_mkv_open(demuxer_t *demuxer) {
|
|||
0xFFFFFFFFL, true, 1);
|
||||
}
|
||||
|
||||
if (mkv_d->tc_scale == 0)
|
||||
mkv_d->tc_scale = MKVD_TIMECODESCALE;
|
||||
|
||||
} else if (EbmlId(*l1) == KaxTracks::ClassInfos.GlobalId) {
|
||||
// Yep, we've found our KaxTracks element. Now find all tracks
|
||||
// contained in this segment.
|
||||
|
@ -1665,8 +1664,8 @@ extern "C" int demux_mkv_fill_buffer(demuxer_t *d) {
|
|||
|
||||
if (EbmlId(*l3) == KaxBlock::ClassInfos.GlobalId) {
|
||||
block = static_cast<KaxBlock *>(l3);
|
||||
block->SetParent(*mkv_d->cluster);
|
||||
block->ReadData(es->I_O());
|
||||
block->SetParent(*mkv_d->cluster);
|
||||
delete_element = 0;
|
||||
elements_found |= 1;
|
||||
|
||||
|
|
Loading…
Reference in New Issue