[vlc-devel] [PATCH] d3d11_deinterlace: set the source and destination rectangle
Steve Lhomme
robux4 at videolabs.io
Tue Oct 31 14:10:53 CET 2017
This way it doesn't try to use extra parts of the texture for interlacing.
Fixes #18775 and possibly #18928
---
modules/video_output/win32/d3d11_deinterlace.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/modules/video_output/win32/d3d11_deinterlace.c b/modules/video_output/win32/d3d11_deinterlace.c
index 26431f5a66..52f8323b0f 100644
--- a/modules/video_output/win32/d3d11_deinterlace.c
+++ b/modules/video_output/win32/d3d11_deinterlace.c
@@ -183,6 +183,16 @@ static int RenderPic( filter_t *p_filter, picture_t *p_outpic, picture_t *p_pic,
stream.pInputSurface = p_sys_src->processorInput;
}
+ RECT srcRect;
+ srcRect.left = 0;
+ srcRect.top = 0;
+ srcRect.right = p_pic->format.i_visible_width;
+ srcRect.bottom = p_pic->format.i_visible_height;
+ ID3D11VideoContext_VideoProcessorSetStreamSourceRect(p_sys->d3dvidctx, p_sys->videoProcessor,
+ 0, TRUE, &srcRect);
+ ID3D11VideoContext_VideoProcessorSetStreamDestRect(p_sys->d3dvidctx, p_sys->videoProcessor,
+ 0, TRUE, &srcRect);
+
hr = ID3D11VideoContext_VideoProcessorBlt(p_sys->d3dvidctx, p_sys->videoProcessor,
p_sys->processorOutput,
0, 1, &stream);
--
2.14.2
More information about the vlc-devel
mailing list