Mercurial > mplayer.hg
comparison libao2/ao_sdl.c @ 3137:b9ee2d8d7279
Audio delay bugfix
author | anders |
---|---|
date | Mon, 26 Nov 2001 11:30:35 +0000 |
parents | 981a9e5118ce |
children | 47297acadbfb |
comparison
equal
deleted
inserted
replaced
3136:b196b915fdc4 | 3137:b9ee2d8d7279 |
---|---|
142 if(ao_subdevice) { | 142 if(ao_subdevice) { |
143 setenv("SDL_AUDIODRIVER", ao_subdevice, 1); | 143 setenv("SDL_AUDIODRIVER", ao_subdevice, 1); |
144 printf("SDL: using %s audio driver\n", ao_subdevice); | 144 printf("SDL: using %s audio driver\n", ao_subdevice); |
145 } | 145 } |
146 | 146 |
147 ao_data.bps=(channels+1)*rate; | 147 ao_data.bps=channels*rate; |
148 if(format != AFMT_U8 && format != AFMT_S8) | 148 if(format != AFMT_U8 && format != AFMT_S8) |
149 ao_data.bps*=2; | 149 ao_data.bps*=2; |
150 | 150 |
151 /* The desired audio format (see SDL_AudioSpec) */ | 151 /* The desired audio format (see SDL_AudioSpec) */ |
152 switch(format) { | 152 switch(format) { |