[MPlayer-cvslog] CVS: main/libmpdemux stream_dvd.c,1.4,1.5
Reimar Döffinger CVS
syncmail at mplayerhq.hu
Sat Oct 15 13:47:35 CEST 2005
CVS change done by Reimar Döffinger CVS
Update of /cvsroot/mplayer/main/libmpdemux
In directory mail:/var2/tmp/cvs-serv32093
Modified Files:
stream_dvd.c
Log Message:
ugly hack to make it work again with external libdvdread
Index: stream_dvd.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/stream_dvd.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- stream_dvd.c 3 Oct 2005 14:29:01 -0000 1.4
+++ stream_dvd.c 15 Oct 2005 11:47:33 -0000 1.5
@@ -625,7 +625,11 @@
if(vts_file->vts_pgcit) {
int i;
for(i=0;i<8;i++)
+#ifdef USE_MPDVDKIT
if(vts_file->vts_pgcit->pgci_srp[ttn].pgc->audio_control[i].present) {
+#else
+ if(vts_file->vts_pgcit->pgci_srp[ttn].pgc->audio_control[i] & 0x8000) {
+#endif
audio_attr_t * audio = &vts_file->vtsi_mat->vts_audio_attr[i];
int language = 0;
char tmp[] = "unknown";
@@ -638,7 +642,11 @@
}
d->audio_streams[d->nr_of_channels].language=language;
+#ifdef USE_MPDVDKIT
d->audio_streams[d->nr_of_channels].id=vts_file->vts_pgcit->pgci_srp[ttn].pgc->audio_control[i].s_audio;
+#else
+ d->audio_streams[d->nr_of_channels].id=vts_file->vts_pgcit->pgci_srp[ttn].pgc->audio_control[i] >> 8 & 7;
+#endif
switch(audio->audio_format) {
case 0: // ac3
d->audio_streams[d->nr_of_channels].id+=FIRST_AC3_AID;
@@ -687,7 +695,11 @@
d->nr_of_subtitles=0;
for(i=0;i<32;i++)
+#ifdef USE_MPDVDKIT
if(vts_file->vts_pgcit->pgci_srp[ttn].pgc->subp_control[i].present) {
+#else
+ if(vts_file->vts_pgcit->pgci_srp[ttn].pgc->subp_control[i] & 0x80000000) {
+#endif
subp_attr_t * subtitle = &vts_file->vtsi_mat->vts_subp_attr[i];
video_attr_t *video = &vts_file->vtsi_mat->vts_video_attr;
int language = 0;
@@ -703,9 +715,17 @@
d->subtitles[ d->nr_of_subtitles ].language=language;
d->subtitles[ d->nr_of_subtitles ].id=d->nr_of_subtitles;
if(video->display_aspect_ratio == 0) /* 4:3 */
+#ifdef USE_MPDVDKIT
d->subtitles[d->nr_of_subtitles].id = vts_file->vts_pgcit->pgci_srp[ttn].pgc->subp_control[i].s_4p3;
+#else
+ d->subtitles[d->nr_of_subtitles].id = vts_file->vts_pgcit->pgci_srp[ttn].pgc->subp_control[i] >> 24 & 31;
+#endif
else if(video->display_aspect_ratio == 3) /* 16:9 */
+#ifdef USE_MPDVDKIT
d->subtitles[d->nr_of_subtitles].id = vts_file->vts_pgcit->pgci_srp[ttn].pgc->subp_control[i].s_lbox;
+#else
+ d->subtitles[d->nr_of_subtitles].id = vts_file->vts_pgcit->pgci_srp[ttn].pgc->subp_control[i] >> 8 & 31;
+#endif
mp_msg(MSGT_OPEN,MSGL_V,"[open] subtitle ( sid ): %d language: %s\n", d->nr_of_subtitles, tmp);
if(identify) {
More information about the MPlayer-cvslog
mailing list