diff options
author | Chris Robinson <[email protected]> | 2012-11-04 22:35:35 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2012-11-04 22:35:35 -0800 |
commit | 3da1b540fd333caee51ca710b8c9ef92ffcc692d (patch) | |
tree | b19120dc9e466c931f77098bec79d3b564310fa9 /Alc | |
parent | 92dde81296778ba9d8a58777c0de192f14e45387 (diff) |
Use the stored buffer metrics for the mmdevapi buffer size
Diffstat (limited to 'Alc')
-rw-r--r-- | Alc/backends/mmdevapi.c | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/Alc/backends/mmdevapi.c b/Alc/backends/mmdevapi.c index 9db83003..de4201dd 100644 --- a/Alc/backends/mmdevapi.c +++ b/Alc/backends/mmdevapi.c @@ -233,18 +233,10 @@ static ALuint MMDevApiProc(ALvoid *ptr) return 0; } - hr = IAudioClient_GetBufferSize(data->client, &buffer_len); - if(FAILED(hr)) - { - ERR("Failed to get audio buffer size: 0x%08lx\n", hr); - aluHandleDisconnect(device); - CoUninitialize(); - return 0; - } - SetRTPriority(); update_size = device->UpdateSize; + buffer_len = update_size * device->NumUpdates; while(!data->killNow) { hr = IAudioClient_GetCurrentPadding(data->client, &written); |