Rémi Bernon (@rbernon) commented about dlls/mfreadwrite/reader.c:
+ * We are doing this here by explicitly changing the target frame size. */ + + UINT64 new_h = h, new_w = w; + if (par_w < par_h) new_h = h * par_h / par_w; + else new_w = w * par_w / par_h; + + new_h = (new_h + 1) & ~1; + new_w = (new_w + 1) & ~1; + + IMFMediaType_SetUINT64(dst_type, &MF_MT_FRAME_SIZE, ((UINT64)new_w << 32) + new_h); + } + else + { media_type_try_copy_attr(dst_type, src_type, &MF_MT_FRAME_SIZE, &hr); + media_type_try_copy_attr(dst_type, src_type, &MF_MT_PIXEL_ASPECT_RATIO, &hr); + } Could we keep this in a separate helper, similar to how we do it in set_default_video_attributes? I think it would be better to keep update_media_type as close as possible as the one in mf/topology_loader.c
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/10535#note_142160