Use the stored buffer metrics for the mmdevapi buffer size

This commit is contained in:
Chris Robinson
2012-11-04 22:35:35 -08:00
parent 92dde81296
commit 3da1b540fd
+1 -9
View File
@@ -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);