[Mplayer-cvslog] CVS: main mplayer.c,1.544,1.545 configure,1.535,1.536

Jonas Jermann CVS jonas at mplayerhq.hu
Sun Aug 11 19:14:58 CEST 2002


Update of /cvsroot/mplayer/main
In directory mail:/var/tmp.root/cvs-serv28592

Modified Files:
	mplayer.c configure 
Log Message:
dvdnav api changed

Index: mplayer.c
===================================================================
RCS file: /cvsroot/mplayer/main/mplayer.c,v
retrieving revision 1.544
retrieving revision 1.545
diff -u -r1.544 -r1.545
--- mplayer.c	9 Aug 2002 17:47:54 -0000	1.544
+++ mplayer.c	11 Aug 2002 17:14:41 -0000	1.545
@@ -2692,7 +2692,24 @@
         break;
         }
       case DVDNAV_SPU_STREAM_CHANGE: {
-        dvdnav_stream_change_event_t * stream_change=(dvdnav_stream_change_event_t*)(dvdnav_event->details);
+#if DVDNAVVERSION > 012
+        dvdnav_spu_stream_change_event_t *stream_change = (dvdnav_spu_stream_change_event_t*)(dvdnav_event->details);
+
+        printf("DVDNAV Event: Nav SPU Stream Change: phys: %d/%d/%d logical: %d\n",
+                stream_change->physical_wide,
+                stream_change->physical_letterbox,
+                stream_change->physical_pan_scan,
+                stream_change->logical);
+
+        if (vo_spudec && dvdsub_id!=stream_change->physical_wide) {
+                mp_msg(MSGT_INPUT,MSGL_DBG2,"d_dvdsub->id change: was %d is now %d\n",
+                        d_dvdsub->id,stream_change->physical_wide);
+                // FIXME: need a better way to change SPU id
+                d_dvdsub->id=dvdsub_id=stream_change->physical_wide;
+                if (vo_spudec) spudec_reset(vo_spudec);
+        }
+#else
+        dvdnav_stream_change_event_t *stream_change = (dvdnav_stream_change_event_t*)(dvdnav_event->details);
 
         printf("DVDNAV Event: Nav SPU Stream Change: phys: %d logical: %d\n",
                 stream_change->physical,
@@ -2705,12 +2722,16 @@
                 d_dvdsub->id=dvdsub_id=stream_change->physical;
                 if (vo_spudec) spudec_reset(vo_spudec);
         }
-
+#endif
         break;
         }
       case DVDNAV_AUDIO_STREAM_CHANGE: {
         int aid_temp;
+#if DVDNAVVERSION > 012
+        dvdnav_audio_stream_change_event_t *stream_change = (dvdnav_audio_stream_change_event_t*)(dvdnav_event->details);
+#else
         dvdnav_stream_change_event_t *stream_change = (dvdnav_stream_change_event_t*)(dvdnav_event->details);
+#endif
 
         printf("DVDNAV Event: Nav Audio Stream Change: phys: %d logical: %d\n",
                 stream_change->physical,

Index: configure
===================================================================
RCS file: /cvsroot/mplayer/main/configure,v
retrieving revision 1.535
retrieving revision 1.536
diff -u -r1.535 -r1.536
--- configure	9 Aug 2002 21:30:19 -0000	1.535
+++ configure	11 Aug 2002 17:14:41 -0000	1.536
@@ -3101,6 +3101,10 @@
   else
    _ld_css="$_ld_css -ldvdnav"
   fi
+  if test -n "$_dvdnavconfig" ; then
+   _dvdnav_version=`$_dvdnavconfig --version | sed "s/\.//g"`
+   _def_dvdnav_version="#define DVDNAVVERSION $_dvdnav_version"
+  fi
   if test -n "$_dvdnavdir" ; then
    _inc_extra="$_inc_extra -I$_dvdnavdir"
   fi
@@ -4412,6 +4416,7 @@
 
 /* DVD navigation support using libdvdnav */
 $_def_dvdnav
+$_def_dvdnav_version
 
 /* Define this to enable MPEG 1/2 image postprocessing (requires a FAST CPU!) */
 #define MPEG12_POSTPROC 1




More information about the MPlayer-cvslog mailing list