[Bug 42546] DSOUND_PrimaryOpen() incorrect set buf size

wine-bugs at winehq.org wine-bugs at winehq.org
Tue Feb 28 08:34:35 CST 2017


https://bugs.winehq.org/show_bug.cgi?id=42546

--- Comment #10 from Ivan_83 <rozhuk.im at gmail.com> ---
> Now, back to the actual discussion in hand.
> https://msdn.microsoft.com/en-us/library/windows/desktop/dd370866(v=vs.85).
> aspx
> states that:
> 
>    The size in bytes of an audio frame is calculated as
>    the number of channels in the stream multiplied by the
>    sample size per channel. For example, the frame size is
>    four bytes for a stereo (2-channel) stream with 16-bit samples.
> 
> i.e. a frame contains nChannels samples.  So if we're allocating memory for
> n frames stored as floats, we need n * nChannels * sizeof(float) bytes.

Looks OK.
But
    device->fraglen = frag_frames * wfx->nBlockAlign;
    device->aclen = aclen_frames * wfx->nBlockAlign;
steel have values that look a little weird.

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list