[MPlayer-cvslog] CVS: main/libmpdemux demux_aac.c, 1.5, 1.6 demux_asf.c, 1.34, 1.35 demux_audio.c, 1.40, 1.41 demux_avi.c, 1.67, 1.68 demux_mkv.c, 1.50, 1.51 demux_mpc.c, 1.11, 1.12 demux_mpg.c, 1.65, 1.66 demux_ogg.c, 1.80, 1.81 demux_rawaudio.c, 1.13, 1.14 demux_real.c, 1.73, 1.74 demux_ts.c, 1.36, 1.37 demux_ty.c, 1.9, 1.10 demux_vqf.c, 1.4, 1.5 demux_xmms.c, 1.12, 1.13 demuxer.c, 1.207, 1.208

Reimar Döffinger CVS syncmail at mplayerhq.hu
Sun Oct 30 10:19:08 CET 2005


CVS change done by Reimar Döffinger CVS

Update of /cvsroot/mplayer/main/libmpdemux
In directory mail:/var2/tmp/cvs-serv18235

Modified Files:
	demux_aac.c demux_asf.c demux_audio.c demux_avi.c demux_mkv.c 
	demux_mpc.c demux_mpg.c demux_ogg.c demux_rawaudio.c 
	demux_real.c demux_ts.c demux_ty.c demux_vqf.c demux_xmms.c 
	demuxer.c 
Log Message:
move resync_audio_stream after seeking to demuxer.c


Index: demux_aac.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_aac.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- demux_aac.c	13 Oct 2005 18:33:56 -0000	1.5
+++ demux_aac.c	30 Oct 2005 09:19:05 -0000	1.6
@@ -14,8 +14,6 @@
 #include "bswap.h"
 #include "ms_hdr.h"
 
-extern void resync_audio_stream(sh_audio_t *sh_audio);
-
 typedef struct {
 	uint8_t *buf;
 	uint64_t size;	/// amount of time of data packets pushed to demuxer->audio (in bytes)
@@ -248,7 +246,6 @@
 		}
 	}
 	sh_audio->delay = priv->last_pts - (ds_tell_pts(demuxer->audio)-sh_audio->a_in_buffer_len)/(float)priv->bitrate;
-	resync_audio_stream(sh_audio);
 }
 
 

Index: demux_asf.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_asf.c,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -r1.34 -r1.35
--- demux_asf.c	2 Sep 2005 08:32:31 -0000	1.34
+++ demux_asf.c	30 Oct 2005 09:19:05 -0000	1.35
@@ -359,7 +359,6 @@
 
 #include "stheader.h"
 
-extern void resync_audio_stream(sh_audio_t *sh_audio);
 extern void skip_audio_frame(sh_audio_t *sh_audio);
 
 static void demux_seek_asf(demuxer_t *demuxer,float rel_seek_secs,int flags){
@@ -390,7 +389,6 @@
     ds_fill_buffer(d_video);
     if(sh_audio){
       ds_fill_buffer(d_audio);
-      resync_audio_stream(sh_audio);
     }
     
     if (d_video->id < 0)

Index: demux_audio.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_audio.c,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -r1.40 -r1.41
--- demux_audio.c	20 Oct 2005 15:15:53 -0000	1.40
+++ demux_audio.c	30 Oct 2005 09:19:05 -0000	1.41
@@ -44,7 +44,6 @@
 } mp3_hdr_t;
 
 extern void free_sh_audio(sh_audio_t* sh);
-extern void resync_audio_stream(sh_audio_t *sh_audio);
 extern void print_wave_header(WAVEFORMATEX *h);
 
 int hr_mp3_seek = 0;
@@ -496,7 +495,6 @@
     if(len > 0)
       high_res_mp3_seek(demuxer,len);
     sh_audio->delay = priv->last_pts -  (ds_tell_pts(demuxer->audio)-sh_audio->a_in_buffer_len)/(float)sh_audio->i_bps;
