[vlc-commits] kms: use the source format to create the local picture

Steve Lhomme git at videolan.org
Mon Sep 7 08:16:57 CEST 2020


vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Wed Sep  2 09:28:29 2020 +0200| [40e718ea7944c997fbdc4b810a865f2064a3995b] | committer: Steve Lhomme

kms: use the source format to create the local picture

At this stage the only difference betweeen vd->source and vd->fmt is the SAR.
Since this local picture is only use to copy planes, the SAR is never used.

It's possible that the original code is wrong as it doesn't take in account the
"kms-vlc-chroma" forced chroma that the core will assume is used.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=40e718ea7944c997fbdc4b810a865f2064a3995b
---

 modules/video_output/kms.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/video_output/kms.c b/modules/video_output/kms.c
index 6de37d3372..e74ff5a3da 100644
--- a/modules/video_output/kms.c
+++ b/modules/video_output/kms.c
@@ -578,7 +578,7 @@ static int OpenDisplay(vout_display_t *vd)
 
     picture_resource_t rsc = { 0 };
 
-    sys->picture = picture_NewFromResource(vd->fmt, &rsc);
+    sys->picture = picture_NewFromResource(vd->source, &rsc);
 
     if (!sys->picture)
         goto err_out;



More information about the vlc-commits mailing list