Commit a6ab4c51 authored by Maarten Lankhorst's avatar Maarten Lankhorst Committed by Alexandre Julliard

dsound: Fix division by zero in DSOUND_Calc3DBuffer.

parent 2b8a1815
......@@ -238,6 +238,9 @@ void DSOUND_Calc3DBuffer(IDirectSoundBufferImpl *dsb)
/* my test show that for my way of calc., we need only half of angles */
DWORD dwInsideConeAngle = dsb->ds3db_ds3db.dwInsideConeAngle/2;
DWORD dwOutsideConeAngle = dsb->ds3db_ds3db.dwOutsideConeAngle/2;
if (dwOutsideConeAngle == dwInsideConeAngle)
++dwOutsideConeAngle;
/* full volume */
if (flAngle < dwInsideConeAngle)
flAngle = dwInsideConeAngle;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment