From: Yuxuan Shui <yshui@codeweavers.com> --- dlls/mf/tests/transform.c | 2 +- dlls/winegstreamer/wma_decoder.c | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/dlls/mf/tests/transform.c b/dlls/mf/tests/transform.c index e865cbc2412..9338121fb30 100644 --- a/dlls/mf/tests/transform.c +++ b/dlls/mf/tests/transform.c @@ -4024,7 +4024,7 @@ static void test_wma_decoder_dmo_output_type(void) init_dmo_media_type_audio(bad_output_type, &MEDIASUBTYPE_PCM, channel_count, rate, bits_per_sample); bad_output_type->formattype = FORMAT_VideoInfo; /* What if formattype is wrong? */ hr = IMediaObject_SetOutputType(dmo, 0, bad_output_type, 0); - todo_wine ok(hr == DMO_E_TYPE_NOT_ACCEPTED, "SetOutputType returned %#lx.\n", hr); + ok(hr == DMO_E_TYPE_NOT_ACCEPTED, "SetOutputType returned %#lx.\n", hr); hr = IMediaObject_SetOutputType(dmo, 0, good_output_type, 0); ok(hr == S_OK, "SetOutputType returned %#lx.\n", hr); diff --git a/dlls/winegstreamer/wma_decoder.c b/dlls/winegstreamer/wma_decoder.c index 4aa90b85c6b..ba9547e9a34 100644 --- a/dlls/winegstreamer/wma_decoder.c +++ b/dlls/winegstreamer/wma_decoder.c @@ -798,6 +798,9 @@ static HRESULT WINAPI media_object_SetOutputType(IMediaObject *iface, DWORD inde if (IsEqualGUID(&decoder->input_type.majortype, &GUID_NULL)) return DMO_E_TYPE_NOT_SET; + if (!IsEqualGUID(&type->formattype, &FORMAT_WaveFormatEx)) + return DMO_E_TYPE_NOT_ACCEPTED; + if (FAILED(hr = wg_transform_create_quartz(&decoder->input_type, type, &attrs, &new_transform))) return hr; -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/9575