Re: [FFmpeg-devel] [PATCH 1/3] lavu/hwcontext_vaapi: Add option to allow to specify vendor id when init hw device

2024-08-09 Thread Xiang, Haihao
On Ma, 2024-08-05 at 02:14 +, Xiang, Haihao wrote: > On Vr, 2024-07-26 at 09:05 +0800, fei.w.wang-at-intel@ffmpeg.org wrote: > > From: Fei Wang > > > > Vendor id will help to select desired device in case of kernel driver is > > unknow or unsupported, for vendor may support different kern

Re: [FFmpeg-devel] PATCH: Force vaapi image formats to NV12-only

2024-08-09 Thread Lluís Batlle i Rossell
On Fri, Aug 09, 2024 at 11:49:54AM +0800, Zhao Zhili wrote: > > vaapi drivers often lack proper image converesions and not all > > situations allow vagetimage or vaputimage with the image formats > > reported by the api. nv12 seems allowed in all circumstances. > > > > with this change now one can

[FFmpeg-devel] [PATCH v2] avcodec/mediacodecdec: call MediaCodec.stop on close

2024-08-09 Thread sfan5
revised commit message as suggested From 9aa111c400cc3245edf870c431a5e271432ef5f2 Mon Sep 17 00:00:00 2001 From: sfan5 Date: Wed, 7 Aug 2024 17:48:06 +0200 Subject: [PATCH v2] avcodec/mediacodecdec: call MediaCodec.stop on close Usually the MediaCodec context will be released immediately, or it

[FFmpeg-devel] [PATCH] libavcodec/arm/mlpdsp_armv5te: fix label format to work with binutils 2.43

