mirror of
https://github.com/mpv-player/mpv
synced 2025-01-20 14:20:55 +00:00
show subtitle language in OSD ; patch by Otvos Attila
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21577 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
a59ebe0c2d
commit
6c985e22b4
13
mplayer.c
13
mplayer.c
@ -2240,6 +2240,19 @@ static int mp_property_sub(m_option_t* prop,int action,void* arg) {
|
||||
strlen(tmp) < 20 ? tmp : tmp+strlen(tmp)-19);
|
||||
return M_PROPERTY_OK;
|
||||
}
|
||||
|
||||
#ifdef USE_DVDNAV
|
||||
if(stream->type==STREAMTYPE_DVDNAV) {
|
||||
if(vo_spudec && dvdsub_id >= 0) {
|
||||
unsigned char lang[3];
|
||||
if(dvdnav_lang_from_sid(stream, dvdsub_id, lang)) {
|
||||
snprintf(*(char**)arg, 63, "(%d) %s", dvdsub_id, lang);
|
||||
return M_PROPERTY_OK;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
if (demuxer->type == DEMUXER_TYPE_MATROSKA && dvdsub_id >= 0) {
|
||||
char lang[40] = MSGTR_Unknown;
|
||||
demux_mkv_get_sub_lang(demuxer, dvdsub_id, lang, 9);
|
||||
|
Loading…
Reference in New Issue
Block a user