-    resync_audio_stream(sh_audio);
     return;
   }
 
@@ -527,9 +525,6 @@
   }
 
   stream_seek(s,pos);
-
-  resync_audio_stream(sh_audio);
-
 }
 
 static void demux_close_audio(demuxer_t* demuxer) {

Index: demux_avi.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_avi.c,v
retrieving revision 1.67
retrieving revision 1.68
diff -u -r1.67 -r1.68
--- demux_avi.c	13 Sep 2005 18:12:48 -0000	1.67
+++ demux_avi.c	30 Oct 2005 09:19:05 -0000	1.68
@@ -617,7 +617,6 @@
 }
 
 //extern float initial_pts_delay;
-extern void resync_audio_stream(sh_audio_t *sh_audio);
 
 void demux_seek_avi(demuxer_t *demuxer,float rel_seek_secs,int flags){
     avi_priv_t *priv=demuxer->priv;
@@ -806,7 +805,6 @@
             demux_read_data(d_audio,NULL,skip_audio_bytes);
             //d_audio->pts=0; // PTS is outdated because of the raw data skipping
           }
-	  resync_audio_stream(sh_audio);
 
 //          sh_audio->timer=-skip_audio_secs;
 

Index: demux_mkv.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_mkv.c,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -r1.50 -r1.51
--- demux_mkv.c	22 Oct 2005 10:13:28 -0000	1.50
+++ demux_mkv.c	30 Oct 2005 09:19:05 -0000	1.51
@@ -3117,7 +3117,6 @@
   free_cached_dps (demuxer);
   if (!(flags & 2))  /* time in secs */
     {
-      void resync_audio_stream(sh_audio_t *sh_audio);
       mkv_demuxer_t *mkv_d = (mkv_demuxer_t *) demuxer->priv;
       stream_t *s = demuxer->stream;
       int64_t target_timecode = 0, diff, min_diff=0xFFFFFFFL;
@@ -3228,15 +3227,11 @@
         clear_subtitles(demuxer, 0, 1);
 
       demux_mkv_fill_buffer(demuxer, NULL);
-
-      if(demuxer->audio->sh != NULL)
-        resync_audio_stream((sh_audio_t *) demuxer->audio->sh); 
     }
   else if ((demuxer->movi_end <= 0) || !(flags & 1))
     mp_msg (MSGT_DEMUX, MSGL_V, "[mkv] seek unsupported flags\n");
   else
     {
-      void resync_audio_stream(sh_audio_t *sh_audio);
       mkv_demuxer_t *mkv_d = (mkv_demuxer_t *) demuxer->priv;
       stream_t *s = demuxer->stream;
       uint64_t target_filepos;
@@ -3274,9 +3269,6 @@
         clear_subtitles(demuxer, 0, 1);
 
       demux_mkv_fill_buffer(demuxer, NULL);
-
-      if(demuxer->audio->sh != NULL)
-        resync_audio_stream((sh_audio_t *) demuxer->audio->sh); 
     }
 }
 

Index: demux_mpc.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_mpc.c,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- demux_mpc.c	12 Oct 2005 21:55:55 -0000	1.11
+++ demux_mpc.c	30 Oct 2005 09:19:05 -0000	1.12
@@ -181,7 +181,6 @@
   if (!sh_audio) return;
   sh_audio->delay = priv->last_pts - (ds_tell_pts(demuxer->audio) -
                      sh_audio->a_in_buffer_len)/(float)sh_audio->i_bps;
-  resync_audio_stream(sh_audio);
 }
 
 static void demux_close_mpc(demuxer_t* demuxer) {

Index: demux_mpg.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_mpg.c,v
retrieving revision 1.65
retrieving revision 1.66
diff -u -r1.65 -r1.66
--- demux_mpg.c	15 Oct 2005 11:51:37 -0000	1.65
+++ demux_mpg.c	30 Oct 2005 09:19:05 -0000	1.66
@@ -669,7 +669,6 @@
   return 1;
 }
 