2024-08-09 Thread Ross Burton
binutils 2.43 has stricter validation for labels[1] and results in errors when building ffmpeg for armv5: src/libavcodec/arm/mlpdsp_armv5te.S:232: Error: junk at end of line, first unrecognized character is `0' Remove the leading zero in the "01" label to resolve this error. [1] https://source

[FFmpeg-devel] [PATCH 1/4] swscale: add nv24/nv42 to yuv420p unscaled converter

2024-08-09 Thread Ramiro Polla
--- libswscale/swscale_unscaled.c | 45 +++ 1 file changed, 45 insertions(+) diff --git a/libswscale/swscale_unscaled.c b/libswscale/swscale_unscaled.c index a5c9917799..239258ab8c 100644 --- a/libswscale/swscale_unscaled.c +++ b/libswscale/swscale_unscaled.c @@ -2

[FFmpeg-devel] [PATCH 2/4] checkasm/yuv2yuv: add tests for semiplanar unscaled converters

2024-08-09 Thread Ramiro Polla
--- tests/checkasm/Makefile | 2 +- tests/checkasm/checkasm.c | 1 + tests/checkasm/checkasm.h | 1 + tests/checkasm/sw_yuv2yuv.c | 131 4 files changed, 134 insertions(+), 1 deletion(-) create mode 100644 tests/checkasm/sw_yuv2yuv.c diff --git

[FFmpeg-devel] [PATCH 3/4] swscale: export ff_copyPlane so it may be used by simd code

2024-08-09 Thread Ramiro Polla
--- libswscale/swscale_internal.h | 4 libswscale/swscale_unscaled.c | 42 +-- 2 files changed, 25 insertions(+), 21 deletions(-) diff --git a/libswscale/swscale_internal.h b/libswscale/swscale_internal.h index e5610161d0..50127d288f 100644 --- a/libswscale/s

[FFmpeg-devel] [PATCH 4/4] swscale/aarch64: add nv24/nv42 to yuv420p unscaled converter

2024-08-09 Thread Ramiro Polla
checkasm --bench for Raspberry Pi 5 Model B Rev 1.0: nv24_yuv420p_128_c: 423.0 nv24_yuv420p_128_neon: 115.7 nv24_yuv420p_1920_c: 5939.5 nv24_yuv420p_1920_neon: 1339.7 nv42_yuv420p_128_c: 423.2 nv42_yuv420p_128_neon: 115.7 nv42_yuv420p_1920_c: 5907.5 nv42_yuv420p_1920_neon: 1342.5 --- libswscale/aa

[FFmpeg-devel] [PATCH 1/2] checkasm/mpegvideoencdsp: add pix_sum and pix_norm1

2024-08-09 Thread Ramiro Polla
--- tests/checkasm/Makefile | 1 + tests/checkasm/checkasm.c| 3 ++ tests/checkasm/checkasm.h| 1 + tests/checkasm/mpegvideoencdsp.c | 77 4 files changed, 82 insertions(+) create mode 100644 tests/checkasm/mpegvideoencdsp.c diff --git

[FFmpeg-devel] [PATCH 2/2] avcodec/mpegvideoencdsp: add aarch64 pix_sum and pix_norm1

2024-08-09 Thread Ramiro Polla
checkasm --bench for Raspberry Pi 5 Model B Rev 1.0: pix_norm1_c: 235.7 pix_norm1_neon: 40.7 pix_sum_c: 249.0 pix_sum_neon: 22.0 --- libavcodec/aarch64/Makefile | 2 + libavcodec/aarch64/mpegvideoencdsp_init.c | 39 + libavcodec/aarch64/mpegvideoencdsp_neon.S | 102 +++

[FFmpeg-devel] [PATCH 2/4] lavc/vp9dsp: R-V V mc bilin hv

2024-08-09 Thread uk7b
From: sunyuechi C908 X60 vp9_avg_bilin_4hv_8bpp_c : 10.79.5 vp9_avg_bilin_4hv_8bpp_rvv_i32 :4.03.5 vp9_avg_bilin_8hv_8bpp_c : 38.5 34.2 vp9_avg_bilin_8h

[FFmpeg-devel] [PATCH 3/4] lavc/vp9dsp: R-V V mc tap h v

2024-08-09 Thread uk7b
From: sunyuechi C908 X60 vp9_avg_8tap_smooth_4h_8bpp_c : 12.7 11.2 vp9_avg_8tap_smooth_4h_8bpp_rvv_i32:4.74.2 vp9_avg_8tap_smooth_4v_8bpp_c : 29.7 12.5 vp9_avg_8tap_smo

[FFmpeg-devel] [PATCH 4/4] lavc/vp9dsp: R-V V mc tap hv

2024-08-09 Thread uk7b
From: sunyuechi C908 X60 vp9_avg_8tap_smooth_4hv_8bpp_c : 32.0 28.0 vp9_avg_8tap_smooth_4hv_8bpp_rvv_i32 : 15.0 13.2 vp9_avg_8tap_smooth_8hv_8bpp_c : 98.0 86.2 vp9_avg_8tap_smo

Re: [FFmpeg-devel] [PATCH 2/4] lavc/vp9dsp: R-V V mc bilin hv

2024-08-09 Thread flow gg
> That seems suboptimal and unnecessary. Updated it, there is no longer any vmv. 于2024年8月9日周五 22:24写道: > From: sunyuechi > > C908 X60 > vp9_avg_bilin_4hv_8bpp_c : 10.79.5 > vp9_avg_bilin_4hv_8bpp_rvv_i32

[FFmpeg-devel] [PATCH 1/4] lavc/vp9dsp: R-V V mc bilin h v

2024-08-09 Thread uk7b
From: sunyuechi C908 X60 vp9_avg_bilin_4h_8bpp_c:5.54.7 vp9_avg_bilin_4h_8bpp_rvv_i32 :1.71.5 vp9_avg_bilin_4v_8bpp_c:5.54.7 vp9_avg_bilin_4v

[FFmpeg-devel] [PATCH] vulkan: add support for encode feedback queries

2024-08-09 Thread Lynne via ffmpeg-devel
--- libavutil/vulkan.c | 26 -- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/libavutil/vulkan.c b/libavutil/vulkan.c index 7b45e43a89..13344b7aed 100644 --- a/libavutil/vulkan.c +++ b/libavutil/vulkan.c @@ -281,6 +281,15 @@ int ff_vk_exec_pool_init(FFVulk

[FFmpeg-devel] [PATCH] lavc/mpegvideoencdsp: R-V V pix_sum

2024-08-09 Thread Rémi Denis-Courmont
T-Head C908: pix_sum_c: 332.2 pix_sum_rvv_i64: 91.2 SpacemiT X60: pix_sum_c: 321.2 pix_sum_rvv_i64: 60.9 --- libavcodec/mpegvideoencdsp.c| 2 ++ libavcodec/mpegvideoencdsp.h| 2 ++ libavcodec/riscv/Makefile | 2 ++ libavcodec/riscv/mpegvideoencds

Re: [FFmpeg-devel] [PATCH] lavc/mpegvideoencdsp: R-V V pix_sum

2024-08-09 Thread Rémi Denis-Courmont
Le perjantaina 9. elokuuta 2024, 22.07.25 EEST Rémi Denis-Courmont a écrit : > T-Head C908: > pix_sum_c: 332.2 > pix_sum_rvv_i64: 91.2 > > SpacemiT X60: > pix_sum_c: 321.2 > pix_sum_rvv_i64: 60.9 > --- > libavcodec/mpegvideoencdsp.c| 2 ++ > libavcodec/mpegvideoencdsp.h

Re: [FFmpeg-devel] [PATCH] lavc/mpegvideoencdsp: R-V V pix_sum

2024-08-09 Thread Rémi Denis-Courmont
Le perjantaina 9. elokuuta 2024, 22.23.43 EEST Rémi Denis-Courmont a écrit : > Le perjantaina 9. elokuuta 2024, 22.07.25 EEST Rémi Denis-Courmont a écrit : > > T-Head C908: > > pix_sum_c: 332.2 > > pix_sum_rvv_i64: 91.2 > > > > SpacemiT X60: > > pix_sum_c: 321.2 > > pix_sum_rvv_i64: 60.9

Re: [FFmpeg-devel] [PATCH 5/6] tools/target_dec_fuzzer: Use av_buffer_allocz() to avoid missing slices to have unpredictable content

2024-08-09 Thread Michael Niedermayer
Hi On Fri, Aug 09, 2024 at 03:56:42AM +0200, Kacper Michajlow wrote: > On Fri, 9 Aug 2024 at 00:06, Michael Niedermayer > wrote: > > > > On Thu, Aug 08, 2024 at 02:13:12PM -0300, James Almer wrote: [...] > > If decoders are fed with uninitialized buffers thats a > > security issue because there

Re: [FFmpeg-devel] [PATCH] avformat/vpk: fix divide by zero

2024-08-09 Thread Michael Niedermayer
On Wed, Aug 07, 2024 at 03:42:46PM +0200, Kacper Michajłow wrote: > Can happen after calling avformat_find_stream_info() when the codec > fails to open, but return value is 0 and subsequent uses of this context > have zero value in channel number. > > Found by OSS-Fuzz. > > Signed-off-by: Kacper

Re: [FFmpeg-devel] [PATCH] lavc/ffv1dec: fix races in accessing FFV1SliceContext.slice_damaged

2024-08-09 Thread Michael Niedermayer
On Thu, Aug 01, 2024 at 04:33:21PM +0200, Anton Khirnov wrote: > That variable is shared between frame threads in the same defective way > described in the previous commit. Fix it by adding a RefStruct-managed > arrays of flags that is propagated across frame threads in the standard > manner. > >

Re: [FFmpeg-devel] [PATCH] avformat/vpk: fix divide by zero

2024-08-09 Thread Kacper Michajlow
On Fri, 9 Aug 2024 at 22:51, Michael Niedermayer wrote: > > On Wed, Aug 07, 2024 at 03:42:46PM +0200, Kacper Michajłow wrote: > > Can happen after calling avformat_find_stream_info() when the codec > > fails to open, but return value is 0 and subsequent uses of this context > > have zero value in

Re: [FFmpeg-devel] [PATCH 37/39] lavc/hevcdec: use a ContainerFifo to hold frames scheduled for output

2024-08-09 Thread Andreas Rheinhardt
Anton Khirnov: > Instead of a single AVFrame. > > Will be useful in future commits, where we will want to produce multiple > output frames for a single coded frame. > --- > libavcodec/Makefile | 2 +- > libavcodec/hevc/hevcdec.c | 30 -- > libavcodec/hevc/hevcde

Re: [FFmpeg-devel] [PATCH 36/39] lavc: add private container FIFO API

2024-08-09 Thread Andreas Rheinhardt
Anton Khirnov: > It provides a FIFO for "container" objects like AVFrame/AVPacket and > features an integrated FFRefStructPool-based pool to avoid allocating an > freeing them repeatedly. > --- > libavcodec/container_fifo.c | 195 > libavcodec/container_fifo.h

[FFmpeg-devel] [PATCH] avcodec/videotoolboxenc: always release supported_props

2024-08-09 Thread gnattu via ffmpeg-devel
In vtenc_populate_extradata, supported_props should always be released to avoid memory leak. Regression from cd2f8a22e94700c68b1de7968df11e8bebfd315b Signed-off-by: gnattu --- libavcodec/videotoolboxenc.c | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/libavco

[FFmpeg-devel] [PATCH] avutil/hwcontext_videotoolbox: silence warning for RGB

2024-08-09 Thread gnattu via ffmpeg-devel
Hardware frames with RGB colorspace will not have a YCbCrMatrixKey. Currently, it will spam the console with warning if rgb frame is uploaded. Signed-off-by: Gnattu OC --- libavutil/hwcontext_videotoolbox.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/hwcontext_v