DSBCAPS_GLOBALFOCUS allows sound to still play when the application is in the background. Other backends do this, so why not let dsound do it too.

This commit is contained in:
Jordan Cristiano 2013-06-22 23:23:53 -04:00
parent 911d73d85a
commit fafdc4fcef
1 changed files with 1 additions and 1 deletions

View File

@ -28,7 +28,7 @@ bool DSound::CreateBuffer()
// Fill out DSound buffer description.
dsbdesc.dwSize = sizeof(DSBUFFERDESC);
dsbdesc.dwFlags = DSBCAPS_GETCURRENTPOSITION2 | DSBCAPS_STICKYFOCUS | DSBCAPS_CTRLVOLUME;
dsbdesc.dwFlags = DSBCAPS_GETCURRENTPOSITION2 | DSBCAPS_CTRLVOLUME | DSBCAPS_GLOBALFOCUS;
dsbdesc.dwBufferBytes = bufferSize = BUFSIZE;
dsbdesc.lpwfxFormat = (WAVEFORMATEX *)&pcmwf;
dsbdesc.guid3DAlgorithm = DS3DALG_DEFAULT;