From 030800905b117a7ac650c90c9cfd1c104e453d04 Mon Sep 17 00:00:00 2001 From: Seungha Yang Date: Fri, 24 Nov 2023 00:17:02 +0900 Subject: [PATCH] d3d11device: Remove outdated comment We do support 4:2:2 YUV formats using compute shader now Part-of: --- .../gst-libs/gst/d3d11/gstd3d11device.cpp | 55 ------------------- 1 file changed, 55 deletions(-) diff --git a/subprojects/gst-plugins-bad/gst-libs/gst/d3d11/gstd3d11device.cpp b/subprojects/gst-plugins-bad/gst-libs/gst/d3d11/gstd3d11device.cpp index c23ad14e6d..c72d9def7b 100644 --- a/subprojects/gst-plugins-bad/gst-libs/gst/d3d11/gstd3d11device.cpp +++ b/subprojects/gst-plugins-bad/gst-libs/gst/d3d11/gstd3d11device.cpp @@ -625,61 +625,6 @@ gst_d3d11_device_setup_format_table (GstD3D11Device * self) priv->format_table[format.format] = format; } - - /* FIXME: d3d11 sampler doesn't support packed-and-subsampled formats - * very well (and it's really poorly documented). - * As per observation, d3d11 samplers seems to be dropping the second - * Y componet from "Y0-U0-Y1-V0" pair which results in bad visual quality - * than 4:2:0 subsampled formats. We should revisit this later */ - - /* TODO: The best would be using d3d11 compute shader to handle this kinds of - * samples but comute shader is not implemented yet by us. - * - * Another simple approach is using d3d11 video processor, - * but capability will be very device dependent because it depends on - * GPU vendor's driver implementation, moreover, software fallback does - * not support d3d11 video processor. So it's not reliable in this case */ -#if 0 - /* NOTE: packted yuv 4:2:2 YUY2, UYVY, and VYUY formats are not natively - * supported render target view formats - * (i.e., cannot be output format of shader pipeline) */ - priv->format_table[n_formats].format = GST_VIDEO_FORMAT_YUY2; - if (can_support_format (self, DXGI_FORMAT_YUY2, - D3D11_FORMAT_SUPPORT_SHADER_SAMPLE)) { - priv->format_table[n_formats].resource_format[0] = - DXGI_FORMAT_R8G8B8A8_UNORM; - priv->format_table[n_formats].dxgi_format = DXGI_FORMAT_YUY2; - } else { - /* If DXGI_FORMAT_YUY2 format is not supported, use this format, - * it's analogous to YUY2 */ - priv->format_table[n_formats].resource_format[0] = - DXGI_FORMAT_G8R8_G8B8_UNORM; - } - n_formats++; - - /* No native DXGI format available for UYVY */ - priv->format_table[n_formats].format = GST_VIDEO_FORMAT_UYVY; - priv->format_table[n_formats].resource_format[0] = - DXGI_FORMAT_R8G8_B8G8_UNORM; - n_formats++; - - /* No native DXGI format available for VYUY */ - priv->format_table[n_formats].format = GST_VIDEO_FORMAT_VYUY; - priv->format_table[n_formats].resource_format[0] = - DXGI_FORMAT_R8G8_B8G8_UNORM; - n_formats++; - - /* Y210 and Y410 formats cannot support rtv */ - priv->format_table[n_formats].format = GST_VIDEO_FORMAT_Y210; - priv->format_table[n_formats].resource_format[0] = - DXGI_FORMAT_R16G16B16A16_UNORM; - if (can_support_format (self, DXGI_FORMAT_Y210, - D3D11_FORMAT_SUPPORT_SHADER_SAMPLE)) - priv->format_table[n_formats].dxgi_format = DXGI_FORMAT_Y210; - else - priv->format_table[n_formats].dxgi_format = DXGI_FORMAT_UNKNOWN; - n_formats++; -#endif } static void