Commit 00bc5eb7 authored by Zebediah Figura's avatar Zebediah Figura Committed by Alexandre Julliard

winegstreamer: Implement IWMReader::GetOutputFormat().

parent beb7966d
......@@ -137,11 +137,14 @@ static HRESULT WINAPI WMReader_GetOutputFormatCount(IWMReader *iface, DWORD outp
return E_NOTIMPL;
}
static HRESULT WINAPI WMReader_GetOutputFormat(IWMReader *iface, DWORD output_num, DWORD format_num, IWMOutputMediaProps **props)
static HRESULT WINAPI WMReader_GetOutputFormat(IWMReader *iface, DWORD output,
DWORD index, IWMOutputMediaProps **props)
{
struct async_reader *This = impl_from_IWMReader(iface);
FIXME("(%p)->(%u %u %p)\n", This, output_num, format_num, props);
return E_NOTIMPL;
struct async_reader *reader = impl_from_IWMReader(iface);
TRACE("reader %p, output %u, index %u, props %p.\n", reader, output, index, props);
return wm_reader_get_output_format(&reader->reader, output, index, props);
}
static HRESULT WINAPI WMReader_Start(IWMReader *iface, QWORD start, QWORD duration, float rate, void *context)
......
......@@ -1419,10 +1419,8 @@ static void test_async_reader_types(void)
* with. In particular it has to be PCM. */
hr = IWMReader_GetOutputFormat(reader, output_number, 0, &output_props);
todo_wine ok(hr == S_OK, "Got hr %#x.\n", hr);
ok(hr == S_OK, "Got hr %#x.\n", hr);
if (hr == S_OK)
{
ret_size = sizeof(mt2_buffer);
hr = IWMOutputMediaProps_GetMediaType(output_props, mt2, &ret_size);
ok(hr == S_OK, "Got hr %#x.\n", hr);
......@@ -1434,7 +1432,6 @@ static void test_async_reader_types(void)
mt2->lSampleSize = mt->lSampleSize;
ok(compare_media_types(mt, mt2), "Media types didn't match.\n");
}
}
else
{
ok(IsEqualGUID(&majortype, &MEDIATYPE_Video), "Got major type %s.\n", debugstr_guid(&majortype));
......@@ -1553,7 +1550,7 @@ static void test_async_reader_types(void)
output_props = (void *)0xdeadbeef;
hr = IWMReader_GetOutputFormat(reader, 2, 0, &output_props);
todo_wine ok(hr == E_INVALIDARG, "Got hr %#x.\n", hr);
ok(hr == E_INVALIDARG, "Got hr %#x.\n", hr);
ok(output_props == (void *)0xdeadbeef, "Got output props %p.\n", output_props);
IWMReaderAdvanced2_Release(advanced);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment