winegstreamer: Implement IWMSyncReader::GetOutputCount().

Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zebediah Figura 2021-10-26 22:22:04 -05:00 committed by Alexandre Julliard
parent f4672a6f0f
commit 8bd3c8bf5a
2 changed files with 11 additions and 6 deletions

View File

@ -85,11 +85,16 @@ static HRESULT WINAPI WMSyncReader_GetNextSample(IWMSyncReader2 *iface, WORD str
return E_NOTIMPL;
}
static HRESULT WINAPI WMSyncReader_GetOutputCount(IWMSyncReader2 *iface, DWORD *outputs)
static HRESULT WINAPI WMSyncReader_GetOutputCount(IWMSyncReader2 *iface, DWORD *count)
{
struct sync_reader *This = impl_from_IWMSyncReader2(iface);
FIXME("(%p)->(%p): stub!\n", This, outputs);
return E_NOTIMPL;
struct sync_reader *reader = impl_from_IWMSyncReader2(iface);
TRACE("reader %p, count %p.\n", reader, count);
EnterCriticalSection(&reader->reader.cs);
*count = reader->reader.stream_count;
LeaveCriticalSection(&reader->reader.cs);
return S_OK;
}
static HRESULT WINAPI WMSyncReader_GetOutputFormat(IWMSyncReader2 *iface, DWORD output_num, DWORD format_num,

View File

@ -463,8 +463,8 @@ static void test_sync_reader_streaming(void)
count = 0xdeadbeef;
hr = IWMSyncReader_GetOutputCount(reader, &count);
todo_wine ok(hr == S_OK, "Got hr %#x.\n", hr);
todo_wine ok(count == 2, "Got count %u.\n", count);
ok(hr == S_OK, "Got hr %#x.\n", hr);
ok(count == 2, "Got count %u.\n", count);
for (i = 0; i < 2; ++i)
{