Mercurial > mplayer.hg
changeset 22419:4cfb8def78c1
Fix wrong setting of samplesize (must be bytes per sample, not bits)
author | reimar |
---|---|
date | Sun, 04 Mar 2007 12:43:55 +0000 |
parents | 677ea3e3c75a |
children | db8714b9cdb7 |
files | libmpdemux/demux_audio.c |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/libmpdemux/demux_audio.c Sun Mar 04 11:31:43 2007 +0000 +++ b/libmpdemux/demux_audio.c Sun Mar 04 12:43:55 2007 +0000 @@ -423,7 +423,8 @@ w->nSamplesPerSec = sh_audio->samplerate = stream_read_dword_le(s); w->nAvgBytesPerSec = stream_read_dword_le(s); w->nBlockAlign = stream_read_word_le(s); - w->wBitsPerSample = sh_audio->samplesize = stream_read_word_le(s); + w->wBitsPerSample = stream_read_word_le(s); + sh_audio->samplesize = (w->wBitsPerSample + 7) / 8; w->cbSize = 0; sh_audio->i_bps = sh_audio->wf->nAvgBytesPerSec; l -= 16;