[FFmpeg-devel] [PATCH 1/2] hwcontext_d3d11: Add BGR0 support

Mark Thompson sw at jkqxz.net
Mon Nov 27 15:43:19 EET 2023


On 22/10/2023 15:54, Mark Thompson wrote:
> The 8-bit four-component DXGI container is also used for three-component
> RGB without alpha.
> ---
> This list is only used for AV->DXGI mapping, so it doesn't matter that there are duplicate DXGI formats in the list.
> 
>   libavutil/hwcontext_d3d11va.c | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/libavutil/hwcontext_d3d11va.c b/libavutil/hwcontext_d3d11va.c
> index cc8c97d2b6..1d249f2088 100644
> --- a/libavutil/hwcontext_d3d11va.c
> +++ b/libavutil/hwcontext_d3d11va.c
> @@ -86,6 +86,7 @@ static const struct {
>   } supported_formats[] = {
>       { DXGI_FORMAT_NV12,         AV_PIX_FMT_NV12 },
>       { DXGI_FORMAT_P010,         AV_PIX_FMT_P010 },
> +    { DXGI_FORMAT_B8G8R8A8_UNORM,    AV_PIX_FMT_BGR0 },
>       { DXGI_FORMAT_B8G8R8A8_UNORM,    AV_PIX_FMT_BGRA },
>       { DXGI_FORMAT_R10G10B10A2_UNORM, AV_PIX_FMT_X2BGR10 },
>       { DXGI_FORMAT_R16G16B16A16_FLOAT, AV_PIX_FMT_RGBAF16 },

Ping for set.

Thanks,

- Mark


More information about the ffmpeg-devel mailing list