vlc/vlc-2.2 | branch: master | Hugo Beauzée-Luyssen <[email protected]> | Thu Apr 6 10:55:44 2017 +0200| [1bff15108ce943aa6a4b6bf79f4705ff82d52e1c] | committer: Hugo Beauzée-Luyssen
direct3d9: Don't attempt to use hardware conversion for uneven dimensions Even when an even buffer is used, StretchRect seems to be failing to convert the last column, at least on some devices. Manually cherry-picked from c2970f6aea95f801ea3435d37f479cfd70035d95 Signed-off-by: Hugo Beauzée-Luyssen <[email protected]> > http://git.videolan.org/gitweb.cgi/vlc/vlc-2.2.git/?a=commit;h=1bff15108ce943aa6a4b6bf79f4705ff82d52e1c --- modules/video_output/msw/direct3d.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/video_output/msw/direct3d.c b/modules/video_output/msw/direct3d.c index 67f9921..abdfaec 100644 --- a/modules/video_output/msw/direct3d.c +++ b/modules/video_output/msw/direct3d.c @@ -875,11 +875,12 @@ static const d3d_format_t d3d_formats[] = { static const d3d_format_t *Direct3DFindFormat(vout_display_t *vd, vlc_fourcc_t chroma, D3DFORMAT target) { vout_display_sys_t *sys = vd->sys; + bool hardware_scale_ok = !(vd->fmt.i_visible_width & 1) && !(vd->fmt.i_visible_height & 1); for (unsigned pass = 0; pass < 2; pass++) { const vlc_fourcc_t *list; - if (pass == 0 && sys->allow_hw_yuv && vlc_fourcc_IsYUV(chroma)) + if (pass == 0 && hardware_scale_ok && sys->allow_hw_yuv && vlc_fourcc_IsYUV(chroma)) list = vlc_fourcc_GetYUVFallback(chroma); else if (pass == 1) list = vlc_fourcc_GetRGBFallback(chroma); _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
