[MPlayer-cvslog] r29170 - trunk/stream/stream_dvdnav.c
diego
subversion at mplayerhq.hu
Sat Apr 11 15:51:02 CEST 2009
Author: diego
Date: Sat Apr 11 15:51:02 2009
New Revision: 29170
Log:
Reemit the ID_AID_x_LANG for the track. This allows the identification of the
audio track by language code (en or es) rather than by ID (128 or 129).
patch by Kevin DeKorte, kdekorte gmail com
Modified:
trunk/stream/stream_dvdnav.c
Modified: trunk/stream/stream_dvdnav.c
==============================================================================
--- trunk/stream/stream_dvdnav.c Fri Apr 10 20:29:01 2009 (r29169)
+++ trunk/stream/stream_dvdnav.c Sat Apr 11 15:51:02 2009 (r29170)
@@ -74,6 +74,7 @@ static const struct m_struct_st stream_o
};
static int seek(stream_t *s, off_t newpos);
+static void show_audio_subs_languages(dvdnav_t *nav);
static dvdnav_priv_t * new_dvdnav_stream(char * filename) {
const char * title_str;
@@ -343,6 +344,7 @@ static int fill_buffer(stream_t *s, char
priv->state &= ~NAV_FLAG_WAIT;
s->end_pos = 0;
update_title_len(s);
+ show_audio_subs_languages(priv->dvdnav);
if (priv->state & NAV_FLAG_WAIT_READ_AUTO)
priv->state |= NAV_FLAG_WAIT_READ;
if(dvdnav_current_title_info(priv->dvdnav, &tit, &part) == DVDNAV_STATUS_OK) {
@@ -538,8 +540,12 @@ static void show_audio_subs_languages(dv
if(format == 0xFFFF || format > 6)
format = 1; //unknown
id = i + base[format];
- mp_msg(MSGT_OPEN,MSGL_STATUS,MSGTR_DVDaudioStreamInfo, i,
- dvd_audio_stream_types[format], dvd_audio_stream_channels[channels], tmp, id);
+ if (lang != 0xFFFF) {
+ mp_msg(MSGT_OPEN,MSGL_STATUS,MSGTR_DVDaudioStreamInfo, i,
+ dvd_audio_stream_types[format], dvd_audio_stream_channels[channels], tmp, id);
+ if(lang && tmp[0])
+ mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_AID_%d_LANG=%s\n", id, tmp);
+ }
}
for(i=0; i<32; i++)
@@ -555,7 +561,8 @@ static void show_audio_subs_languages(dv
tmp[1] = lang & 0xFF;
}
tmp[2] = 0;
- mp_msg(MSGT_OPEN,MSGL_STATUS,MSGTR_DVDsubtitleLanguage, i+0x20, tmp);
+ if (lang != 0xFFFF)
+ mp_msg(MSGT_OPEN,MSGL_STATUS,MSGTR_DVDsubtitleLanguage, i+0x20, tmp);
}
}
More information about the MPlayer-cvslog
mailing list