Native MF aligns the NV12 planes on 16 pixels, and Greedfall expects it.
Signed-off-by: Rémi Bernon rbernon@codeweavers.com --- dlls/winegstreamer/wg_parser.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/dlls/winegstreamer/wg_parser.c b/dlls/winegstreamer/wg_parser.c index a3b88529c60..4cadf87ccd0 100644 --- a/dlls/winegstreamer/wg_parser.c +++ b/dlls/winegstreamer/wg_parser.c @@ -605,6 +605,7 @@ static NTSTATUS wg_parser_stream_enable(void *args) const struct wg_parser_stream_enable_params *params = args; struct wg_parser_stream *stream = params->stream; const struct wg_format *format = params->format; + uint32_t aligned_height;
stream->current_format = *format; stream->enabled = true; @@ -621,9 +622,14 @@ static NTSTATUS wg_parser_stream_enable(void *args) gst_util_set_object_arg(G_OBJECT(stream->flip), "method", "vertical-flip"); break;
+ case WG_VIDEO_FORMAT_NV12: + aligned_height = (stream->current_format.u.video.height + 0xf) & ~0xf; + g_object_set(G_OBJECT(stream->videobox), "bottom", + stream->current_format.u.video.height - aligned_height, NULL); + stream->current_format.u.video.height = aligned_height; + /* fallthrough */ case WG_VIDEO_FORMAT_AYUV: case WG_VIDEO_FORMAT_I420: - case WG_VIDEO_FORMAT_NV12: case WG_VIDEO_FORMAT_UYVY: case WG_VIDEO_FORMAT_YUY2: case WG_VIDEO_FORMAT_YV12: