[vlc-commits] direct3d11: fix aspect ratio handling
Steve Lhomme
git at videolan.org
Thu Aug 27 16:20:56 CEST 2020
vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Thu Aug 27 13:45:57 2020 +0200| [05ed57be9c2c21a8822d5458f0833201552f1429] | committer: Steve Lhomme
direct3d11: fix aspect ratio handling
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=05ed57be9c2c21a8822d5458f0833201552f1429
---
modules/video_output/win32/direct3d11.c | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/modules/video_output/win32/direct3d11.c b/modules/video_output/win32/direct3d11.c
index d8b76e800d..b6881ecc8b 100644
--- a/modules/video_output/win32/direct3d11.c
+++ b/modules/video_output/win32/direct3d11.c
@@ -278,10 +278,10 @@ static void UpdateSize(vout_display_t *vd)
D3D11_UpdateViewport( &sys->picQuad, &rect_dst, sys->display.pixelFormat );
RECT source_rect = {
- .left = vd->source.i_x_offset,
- .right = vd->source.i_x_offset + vd->source.i_visible_width,
- .top = vd->source.i_y_offset,
- .bottom = vd->source.i_y_offset + vd->source.i_visible_height,
+ .left = vd->fmt.i_x_offset,
+ .right = vd->fmt.i_x_offset + vd->fmt.i_visible_width,
+ .top = vd->fmt.i_y_offset,
+ .bottom = vd->fmt.i_y_offset + vd->fmt.i_visible_height,
};
d3d11_device_lock( sys->d3d_dev );
@@ -1076,10 +1076,10 @@ static int Direct3D11CreateFormatResources(vout_display_t *vd, const video_forma
}
RECT source_rect = {
- .left = vd->source.i_x_offset,
- .right = vd->source.i_x_offset + vd->source.i_visible_width,
- .top = vd->source.i_y_offset,
- .bottom = vd->source.i_y_offset + vd->source.i_visible_height,
+ .left = vd->fmt.i_x_offset,
+ .right = vd->fmt.i_x_offset + vd->fmt.i_visible_width,
+ .top = vd->fmt.i_y_offset,
+ .bottom = vd->fmt.i_y_offset + vd->fmt.i_visible_height,
};
if (!D3D11_UpdateQuadPosition(vd, sys->d3d_dev, &sys->picQuad, &source_rect, vd->source.orientation))
{
More information about the vlc-commits
mailing list