Mercurial > mplayer.hg
changeset 9707:53e738a54064
Fix a 100L bug wich killed mencoder timing and switch to the new
config header
author | albeu |
---|---|
date | Thu, 27 Mar 2003 20:27:50 +0000 |
parents | 8ae20fe919c9 |
children | a37708f0b574 |
files | libmpdemux/demux_rawaudio.c |
diffstat | 1 files changed, 5 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/libmpdemux/demux_rawaudio.c Thu Mar 27 20:25:32 2003 +0000 +++ b/libmpdemux/demux_rawaudio.c Thu Mar 27 20:27:50 2003 +0000 @@ -6,7 +6,8 @@ #include <unistd.h> #include <string.h> -#include "../cfgparser.h" +#include "../m_option.h" +#include "../m_config.h" #include "stream.h" #include "demuxer.h" @@ -65,8 +66,8 @@ return 0; dp = new_demux_packet(l); - ds->pts = spos / (float)(sh_audio->wf->nAvgBytesPerSec); - ds->pos = spos; + dp->pts = (spos - demuxer->movi_start) / (float)(sh_audio->wf->nAvgBytesPerSec); + dp->pos = (spos - demuxer->movi_start); stream_read(demuxer->stream,dp->buffer,l); ds_add_packet(ds,dp); @@ -87,7 +88,7 @@ pos -= (pos % (sh_audio->channels * sh_audio->samplesize) ); stream_seek(s,pos); - sh_audio->delay=pos / (float)(sh_audio->wf->nAvgBytesPerSec); + //sh_audio->delay=pos / (float)(sh_audio->wf->nAvgBytesPerSec); resync_audio_stream(sh_audio); // printf("demux_rawaudio: streamtell=%d\n",(int)stream_tell(demuxer->stream)); }