-extern void resync_audio_stream(sh_audio_t *sh_audio);
 extern void skip_audio_frame(sh_audio_t *sh_audio);
 
 void demux_seek_mpg(demuxer_t *demuxer,float rel_seek_secs,int flags){
@@ -733,7 +732,6 @@
 	ds_fill_buffer(d_video);
 	if(sh_audio){
 	  ds_fill_buffer(d_audio);
-	  resync_audio_stream(sh_audio);
 	}
 
 	while(1){

Index: demux_ogg.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_ogg.c,v
retrieving revision 1.80
retrieving revision 1.81
diff -u -r1.80 -r1.81
--- demux_ogg.c	13 Oct 2005 18:33:56 -0000	1.80
+++ demux_ogg.c	30 Oct 2005 09:19:05 -0000	1.81
@@ -1390,8 +1390,6 @@
 
 }
 
-extern void resync_audio_stream(sh_audio_t *sh_audio);
-
 static void demux_ogg_seek(demuxer_t *demuxer,float rel_seek_secs,int flags) {
   ogg_demuxer_t* ogg_d = demuxer->priv;
   ogg_sync_state* sync = &ogg_d->sync;
@@ -1558,8 +1556,6 @@
         vo_osd_changed(OSDTYPE_SUBTITLE);
         clear_sub = -1;
 	demux_ogg_add_packet(ds,os,ds->id,&op);
-	if(sh_audio)
-	  resync_audio_stream(sh_audio); 
 	return;
       }
      }

Index: demux_rawaudio.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_rawaudio.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- demux_rawaudio.c	25 Sep 2005 17:29:45 -0000	1.13
+++ demux_rawaudio.c	30 Oct 2005 09:19:05 -0000	1.14
@@ -30,8 +30,6 @@
 };
 
 
-extern void resync_audio_stream(sh_audio_t *sh_audio);
-
 static demuxer_t* demux_rawaudio_open(demuxer_t* demuxer) {
   sh_audio_t* sh_audio;
   WAVEFORMATEX* w;
@@ -95,7 +93,6 @@
   pos -= (pos % (sh_audio->channels * sh_audio->samplesize) );
   stream_seek(s,pos);
   sh_audio->delay= (pos-ds_tell_pts(demuxer->audio)-sh_audio->a_in_buffer_len) / (float)(sh_audio->wf->nAvgBytesPerSec);
-  resync_audio_stream(sh_audio);
 //  printf("demux_rawaudio: streamtell=%d\n",(int)stream_tell(demuxer->stream));
 }
 

Index: demux_real.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_real.c,v
retrieving revision 1.73
retrieving revision 1.74
diff -u -r1.73 -r1.74
--- demux_real.c	2 Sep 2005 08:32:32 -0000	1.73
+++ demux_real.c	30 Oct 2005 09:19:05 -0000	1.74
@@ -1748,8 +1748,6 @@
     return;
 }
 
-extern void resync_audio_stream(sh_audio_t * sh_audio);
-
 /* please upload RV10 samples WITH INDEX CHUNK */
 static int demux_seek_real(demuxer_t *demuxer, float rel_seek_secs, int flags)
 {
@@ -1840,8 +1838,6 @@
         stream_seek(demuxer->stream, next_offset);
 
     demux_real_fill_buffer(demuxer, NULL);
-    if (sh_audio)
-        resync_audio_stream(sh_audio);
     return 1;
 }
 

Index: demux_ts.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_ts.c,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -r1.36 -r1.37
--- demux_ts.c	13 Oct 2005 18:33:56 -0000	1.36
+++ demux_ts.c	30 Oct 2005 09:19:05 -0000	1.37
@@ -223,7 +223,6 @@
 #define IS_VIDEO(x) (((x) == VIDEO_MPEG1) || ((x) == VIDEO_MPEG2) || ((x) == VIDEO_MPEG4) || ((x) == VIDEO_H264) || ((x) == VIDEO_AVC))
 
 static int ts_parse(demuxer_t *demuxer, ES_stream_t *es, unsigned char *packet, int probe);
