mirror of
https://github.com/reactos/wine.git
synced 2024-11-28 22:20:26 +00:00
msadp32: MSDN suggests "wfx.nBlockAlign * 2 / wfx.nChannels - 12" as the formula for calculating wSamplesPerBlock.
This commit is contained in:
parent
279e797cb2
commit
d6ae9f8800
@ -171,7 +171,7 @@ static void init_wfx_adpcm(ADPCMWAVEFORMAT* awfx)
|
||||
pwfx->cbSize = 2 * sizeof(WORD) + 7 * sizeof(ADPCMCOEFSET);
|
||||
/* 7 is the size of the block head (which contains two samples) */
|
||||
|
||||
awfx->wSamplesPerBlock = (pwfx->nBlockAlign - (7 * pwfx->nChannels)) * (2 / pwfx->nChannels) + 2;
|
||||
awfx->wSamplesPerBlock = pwfx->nBlockAlign * 2 / pwfx->nChannels - 12;
|
||||
pwfx->nAvgBytesPerSec = (pwfx->nSamplesPerSec * pwfx->nBlockAlign) / awfx->wSamplesPerBlock;
|
||||
awfx->wNumCoef = 7;
|
||||
memcpy(awfx->aCoef, MSADPCM_CoeffSet, 7 * sizeof(ADPCMCOEFSET));
|
||||
|
Loading…
Reference in New Issue
Block a user