[MPlayer-cvslog] r22437 - trunk/libmpdemux/demux_audio.c
reimar
subversion at mplayerhq.hu
Sun Mar 4 13:43:56 CET 2007
Author: reimar
Date: Sun Mar 4 13:43:55 2007
New Revision: 22437
Modified:
trunk/libmpdemux/demux_audio.c
Log:
Fix wrong setting of samplesize (must be bytes per sample, not bits)
Modified: trunk/libmpdemux/demux_audio.c
==============================================================================
--- trunk/libmpdemux/demux_audio.c (original)
+++ trunk/libmpdemux/demux_audio.c Sun Mar 4 13:43:55 2007
@@ -423,7 +423,8 @@ static int demux_audio_open(demuxer_t* d
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;
More information about the MPlayer-cvslog
mailing list