Re: [FFmpeg-devel] [PATCH v3 10/10] ffv1enc: add a Vulkan encoder

2024-11-17 Thread Lynne via ffmpeg-devel

On 11/17/24 13:38, Jerome Martinez wrote:


Le 17/11/2024 à 01:19, Lynne via ffmpeg-devel a écrit :

I'll push the patchset tomorrow if there are no more comments to fix.


As it silently creates bad streams with some pix_fmts, please mandate 
-strict -2 for the moment.



I would like to point out that it only happens under extreme conditions that

the encoder itself, sofware and hardware, *warns* that the output may be 
bad,


and second, -strict -2 simply leads to users to cargo-culting command line

parameters for decades. I'm serious, 9 years later an people still use 
-strict -2 -acodec aac.


As such, I'm still debating adding this requirement, but as the issues 
have to be


solved one way or another, and we're still far off from a release, I'm 
considering


being on the side of "no".
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-devel] [PATCH v3 10/10] ffv1enc: add a Vulkan encoder

2024-11-17 Thread Jerome Martinez

Le 17/11/2024 à 01:19, Lynne via ffmpeg-devel a écrit :

I'll push the patchset tomorrow if there are no more comments to fix.


As it silently creates bad streams with some pix_fmts, please mandate 
-strict -2 for the moment.

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-devel] [PATCH v3 10/10] ffv1enc: add a Vulkan encoder

2024-11-16 Thread Lynne via ffmpeg-devel

On 11/15/24 05:50, Lynne wrote:

This commit implements a standard, compliant, version 3 and version 4
FFv1 encoder, entirely in Vulkan. The encoder is written in standard
GLSL and requires a Vulkan 1.3 supporting GPU with the BDA extension.

The encoder can use any amount of slices, but nominally, should use
32x32 slices (1024 in total) to maximize parallelism.

All features are supported, as well as all pixel formats.
This includes:
  - Rice
  - Range coding with a custom quantization table
  - PCM encoding

CRC calculation is also massively parallelized on the GPU.

Encoding of unaligned dimensions on subsampled data requires
version 4, or requires oversizing the image to 64-pixel alignment
and cropping out the padding via container flags.
---
  configure  |1 +
  libavcodec/Makefile|1 +
  libavcodec/allcodecs.c |1 +
  libavcodec/ffv1enc.c   |2 +-
  libavcodec/ffv1enc_vulkan.c| 1598 
  libavcodec/vulkan/Makefile |8 +
  libavcodec/vulkan/common.comp  |  182 +++
  libavcodec/vulkan/ffv1_common.comp |   75 ++
  libavcodec/vulkan/ffv1_enc.comp|   67 +
  libavcodec/vulkan/ffv1_enc_ac.comp |   83 ++
  libavcodec/vulkan/ffv1_enc_common.comp |  101 ++
  libavcodec/vulkan/ffv1_enc_rct.comp|   85 ++
  libavcodec/vulkan/ffv1_enc_rgb.comp|   83 ++
  libavcodec/vulkan/ffv1_enc_setup.comp  |  153 +++
  libavcodec/vulkan/ffv1_enc_vlc.comp|  112 ++
  libavcodec/vulkan/ffv1_reset.comp  |   55 +
  libavcodec/vulkan/ffv1_vlc.comp|  122 ++
  libavcodec/vulkan/rangecoder.comp  |  190 +++
  18 files changed, 2918 insertions(+), 1 deletion(-)
  create mode 100644 libavcodec/ffv1enc_vulkan.c
  create mode 100644 libavcodec/vulkan/common.comp
  create mode 100644 libavcodec/vulkan/ffv1_common.comp
  create mode 100644 libavcodec/vulkan/ffv1_enc.comp
  create mode 100644 libavcodec/vulkan/ffv1_enc_ac.comp
  create mode 100644 libavcodec/vulkan/ffv1_enc_common.comp
  create mode 100644 libavcodec/vulkan/ffv1_enc_rct.comp
  create mode 100644 libavcodec/vulkan/ffv1_enc_rgb.comp
  create mode 100644 libavcodec/vulkan/ffv1_enc_setup.comp
  create mode 100644 libavcodec/vulkan/ffv1_enc_vlc.comp
  create mode 100644 libavcodec/vulkan/ffv1_reset.comp
  create mode 100644 libavcodec/vulkan/ffv1_vlc.comp
  create mode 100644 libavcodec/vulkan/rangecoder.comp



I'll push the patchset tomorrow if there are no more comments to fix.

We should definitely add FATE tests for such implementations.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".