[FFmpeg-devel] [PATCH v3 5/5] lavc: implement a Vulkan-based VC-2 encoder Implements a Vulkan based dirac encoder. Supports Haar and Legall wavelets and should work with all wavelet depths.

Lynne dev at lynne.ee
Fri Apr 18 04:11:13 EEST 2025


On 18/04/2025 01:55, IndecisiveTurtle wrote:
> From: IndecisiveTurtle <geoster3d at gmail.com>
> 
> Performance wise, encoding a 1080p 1-minute video is performed in about 2.5 minutes with the cpu encoder running on my Ryzen 5 4600H, while it takes about 30 seconds on my NVIDIA GTX 1650
> 
> Haar shader has a subgroup optimized variant that applies when configured wavelet depth allows it
> ---
>   configure                                    |   1 +
>   libavcodec/Makefile                          |   3 +
>   libavcodec/allcodecs.c                       |   1 +
>   libavcodec/vc2enc_vulkan.c                   | 959 +++++++++++++++++++
>   libavcodec/vulkan/vc2_dwt_haar.comp          |  82 ++
>   libavcodec/vulkan/vc2_dwt_haar_subgroup.comp |  75 ++
>   libavcodec/vulkan/vc2_dwt_hor_legall.comp    |  82 ++
>   libavcodec/vulkan/vc2_dwt_upload.comp        |  96 ++
>   libavcodec/vulkan/vc2_dwt_ver_legall.comp    |  78 ++
>   libavcodec/vulkan/vc2_encode.comp            | 169 ++++
>   libavcodec/vulkan/vc2_slice_sizes.comp       | 170 ++++
>   11 files changed, 1716 insertions(+)
>   create mode 100644 libavcodec/vc2enc_vulkan.c
>   create mode 100644 libavcodec/vulkan/vc2_dwt_haar.comp
>   create mode 100644 libavcodec/vulkan/vc2_dwt_haar_subgroup.comp
>   create mode 100644 libavcodec/vulkan/vc2_dwt_hor_legall.comp
>   create mode 100644 libavcodec/vulkan/vc2_dwt_upload.comp
>   create mode 100644 libavcodec/vulkan/vc2_dwt_ver_legall.comp
>   create mode 100644 libavcodec/vulkan/vc2_encode.comp
>   create mode 100644 libavcodec/vulkan/vc2_slice_sizes.comp

LGTM.
Planning to push this tomorrow unless there are objections.


More information about the ffmpeg-devel mailing list