[vlc-commits] d3d11_shaders: add missing DXGI formats to detect RGB formats

Steve Lhomme git at videolan.org
Tue Dec 17 08:26:58 CET 2019


vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Mon Dec 16 11:17:58 2019 +0100| [2b9796197a44490279d3c0915abe4e0062f3d818] | committer: Steve Lhomme

d3d11_shaders: add missing DXGI formats to detect RGB formats

Rather than excluding formats, we might just include them.

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

 modules/video_output/win32/d3d11_shaders.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/modules/video_output/win32/d3d11_shaders.c b/modules/video_output/win32/d3d11_shaders.c
index 0f37b71fa5..1f943953c2 100644
--- a/modules/video_output/win32/d3d11_shaders.c
+++ b/modules/video_output/win32/d3d11_shaders.c
@@ -202,7 +202,9 @@ bool IsRGBShader(const d3d_format_t *cfg)
 {
     return cfg->resourceFormat[0] != DXGI_FORMAT_R8_UNORM &&
            cfg->resourceFormat[0] != DXGI_FORMAT_R16_UNORM &&
-           cfg->formatTexture != DXGI_FORMAT_YUY2;
+           cfg->formatTexture != DXGI_FORMAT_YUY2 &&
+           cfg->formatTexture != DXGI_FORMAT_AYUV &&
+           cfg->formatTexture != DXGI_FORMAT_420_OPAQUE;
 }
 
 static HRESULT CompileTargetShader(vlc_object_t *o, d3d11_handle_t *hd3d, bool legacy_shader,



More information about the vlc-commits mailing list