From: Henri Verbeet <hverbeet(a)locutus.nl> --- dlls/quartz/vmr7_presenter.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/dlls/quartz/vmr7_presenter.c b/dlls/quartz/vmr7_presenter.c index 90a0b906610..bbfca8ec695 100644 --- a/dlls/quartz/vmr7_presenter.c +++ b/dlls/quartz/vmr7_presenter.c @@ -189,6 +189,14 @@ static HRESULT WINAPI surface_allocator_AllocateSurface(IVMRSurfaceAllocator *if if (info->lpHdr->biCompression == BI_RGB) { + DDSURFACEDESC2 primary_desc; + + primary_desc.dwSize = sizeof(primary_desc); + if (FAILED(hr = IDirectDrawSurface7_GetSurfaceDesc(presenter->primary, &primary_desc))) + return hr; + if (info->lpHdr->biBitCount != primary_desc.ddpfPixelFormat.dwRGBBitCount) + return E_FAIL; + if (info->lpHdr->biBitCount != 32) { FIXME("Unhandled bit depth %u.\n", info->lpHdr->biBitCount); -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/9520