From 04cf4dc06ff5d2d1b43d3a7d6f3ccbb07b8c1fb5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20H=C3=B6hle?= Date: Thu, 12 Jan 2012 23:08:47 +0100 Subject: [PATCH] wineoss: Reset accounts for dropped frames in capture mode. --- dlls/wineoss.drv/mmdevdrv.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/dlls/wineoss.drv/mmdevdrv.c b/dlls/wineoss.drv/mmdevdrv.c index 89c9adf9c05..8bfb768c471 100644 --- a/dlls/wineoss.drv/mmdevdrv.c +++ b/dlls/wineoss.drv/mmdevdrv.c @@ -1501,7 +1501,12 @@ static HRESULT WINAPI AudioClient_Reset(IAudioClient *iface) return AUDCLNT_E_BUFFER_OPERATION_PENDING; } - This->written_frames = 0; + if(This->dataflow == eRender){ + This->written_frames = 0; + }else{ + This->written_frames += This->held_frames; + } + This->lcl_offs_frames = 0; This->inbuf_frames = 0; This->held_frames = 0;