mirror of
https://github.com/mpv-player/mpv.git
synced 2026-10-28 23:13:18 +08:00
Old code for dvdsub_id fix assume the global_sub_indices[SUB_SOURCE_DEMUX]
must be zero when use a dvdsub_id greater than max sub id from demux. To remove the implicit assumption, make it up here. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24962 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
@@ -3019,7 +3019,9 @@ if (mpctx->stream->type != STREAMTYPE_DVD && mpctx->stream->type != STREAMTYPE_D
|
||||
maxid = FFMAX(maxid, ((sh_sub_t *)mpctx->demuxer->s_streams[i])->sid);
|
||||
mpctx->global_sub_size += maxid + 1;
|
||||
}
|
||||
if (mpctx->global_sub_size <= dvdsub_id) mpctx->global_sub_size = dvdsub_id + 1;
|
||||
// Make dvdsub_id always selectable if set.
|
||||
if (mpctx->global_sub_size <= mpctx->global_sub_indices[SUB_SOURCE_DEMUX] + dvdsub_id)
|
||||
mpctx->global_sub_size = mpctx->global_sub_indices[SUB_SOURCE_DEMUX] + dvdsub_id + 1;
|
||||
|
||||
current_module="demux_open2";
|
||||
|
||||
|
||||
Reference in New Issue
Block a user