Audio delay bugfix

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@3138 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
anders 2001-11-26 11:30:35 +00:00
parent 32646569d9
commit abf8696e5e
3 changed files with 3 additions and 3 deletions

View File

@ -110,7 +110,7 @@ static int init(int rate,int channels,int format,int flags){
return 0;
}
ao_data.bps=(channels+1)*rate;
ao_data.bps=channels*rate;
if(format != AFMT_U8 && format != AFMT_S8)
ao_data.bps*=2;

View File

@ -144,7 +144,7 @@ static int init(int rate,int channels,int format,int flags){
printf("SDL: using %s audio driver\n", ao_subdevice);
}
ao_data.bps=(channels+1)*rate;
ao_data.bps=channels*rate;
if(format != AFMT_U8 && format != AFMT_S8)
ao_data.bps*=2;

View File

@ -459,6 +459,6 @@ static float get_delay(){
if (info.play.samples && enable_sample_timing == RTSC_ENABLED)
return (float)(queued_samples - info.play.samples) / (float)byte_per_sec;
else
return (flaot)((queued_bursts - info.play.eof) * ao_data.outburst) / (float)byte_per_sec;
return (float)((queued_bursts - info.play.eof) * ao_data.outburst) / (float)byte_per_sec;
}