Commit 5542942c authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

evr/mixer: Store input type attributes.

parent 95ab7e8a
......@@ -686,7 +686,16 @@ static HRESULT WINAPI video_mixer_transform_SetInputType(IMFTransform *iface, DW
&count, &guids)))
{
if (SUCCEEDED(hr = video_mixer_collect_output_types(mixer, &video_desc, service, count, guids)))
FIXME("Set input type.\n");
{
GUID subtype = { 0 };
if (FAILED(hr = IMFMediaType_GetGUID(media_type, &MF_MT_SUBTYPE, &subtype)))
WARN("Failed to get subtype %#x.\n", hr);
if (SUCCEEDED(hr = MFCreateVideoMediaTypeFromSubtype(&subtype, &mixer->inputs[0].media_type)))
hr = IMFMediaType_CopyAllItems(media_type, (IMFAttributes *)mixer->inputs[0].media_type);
}
CoTaskMemFree(guids);
}
}
......
......@@ -896,17 +896,15 @@ static void test_default_mixer_type_negotiation(void)
ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
hr = IMFTransform_GetInputCurrentType(transform, 0, &media_type);
todo_wine
ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
if (hr == S_OK)
{
ok(media_type != (IMFMediaType *)video_type, "Unexpected media type instance.\n");
hr = IMFTransform_GetInputCurrentType(transform, 0, &media_type2);
ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
ok(media_type == media_type2, "Unexpected media type instance.\n");
IMFMediaType_Release(media_type);
IMFMediaType_Release(media_type2);
}
hr = IMFTransform_QueryInterface(transform, &IID_IMFVideoProcessor, (void **)&processor);
ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
......@@ -919,31 +917,24 @@ todo_wine
ok(hr == MF_E_TRANSFORM_TYPE_NOT_SET, "Unexpected hr %#x.\n", hr);
hr = IMFTransform_GetInputCurrentType(transform, 0, &media_type);
todo_wine
ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
if (SUCCEEDED(hr))
{
ok(media_type != (IMFMediaType *)video_type, "Unexpected pointer.\n");
hr = IMFMediaType_QueryInterface(media_type, &IID_IMFVideoMediaType, (void **)&unk);
ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
IUnknown_Release(unk);
IMFMediaType_Release(media_type);
}
ok(media_type != (IMFMediaType *)video_type, "Unexpected pointer.\n");
hr = IMFMediaType_QueryInterface(media_type, &IID_IMFVideoMediaType, (void **)&unk);
ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
IUnknown_Release(unk);
IMFMediaType_Release(media_type);
hr = IMFVideoProcessor_GetAvailableVideoProcessorModes(processor, &count, &guids);
todo_wine
ok(hr == MF_E_TRANSFORM_TYPE_NOT_SET, "Unexpected hr %#x.\n", hr);
hr = IMFTransform_GetOutputAvailableType(transform, 0, 0, &media_type);
todo_wine
ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
if (SUCCEEDED(hr))
{
hr = IMFTransform_SetOutputType(transform, 0, media_type, 0);
ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
IMFMediaType_Release(media_type);
}
hr = IMFTransform_SetOutputType(transform, 0, media_type, 0);
todo_wine
ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
IMFMediaType_Release(media_type);
hr = IMFVideoProcessor_GetVideoProcessorMode(processor, &guid);
todo_wine
......
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