diff options
Diffstat (limited to 'libmpdemux')
-rw-r--r-- | libmpdemux/demux_audio.c | 6 | ||||
-rw-r--r-- | libmpdemux/demux_demuxers.c | 3 | ||||
-rw-r--r-- | libmpdemux/demuxer.c | 2 | ||||
-rw-r--r-- | libmpdemux/stheader.h | 2 |
4 files changed, 6 insertions, 7 deletions
diff --git a/libmpdemux/demux_audio.c b/libmpdemux/demux_audio.c index f507fab6b7..d45861b93e 100644 --- a/libmpdemux/demux_audio.c +++ b/libmpdemux/demux_audio.c @@ -295,7 +295,7 @@ void demux_audio_seek(demuxer_t *demuxer,float rel_seek_secs,int flags){ } if(len > 0) high_res_mp3_seek(demuxer,len); - sh_audio->timer = priv->last_pts - (ds_tell_pts(demuxer->audio)-sh_audio->a_in_buffer_len)/(float)sh_audio->i_bps; + 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; } @@ -307,13 +307,13 @@ void demux_audio_seek(demuxer_t *demuxer,float rel_seek_secs,int flags){ pos = base + (rel_seek_secs*sh_audio->i_bps); if(demuxer->movi_end && pos >= demuxer->movi_end) { - sh_audio->timer = (stream_tell(s) - demuxer->movi_start)/(float)sh_audio->i_bps; + sh_audio->delay = (stream_tell(s) - demuxer->movi_start)/(float)sh_audio->i_bps; return; } else if(pos < demuxer->movi_start) pos = demuxer->movi_start; priv->last_pts = (pos-demuxer->movi_start)/(float)sh_audio->i_bps; - sh_audio->timer = priv->last_pts - (ds_tell_pts(demuxer->audio)-sh_audio->a_in_buffer_len)/(float)sh_audio->i_bps; + sh_audio->delay = priv->last_pts - (ds_tell_pts(demuxer->audio)-sh_audio->a_in_buffer_len)/(float)sh_audio->i_bps; switch(priv->frmt) { case WAV: diff --git a/libmpdemux/demux_demuxers.c b/libmpdemux/demux_demuxers.c index 7431b42723..36e89ee624 100644 --- a/libmpdemux/demux_demuxers.c +++ b/libmpdemux/demux_demuxers.c @@ -73,8 +73,7 @@ void demux_demuxers_seek(demuxer_t *demuxer,float rel_seek_secs,int flags) { // In case the demuxer don't set pts if(!demuxer->audio->pts) demuxer->audio->pts = pos-((ds_tell_pts(demuxer->audio)-sh->a_in_buffer_len)/(float)sh->i_bps); - if(sh->timer) - sh->timer = 0; + sh->delay = 0; } if(priv->sd != priv->vd) diff --git a/libmpdemux/demuxer.c b/libmpdemux/demuxer.c index 3fca3160cd..c53c1628a4 100644 --- a/libmpdemux/demuxer.c +++ b/libmpdemux/demuxer.c @@ -1135,7 +1135,7 @@ if(!demuxer->seekable){ #if 0 if(sh_audio) sh_audio->timer=sh_video->timer; #else - if(sh_audio) sh_audio->timer=0; + if(sh_audio) sh_audio->delay=0; if(sh_video) sh_video->timer=0; // !!!!!! #endif diff --git a/libmpdemux/stheader.h b/libmpdemux/stheader.h index 12dff42c10..8f681d9f13 100644 --- a/libmpdemux/stheader.h +++ b/libmpdemux/stheader.h @@ -46,7 +46,7 @@ typedef struct { struct codecs_st *codec; unsigned int format; int inited; - float timer; // value of old a_frame + float delay; // value of old a_frame // output format: int sample_format; int samplerate; |