diff options
author | nicodvb <nicodvb@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2006-12-15 23:12:50 +0000 |
---|---|---|
committer | nicodvb <nicodvb@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2006-12-15 23:12:50 +0000 |
commit | 2ac92166410a455fdc635fa8e3a640e8c05d603b (patch) | |
tree | e9eac8550eca3b53188cd8fb4cae31c14bb0b5a6 | |
parent | df3d2e16f18f82299b13a5d4be805913572310c0 (diff) | |
download | mpv-2ac92166410a455fdc635fa8e3a640e8c05d603b.tar.bz2 mpv-2ac92166410a455fdc635fa8e3a640e8c05d603b.tar.xz |
simplified aid management in dvdnav_lang_from_aid(); patch by Joakim Patte
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21629 b3059339-0415-0410-9bf9-f77b7e298cf2
-rw-r--r-- | stream/stream_dvdnav.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/stream/stream_dvdnav.c b/stream/stream_dvdnav.c index e5fd6028c1..5d52b72d48 100644 --- a/stream/stream_dvdnav.c +++ b/stream/stream_dvdnav.c @@ -527,15 +527,9 @@ int dvdnav_lang_from_aid(stream_t *stream, int aid, unsigned char *buf) { uint16_t lang; dvdnav_priv_t * priv=(dvdnav_priv_t*)stream->priv; - if(aid >= 0x80 && aid < 0x88) - aid -= 0x80; - else if(aid >= 0x88 && aid <= 0x8F) - aid -= 0x88; - else if(aid >= 0xA0 && aid <= 0xAF) - aid -= 0xA0; if(aid < 0) return 0; - lg = dvdnav_get_audio_logical_stream(priv->dvdnav, aid); + lg = dvdnav_get_audio_logical_stream(priv->dvdnav, aid & 0x7); if(lg == 0xff) return 0; lang = dvdnav_audio_stream_to_lang(priv->dvdnav, lg); if(lang == 0xffff) return 0; |