Nikolay Sivov (@nsivov) commented about dlls/mf/tests/mf.c:
+#define check_type_handler_output_type(a, b, c) check_type_handler_output_type_(__LINE__, a, b, c) +static void check_type_handler_output_type_(int line, IMFMediaTypeHandler *handler, UINT expected_w, UINT expected_h) +{
- IMFMediaType *output_type;
- UINT64 frame_size;
- HRESULT hr;
- hr = IMFMediaTypeHandler_GetCurrentMediaType(handler, &output_type);
- ok_(__FILE__, line)(hr == S_OK, "Unexpected hr %#lx.\n", hr);
- hr = IMFMediaType_GetUINT64(output_type, &MF_MT_FRAME_SIZE, &frame_size);
- ok_(__FILE__, line)(hr == S_OK, "Unexpected hr %#lx.\n", hr);
- todo_wine_if(expected_h > 72)
- ok_(__FILE__, line)(frame_size == (((UINT64)expected_w << 32) | expected_h), "Unexpected frame size %#llx\n", frame_size);
- IMFMediaType_Release(output_type);
+}
Could you inline those checks please? It doesn't check type, but only one attribute and it's unlikely to be used anywhere else. We can still have a helper, that returns UINT64 for frame size, accepting both IMFMediaTypeHandler and IMFTransform (with QI probing), but testing for size value we can do in the test function.
Otherwise let's have it as is.