-extern void resync_audio_stream( sh_audio_t *sh_audio );
 
 static uint8_t get_packet_size(const unsigned char *buf, int size)
 {
@@ -2991,7 +2990,6 @@
 }
 
 
-extern void resync_audio_stream(sh_audio_t *sh_audio);
 extern void skip_audio_frame(sh_audio_t *sh_audio);
 
 static void reset_fifos(ts_priv_t* priv, int a, int v, int s)
@@ -3096,7 +3094,6 @@
 	if(sh_audio != NULL)
 	{
 		ds_fill_buffer(d_audio);
-		resync_audio_stream(sh_audio);
 	}
 
 	while(sh_video != NULL)

Index: demux_ty.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_ty.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- demux_ty.c	13 Oct 2005 18:33:56 -0000	1.9
+++ demux_ty.c	30 Oct 2005 09:19:05 -0000	1.10
@@ -45,7 +45,6 @@
 #include "stheader.h"
 #include "../sub_cc.h"
 
-extern void resync_audio_stream( sh_audio_t *sh_audio );
 extern void skip_audio_frame( sh_audio_t *sh_audio );
 extern int sub_justify;
 
@@ -1313,7 +1312,6 @@
 	if( sh_audio )
    {
 	  ds_fill_buffer( d_audio );
-	  resync_audio_stream( sh_audio );
 	}
 
 	while( 1 )

Index: demux_vqf.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_vqf.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- demux_vqf.c	13 Oct 2005 18:33:56 -0000	1.4
+++ demux_vqf.c	30 Oct 2005 09:19:05 -0000	1.5
@@ -9,8 +9,6 @@
 #include "stheader.h"
 #include "../libmpcodecs/vqf.h"
 
-extern void resync_audio_stream(sh_audio_t *sh_audio);
-
 static int demux_probe_vqf(demuxer_t* demuxer) 
 {
   char buf[KEYWORD_BYTES];
@@ -195,7 +193,6 @@
 
   pos -= (pos % (sh_audio->channels * sh_audio->samplesize) );
   stream_seek(s,pos);
-  resync_audio_stream(sh_audio);
 #endif
 }
 

Index: demux_xmms.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_xmms.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- demux_xmms.c	2 Sep 2005 08:32:32 -0000	1.12
+++ demux_xmms.c	30 Oct 2005 09:19:05 -0000	1.13
@@ -199,8 +199,6 @@
 
 // ============================ mplayer demuxer stuff ===============
 
-//extern void resync_audio_stream(sh_audio_t *sh_audio);
-
 static int demux_xmms_open(demuxer_t* demuxer) {
   InputPlugin* ip = NULL;
   sh_audio_t* sh_audio;

Index: demuxer.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demuxer.c,v
retrieving revision 1.207
retrieving revision 1.208
diff -u -r1.207 -r1.208
--- demuxer.c	23 Sep 2005 22:35:03 -0000	1.207
+++ demuxer.c	30 Oct 2005 09:19:05 -0000	1.208
@@ -21,6 +21,7 @@
 #include "../libaf/af_format.h"
 #include "../libvo/fastmemcpy.h"
 
+extern void resync_audio_stream(sh_audio_t *sh_audio);
 
 // Demuxer list
 extern demuxer_desc_t demuxer_desc_rawaudio;
@@ -856,6 +857,8 @@
 if (demuxer->desc->seek)
     demuxer->desc->seek(demuxer,rel_seek_secs,flags);
 
+    if (sh_audio) resync_audio_stream(sh_audio);
+
 return 1;
 }
 




More information about the MPlayer-cvslog mailing list