mplayer: remove unused mp_add_subtitles() parameter

This commit is contained in:
wm4 2013-09-07 20:19:57 +02:00
parent 8894a4b0d2
commit c4b935adf7
3 changed files with 6 additions and 6 deletions

View File

@ -2575,7 +2575,7 @@ void run_command(MPContext *mpctx, mp_cmd_t *cmd)
case MP_CMD_SUB_ADD:
if (sh_video) {
mp_add_subtitles(mpctx, cmd->args[0].v.s, 0);
mp_add_subtitles(mpctx, cmd->args[0].v.s);
}
break;
@ -2590,7 +2590,7 @@ void run_command(MPContext *mpctx, mp_cmd_t *cmd)
struct track *sub = mp_track_by_tid(mpctx, STREAM_SUB, cmd->args[0].v.i);
if (sh_video && sub && sub->is_external && sub->external_filename)
{
struct track *nsub = mp_add_subtitles(mpctx, sub->external_filename, 0);
struct track *nsub = mp_add_subtitles(mpctx, sub->external_filename);
if (nsub) {
mp_remove_track(mpctx, sub);
mp_switch_track(mpctx, nsub->type, nsub);

View File

@ -306,7 +306,7 @@ extern int forced_subs_only;
void uninit_player(struct MPContext *mpctx, unsigned int mask);
void reinit_audio_chain(struct MPContext *mpctx);
double playing_audio_pts(struct MPContext *mpctx);
struct track *mp_add_subtitles(struct MPContext *mpctx, char *filename, int noerr);
struct track *mp_add_subtitles(struct MPContext *mpctx, char *filename);
int reinit_video_chain(struct MPContext *mpctx);
int reinit_video_filters(struct MPContext *mpctx);
int reinit_audio_filters(struct MPContext *mpctx);

View File

@ -3951,13 +3951,13 @@ static void open_subtitles_from_options(struct MPContext *mpctx)
// check .sub
if (mpctx->opts->sub_name) {
for (int i = 0; mpctx->opts->sub_name[i] != NULL; ++i)
mp_add_subtitles(mpctx, mpctx->opts->sub_name[i], 0);
mp_add_subtitles(mpctx, mpctx->opts->sub_name[i]);
}
if (mpctx->opts->sub_auto) { // auto load sub file ...
char **tmp = find_text_subtitles(mpctx->opts, mpctx->filename);
int nsub = MP_TALLOC_ELEMS(tmp);
for (int i = 0; i < nsub; i++) {
struct track *track = mp_add_subtitles(mpctx, tmp[i], 1);
struct track *track = mp_add_subtitles(mpctx, tmp[i]);
if (track)
track->auto_loaded = true;
}
@ -4025,7 +4025,7 @@ static void open_audiofiles_from_options(struct MPContext *mpctx)
opts->audio_stream_cache, STREAM_AUDIO);
}
struct track *mp_add_subtitles(struct MPContext *mpctx, char *filename, int noerr)
struct track *mp_add_subtitles(struct MPContext *mpctx, char *filename)
{
struct MPOpts *opts = mpctx->opts;
return open_external_file(mpctx, filename, opts->sub_demuxer_name, 0,