Commit 51bd7f86 authored by Rémi Bernon's avatar Rémi Bernon Committed by Alexandre Julliard

winegstreamer: Use H264 input media type frame size when specified.

parent e15af490
......@@ -401,6 +401,7 @@ static HRESULT WINAPI transform_SetInputType(IMFTransform *iface, DWORD id, IMFM
{
struct h264_decoder *decoder = impl_from_IMFTransform(iface);
GUID major, subtype;
UINT64 frame_size;
HRESULT hr;
ULONG i;
......@@ -429,6 +430,12 @@ static HRESULT WINAPI transform_SetInputType(IMFTransform *iface, DWORD id, IMFM
IMFMediaType_Release(decoder->input_type);
IMFMediaType_AddRef((decoder->input_type = type));
if (SUCCEEDED(IMFMediaType_GetUINT64(type, &MF_MT_FRAME_SIZE, &frame_size)))
{
decoder->wg_format.u.video.width = frame_size >> 32;
decoder->wg_format.u.video.height = (UINT32)frame_size;
}
return S_OK;
}
......
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