Re: [FFmpeg-devel] [PATCH 8/8] avfilter/vf_scale: Cleanup some checks

2024-07-09 Thread Anton Khirnov
Quoting Michael Niedermayer (2024-07-09 00:24:10) > Fixes: CID1513722 Operands don't affect result > > Sponsored-by: Sovereign Tech Fund > Signed-off-by: Michael Niedermayer > --- > libavfilter/vf_scale.c | 6 ++ > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git

Re: [FFmpeg-devel] [PATCH 1/2] hwcontext_vulkan: add a new mechanism to expose used queue families

2024-07-09 Thread Anton Khirnov
Quoting Lynne via ffmpeg-devel (2024-07-09 03:07:12) > @@ -151,6 +162,17 @@ typedef struct AVVulkanDeviceContext { > * Similar to lock_queue(), unlocks a queue. Must only be called after > locking. > */ > void (*unlock_queue)(struct AVHWDeviceContext *ctx, uint32_t >

Re: [FFmpeg-devel] [PATCH] lavc/vaapi_{decode, av1}: Fix memory leak in fail codepath

2024-07-09 Thread Xiang, Haihao
On Ma, 2024-07-01 at 16:36 +0800, fei.w.wang-at-intel@ffmpeg.org wrote: > From: Fei Wang > > Signed-off-by: Fei Wang > --- >  libavcodec/vaapi_av1.c    | 9 + >  libavcodec/vaapi_decode.c | 5 +++-- >  2 files changed, 8 insertions(+), 6 deletions(-) > > diff --git

Re: [FFmpeg-devel] videotoolbox increases min target to macOS 12

2024-07-09 Thread Gnattu OC via ffmpeg-devel
> On Jul 9, 2024, at 13:47, Helmut K. C. Tessarek wrote: > > I'm very sorry to bother the dev list with this, but this is the 2nd time in > less than a year that the min version of macOS was changed in videotoolbox. > > 2023-09-22: macOS 10.13 > now: macOS 12 > > Will ffmpeg soon only

Re: [FFmpeg-devel] [PATCH v2] doc/examples/vaapi_encode: Try to check fwrite() for failure

2024-07-09 Thread Xiang, Haihao
On Di, 2024-07-02 at 01:47 +0200, Michael Niedermayer wrote: > Fixes: CID1604548 Unused value > > Sponsored-by: Sovereign Tech Fund > Signed-off-by: Michael Niedermayer > --- >  doc/examples/vaapi_encode.c | 4 >  1 file changed, 4 insertions(+) > > diff --git a/doc/examples/vaapi_encode.c

Re: [FFmpeg-devel] [PATCH 2/6] avcodec/vaapi_h264: Do not store our error code in VASliceParameterBufferH264

2024-07-09 Thread Xiang, Haihao
On So, 2024-07-07 at 20:47 +0200, Michael Niedermayer wrote: > I am not sure this is possible (thus this requires review) > > Fixes: CID1604570 Overflowed constant > > Sponsored-by: Sovereign Tech Fund > Signed-off-by: Michael Niedermayer > --- >  libavcodec/vaapi_h264.c | 6 +- >  1 file

[FFmpeg-devel] videotoolbox increases min target to macOS 12

2024-07-08 Thread Helmut K. C. Tessarek
I'm very sorry to bother the dev list with this, but this is the 2nd time in less than a year that the min version of macOS was changed in videotoolbox. 2023-09-22: macOS 10.13 now: macOS 12 Will ffmpeg soon only compile on the current release of macOS (with videtoolbox support)? While I

[FFmpeg-devel] [PATCH 2/2] avformat/movenc: support writing cropping values

2024-07-08 Thread James Almer
Finishes implementing ticket #7437. Signed-off-by: James Almer --- libavformat/movenc.c| 56 +++-- tests/ref/fate/copy-trac236 | 16 +-- 2 files changed, 50 insertions(+), 22 deletions(-) diff --git a/libavformat/movenc.c b/libavformat/movenc.c

[FFmpeg-devel] [PATCH 1/2] avformat/mov: export cropping values from clap boxes

2024-07-08 Thread James Almer
Addresses part of ticket #7437. Signed-off-by: James Almer --- libavformat/mov.c | 78 + tests/ref/fate/aic | 32 +- tests/ref/fate/prores-transparency | 4 +- tests/ref/fate/prores-transparency_skip | 4 +- 4

[FFmpeg-devel] [PATCH 2/2] vulkan: use the new queue family mechanism

2024-07-08 Thread Lynne via ffmpeg-devel
--- libavutil/vulkan.c | 68 ++ libavutil/vulkan.h | 2 +- 2 files changed, 21 insertions(+), 49 deletions(-) diff --git a/libavutil/vulkan.c b/libavutil/vulkan.c index e0208c5a7c..d98e863711 100644 --- a/libavutil/vulkan.c +++ b/libavutil/vulkan.c @@

[FFmpeg-devel] [PATCH 1/2] hwcontext_vulkan: add a new mechanism to expose used queue families

2024-07-08 Thread Lynne via ffmpeg-devel
The issue with the old mechanism is that we had to introduce new API each time we needed a new queue family, and all the queue families were functionally fixed to a given purpose. Nvidia's GPUs are able to handle video encoding and compute on the same queue, which results in a speedup when

Re: [FFmpeg-devel] [PATCH 2/2] avutil/executor: Fix stack overflow due to recursive call

2024-07-08 Thread Timo Rothenpieler
On 08.07.2024 17:32, Zhao Zhili wrote: On Jul 8, 2024, at 22:07, Timo Rothenpieler wrote: On 08.07.2024 09:43, Zhao Zhili wrote: From: Zhao Zhili av_executor_execute run the task directly when thread is disabled. The task can schedule a new task by call av_executor_execute. This forms an

[FFmpeg-devel] [PATCH 8/8] avfilter/vf_scale: Cleanup some checks

2024-07-08 Thread Michael Niedermayer
Fixes: CID1513722 Operands don't affect result Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavfilter/vf_scale.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/libavfilter/vf_scale.c b/libavfilter/vf_scale.c index bf09196e10d..120ff473f2e

[FFmpeg-devel] [PATCH 7/8] avfilter/vf_scale: Check ff_scale_adjust_dimensions() for failure

2024-07-08 Thread Michael Niedermayer
Helps: CID1513722 Operands don't affect result Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavfilter/vf_scale.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libavfilter/vf_scale.c b/libavfilter/vf_scale.c index 841075193e6..bf09196e10d

[FFmpeg-devel] [PATCH 6/8] avfilter/scale_eval: Use 64bit, check values in ff_scale_adjust_dimensions()

2024-07-08 Thread Michael Niedermayer
Found by reviewing CID1513722 Operands don't affect result Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavfilter/scale_eval.c | 9 ++--- libavfilter/scale_eval.h | 2 +- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/libavfilter/scale_eval.c

[FFmpeg-devel] [PATCH 5/8] avfilter/vf_premultiply: Use AV_PIX_MAX_PLANES

2024-07-08 Thread Michael Niedermayer
Helps: CID1435164 Out-of-bounds read Helps: CID1435165 Out-of-bounds read Helps: CID1435167 Out-of-bounds read Helps: CID1435169 Out-of-bounds read Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavfilter/vf_premultiply.c | 6 +++--- 1 file changed, 3 insertions(+),

[FFmpeg-devel] [PATCH 4/8] avfilter/vf_neighbor_opencl: Use AV_PIX_MAX_PLANES

2024-07-08 Thread Michael Niedermayer
Fix/Robustness/whatever: CID1439575 Out-of-bounds read Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavfilter/vf_neighbor_opencl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavfilter/vf_neighbor_opencl.c

[FFmpeg-devel] [PATCH 3/8] avfilter/vf_lut3d: Check av_scanf()

2024-07-08 Thread Michael Niedermayer
Fixes: CID1604398 Unchecked return value Fixes: CID1604542 Unchecked return value Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavfilter/vf_lut3d.c | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/libavfilter/vf_lut3d.c

[FFmpeg-devel] [PATCH 2/8] avfilter/vf_fftfilt: Remove dead depth code

2024-07-08 Thread Michael Niedermayer
Fixes: CID1509373 Logically dead code Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavfilter/vf_fftfilt.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/libavfilter/vf_fftfilt.c b/libavfilter/vf_fftfilt.c index 1ffbe02ec41..af0e1f51d24

[FFmpeg-devel] [PATCH 1/8] avfilter/vf_elbg: Use unsigned for shifting into the top bit

2024-07-08 Thread Michael Niedermayer
Fixes: part of CID1355110 Overflowed constant Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavfilter/vf_elbg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavfilter/vf_elbg.c b/libavfilter/vf_elbg.c index 732a2c8abfb..dd22da07b6b 100644

Re: [FFmpeg-devel] [PATCH] avcodec/h264_mp4toannexb: Prepend SPS/PPS to buffering period SEI

2024-07-08 Thread Josh Allmann
On Sat, 6 Jul 2024 at 09:37, Michael Niedermayer wrote: > > On Wed, Jul 03, 2024 at 02:05:06PM -0700, Josh Allmann wrote: > > Encoders may emit a buffering period SEI without a corresponding > > SPS/PPS if the SPS/PPS is carried out-of-band, eg with avcc. > > > > During Annex B conversion, this

Re: [FFmpeg-devel] [FFmpeg-cvslog] avfilter/vf_scale: add optional "ref" input

2024-07-08 Thread Michael Niedermayer
Hi On Fri, May 03, 2024 at 12:26:52PM +, Niklas Haas wrote: > ffmpeg | branch: master | Niklas Haas | Wed Apr 24 12:03:00 > 2024 +0200| [bb8044581366fe286e16b14515d873979133dbda] | committer: Niklas > Haas > > avfilter/vf_scale: add optional "ref" input > > This is automatically enabled

[FFmpeg-devel] [PATCH v2] lavu/opt: Mention that AV_OPT_TYPE_IMAGE_SIZE can be unsigned

2024-07-08 Thread Andrew Sayers
TileContext in libavfilter/vf_tile.c and UntileContext in libavfilter/vf_untile.c point to unsigned ints - confirm this is OK. --- Thanks Marcus - have updated my e-mail script to remind myself in future. libavutil/opt.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[FFmpeg-devel] [PATCH] Mention that AV_OPT_TYPE_IMAGE_SIZE can be unsigned

2024-07-08 Thread Andrew Sayers
TileContext in libavfilter/vf_tile.c and UntileContext in libavfilter/vf_untile.c point to unsigned ints - confirm this is OK. --- libavutil/opt.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/opt.h b/libavutil/opt.h index 07e27a9208..9339b1a6ac 100644 ---

Re: [FFmpeg-devel] [PATCH 3/4] avformat/matroskaenc: Only write useful cropping values

2024-07-08 Thread James Almer
On 7/8/2024 2:52 PM, Andreas Rheinhardt wrote: Signed-off-by: Andreas Rheinhardt --- libavformat/matroskaenc.c | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c index 4b91283119..a98d33abf3 100644 ---

Re: [FFmpeg-devel] [PATCH 2/2] avformat/matroskaenc: Fix and simplify check for invalid crop values

2024-07-08 Thread James Almer
On 7/8/2024 2:24 PM, Andreas Rheinhardt wrote: The check "left >= INT_MAX - right" is supposed to check for whether left + right does not overflow/wraparound, but given that left and top are uint32_t INT_MAX - right can already wraparound for big values of right (and ordinary 32-bit ints): If

Re: [FFmpeg-devel] [PATCH] avformat/matroskaenc: Fix potential stack-buffer-overflow

2024-07-08 Thread James Almer
On 7/8/2024 2:09 PM, Andreas Rheinhardt wrote: Forgotten in f194f291d8082134cdce625b0ca3548067428ea9 Signed-off-by: Andreas Rheinhardt --- libavformat/matroskaenc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c

[FFmpeg-devel] [PATCH 4/4] avformat/matroskaenc: Avoid indirection via st->codecpar

2024-07-08 Thread Andreas Rheinhardt
Use the already available AVCodecParameters pointer instead. Shortens lines. Signed-off-by: Andreas Rheinhardt --- libavformat/matroskaenc.c | 34 ++ 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/libavformat/matroskaenc.c

[FFmpeg-devel] [PATCH 3/4] avformat/matroskaenc: Only write useful cropping values

2024-07-08 Thread Andreas Rheinhardt
Signed-off-by: Andreas Rheinhardt --- libavformat/matroskaenc.c | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c index 4b91283119..a98d33abf3 100644 --- a/libavformat/matroskaenc.c +++

Re: [FFmpeg-devel] [PATCH 8/9] avformat/udp: Fix temporary buffer race

2024-07-08 Thread Marton Balint
On Sun, 9 Jun 2024, Michael Niedermayer wrote: Fixes: CID1551679 Data race condition Fixes: CID1551687 Data race condition How is this a data race? Concurrent reading and writing is not supported for UDP as far as I know. Thanks, Marton Sponsored-by: Sovereign Tech Fund

[FFmpeg-devel] [PATCH 2/2] avformat/matroskaenc: Fix and simplify check for invalid crop values

2024-07-08 Thread Andreas Rheinhardt
The check "left >= INT_MAX - right" is supposed to check for whether left + right does not overflow/wraparound, but given that left and top are uint32_t INT_MAX - right can already wraparound for big values of right (and ordinary 32-bit ints): If right == UINT32_MAX, INT_MAX - right is INT_MAX +

[FFmpeg-devel] [PATCH] avformat/matroskaenc: Fix potential stack-buffer-overflow

2024-07-08 Thread Andreas Rheinhardt
Forgotten in f194f291d8082134cdce625b0ca3548067428ea9 Signed-off-by: Andreas Rheinhardt --- libavformat/matroskaenc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c index 216cb48884..e1adc0eba6 100644 ---

Re: [FFmpeg-devel] [PATCH] fate/png: add mDCv read and write test

2024-07-08 Thread Andreas Rheinhardt
Leo Izen: > This test confirms that we can write mDCv chunks and read them back via > the png decoder. It uses an HEVC conformance sample with this metadata > as the base source for the side data in the frames. > > Signed-off-by: Leo Izen > Reported-by: Jan Ekström > --- > tests/fate/image.mak

[FFmpeg-devel] [PATCH] fate/png: add mDCv read and write test

2024-07-08 Thread Leo Izen
This test confirms that we can write mDCv chunks and read them back via the png decoder. It uses an HEVC conformance sample with this metadata as the base source for the side data in the frames. Signed-off-by: Leo Izen Reported-by: Jan Ekström --- tests/fate/image.mak| 5 +

[FFmpeg-devel] [PATCH 2/2] avcodec/decode: Avoid ffcodec()

2024-07-08 Thread Andreas Rheinhardt
Signed-off-by: Andreas Rheinhardt --- libavcodec/decode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/decode.c b/libavcodec/decode.c index cdb682cf69..187b5b6c85 100644 --- a/libavcodec/decode.c +++ b/libavcodec/decode.c @@ -1029,7 +1029,7 @@ enum AVPixelFormat

Re: [FFmpeg-devel] [PATCH 1/2] avcodec/decode: Fix member access within null pointer

2024-07-08 Thread James Almer
On 7/8/2024 12:58 PM, Andreas Rheinhardt wrote: This "works" because the public AVCodecHWConfig is at the beginning of AVCodecHWConfigInternal. Fixes libavcodec/decode.c:1035:61: runtime error: member access within null pointer of type 'const struct AVCodecHWConfigInternal'. Signed-off-by:

[FFmpeg-devel] [PATCH 1/2] avcodec/decode: Fix member access within null pointer

2024-07-08 Thread Andreas Rheinhardt
This "works" because the public AVCodecHWConfig is at the beginning of AVCodecHWConfigInternal. Fixes libavcodec/decode.c:1035:61: runtime error: member access within null pointer of type 'const struct AVCodecHWConfigInternal'. Signed-off-by: Andreas Rheinhardt --- libavcodec/decode.c | 7

Re: [FFmpeg-devel] [PATCH v5] lavc/vvc_mc: R-V V avg w_avg

2024-07-08 Thread Rémi Denis-Courmont
Le maanantaina 1. heinäkuuta 2024, 19.09.01 EEST flow gg a écrit : > I reviewed it again, the purpose of is_w is to limit lmul to a maximum of > 1/4 of vlen, 1/4 of vlen? Do you mean limit to EMUL=1 for EEW=32 and EMUL=1/4 for EEW=8? Limiting LMUL to less than 1 at maximum EEW is useless from a

Re: [FFmpeg-devel] [PATCH 2/2] avutil/executor: Fix stack overflow due to recursive call

2024-07-08 Thread Zhao Zhili
> On Jul 8, 2024, at 22:07, Timo Rothenpieler wrote: > > On 08.07.2024 09:43, Zhao Zhili wrote: >> From: Zhao Zhili >> av_executor_execute run the task directly when thread is disabled. >> The task can schedule a new task by call av_executor_execute. This >> forms an implicit recursive call.

Re: [FFmpeg-devel] [PATCH] MAINTAINERS: add myself as d3d12va_encode maintainer

2024-07-08 Thread Tong Wu
Ping. As the author of d3d12va_encode, I would like to get the access in order maintain the code and add more new features. >-Original Message- >From: wutong1...@outlook.com >Sent: 2024年7月2日 23:23 >To: ffmpeg-devel@ffmpeg.org >Cc: Tong Wu >Subject: [FFmpeg-devel][PATCH] MAINTAINERS:

[FFmpeg-devel] [PATCH 2/2] lavc/d3d12va_encode: trim header alignment at output

2024-07-08 Thread Tong Wu
It is d3d12va's requirement that the FrameStartOffset must be aligned as per hardware limitation. However, we could trim this alignment at output to reduce coded size. A aligned_header_size is added to D3D12VAEncodePicture. Signed-off-by: Tong Wu --- libavcodec/d3d12va_encode.c | 18

[FFmpeg-devel] [PATCH 1/2] lavc/hw_base_encode: correct the timestamp when input_order = decode_delay

2024-07-08 Thread Tong Wu
Fixed the command line: ffmpeg -hwaccel vaapi -pix_fmt nv12 -s:v widthxheight -i input.yuv -vf "hwupload" -c:v hevc_vaapi -bf 10 -b_depth 3 -vframes 3 -f null - Signed-off-by: Tong Wu --- libavcodec/hw_base_encode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

Re: [FFmpeg-devel] [PATCH] avcodec/decode: use avcodec_get_hw_config()

2024-07-08 Thread Kacper Michajlow
On Mon, 1 Jul 2024 at 12:16, Anton Khirnov wrote: > > Quoting Kacper Michajłow (2024-06-02 03:38:18) > > Fixes libavcodec/decode.c:1035:61: runtime error: member access within > > null pointer of type 'const struct AVCodecHWConfigInternal'. > > > > This can happen when hwaccel fails to initialize

[FFmpeg-devel] [PATCH] avcodec/avformat: Store SDP attributes from RTSP stream into AVStream side data.

2024-07-08 Thread Bernardo Pilarz via ffmpeg-devel
Connecting to an RTSP stream will now cause the SDP attributes of each media stream to be stored in the codecpar of the relative AVStream. The SDP attributes are stored in the coded_side_data using the (new) type AV_PKT_DATA_SDP_ATTRIBUTES (AVPacketSideDataType enum). Signed-off-by: Bernardo

Re: [FFmpeg-devel] [PATCH 2/2] avutil/executor: Fix stack overflow due to recursive call

2024-07-08 Thread Timo Rothenpieler
On 08.07.2024 09:43, Zhao Zhili wrote: From: Zhao Zhili av_executor_execute run the task directly when thread is disabled. The task can schedule a new task by call av_executor_execute. This forms an implicit recursive call. This patch removed the recursive call. --- libavutil/executor.c | 5

Re: [FFmpeg-devel] [PATCH 3/6] avcodec/vvc/refs: Use unsigned mask

2024-07-08 Thread Nuo Mi
LGTM. Thank you, Michael, On Mon, Jul 8, 2024 at 2:48 AM Michael Niedermayer wrote: > Not a bugfix, but might fix CID1604361 Overflowed constant > > Sponsored-by: Sovereign Tech Fund > Signed-off-by: Michael Niedermayer > --- > libavcodec/vvc/refs.c | 2 +- > 1 file changed, 1 insertion(+),

[FFmpeg-devel] [PATCH v2] avformat/hls: Fixed incorrect behaviour of default

2024-07-08 Thread CoderVenkat
Hello, I have attached a patch with the requested changes. Thanks, vckt From 5ac9b69d1c570eff4bc72ee4469874a9b182537d Mon Sep 17 00:00:00 2001 From: vckt Date: Fri, 5 Jul 2024 18:51:32 +0530 Subject: [PATCH v2] avformat/hls: Fixed incorrect behaviour of default setting, added autoselect and

Re: [FFmpeg-devel] [RFC]] swscale modernization proposal

2024-07-08 Thread Ronald S. Bultje
Hi, On Mon, Jul 8, 2024 at 8:34 AM Andrew Sayers wrote: > We often say e.g. "this struct currently has such-and-such members, but the > size is not part of the public API". So it's not much of a stretch to say > "this preset enables such-and-such features, but the value is not part of > the >

Re: [FFmpeg-devel] [PATCH 1/2] avcodec/vvc: Use static const for function table

2024-07-08 Thread Nuo Mi
LGTM thank you, Zhili. On Mon, Jul 8, 2024 at 3:40 PM Zhao Zhili wrote: > From: Zhao Zhili > > --- > libavcodec/vvc/thread.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/libavcodec/vvc/thread.c b/libavcodec/vvc/thread.c > index 0cacb1f51c..8dd9a36fd5 100644 > ---

Re: [FFmpeg-devel] [PATCH v2 2/2] avutil/executor: Fix stack overflow due to recursive call

2024-07-08 Thread Nuo Mi
On Mon, Jul 8, 2024 at 8:14 PM Zhao Zhili wrote: > From: Zhao Zhili > > av_executor_execute run the task directly when thread is disabled. > The task can schedule a new task by call av_executor_execute. This > forms an implicit recursive call. This patch removed the recursive > call. > Thank

Re: [FFmpeg-devel] [PATCH 0/1] avfilter/framesync: fix forward EOF pts

2024-07-08 Thread Nicolas Gaullier
>Envoyé : vendredi 14 juin 2024 13:27 >>Envoyé : lundi 3 juin 2024 12:00 >>>Envoyé : mardi 28 mai 2024 11:11 >>> >>>This a new ping but I post the patch again to get fate cleanly completed on >>>patchwork. >>> >>https://patchwork.ffmpeg.org/project/ffmpeg/list/?series=11939 > >To summarize, and

Re: [FFmpeg-devel] [RFC]] swscale modernization proposal

2024-07-08 Thread Andrew Sayers
On Mon, Jul 08, 2024 at 07:58:44AM -0400, Ronald S. Bultje wrote: > On Sat, Jul 6, 2024 at 1:29 PM Hendrik Leppkes wrote: > > On Sat, Jul 6, 2024 at 6:42 PM Michael Niedermayer [...] > > > > The entire point of presets is to have them provide a predefined set > > > > of parameters, easy for users

[FFmpeg-devel] [PATCH v2 2/2] avutil/executor: Fix stack overflow due to recursive call

2024-07-08 Thread Zhao Zhili
From: Zhao Zhili av_executor_execute run the task directly when thread is disabled. The task can schedule a new task by call av_executor_execute. This forms an implicit recursive call. This patch removed the recursive call. --- v2: use bool type libavutil/executor.c | 7 +++ 1 file

Re: [FFmpeg-devel] [PATCH 2/2] swscale/x86/yuv2rgb: Detemplatize

2024-07-08 Thread Ramiro Polla
On Thu, Jul 4, 2024 at 11:40 AM Ramiro Polla wrote: > Every function in yuv2rgb_template.c is only compiled exactly > once, so detemplatize it. I'll apply in a few days if there are no comments. ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org

Re: [FFmpeg-devel] [PATCH] configure: restore autodetection of v4l2 and fbdev

2024-07-08 Thread Ramiro Polla
On Wed, Jul 3, 2024 at 12:30 AM Ramiro Polla wrote: > The detection logic for v4l2 and fbdev was accidentally modified to > depend on v4l2-m2m in 43b3412. I'll apply in a few days if there are no comments. ___ ffmpeg-devel mailing list

Re: [FFmpeg-devel] [RFC]] swscale modernization proposal

2024-07-08 Thread Ronald S. Bultje
Hi, On Sat, Jul 6, 2024 at 1:29 PM Hendrik Leppkes wrote: > On Sat, Jul 6, 2024 at 6:42 PM Michael Niedermayer > wrote: > > > > On Sat, Jul 06, 2024 at 02:11:30AM +0200, Hendrik Leppkes wrote: > > > On Fri, Jul 5, 2024 at 11:34 PM Michael Niedermayer > > > wrote: > > > > > /** > > > > > *

Re: [FFmpeg-devel] [PATCH 1/6] avutil/hwcontext_d3d11va: correct sizeof AVD3D11FrameDescriptor

2024-07-08 Thread Steve Lhomme
Hi Michael, All the patches in that patches look good to me. You can apply. Steve On 07/07/2024 22:23, Michael Niedermayer wrote: Hi Steve you are listed as maintainer for d3d11va, there are some trivial patches in this patchset that i cannot easily test can you either

[FFmpeg-devel] [PATCH 2/2] avutil/executor: Fix stack overflow due to recursive call

2024-07-08 Thread Zhao Zhili
From: Zhao Zhili av_executor_execute run the task directly when thread is disabled. The task can schedule a new task by call av_executor_execute. This forms an implicit recursive call. This patch removed the recursive call. --- libavutil/executor.c | 5 + 1 file changed, 5 insertions(+)

[FFmpeg-devel] [PATCH 2/2] avutil/executor: Fix stack overflow due to recursive call

2024-07-08 Thread Zhao Zhili
From: Zhao Zhili av_executor_execute run the task directly when thread is disabled. The task can schedule a new task by call av_executor_execute. This forms an implicit recursive call. This patch removed the recursive call. --- libavutil/executor.c | 5 + 1 file changed, 5 insertions(+)

[FFmpeg-devel] [PATCH 1/2] avcodec/vvc: Use static const for function table

2024-07-08 Thread Zhao Zhili
From: Zhao Zhili --- libavcodec/vvc/thread.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/vvc/thread.c b/libavcodec/vvc/thread.c index 0cacb1f51c..8dd9a36fd5 100644 --- a/libavcodec/vvc/thread.c +++ b/libavcodec/vvc/thread.c @@ -565,7 +565,7 @@ static void

[FFmpeg-devel] [PATCH] avutil/hwcontext_videotoolbox: Fix version check

2024-07-08 Thread Zhao Zhili
From: Zhao Zhili --- libavutil/hwcontext_videotoolbox.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/hwcontext_videotoolbox.c b/libavutil/hwcontext_videotoolbox.c index 953155ce32..dd89edfa08 100644 --- a/libavutil/hwcontext_videotoolbox.c +++

[FFmpeg-devel] [PATCHv2] swscale: prevent undefined behaviour in the PUTRGBA macro

2024-07-07 Thread Sean McGovern
--- libswscale/yuv2rgb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libswscale/yuv2rgb.c b/libswscale/yuv2rgb.c index 977eb3a7dd..ac0b811f61 100644 --- a/libswscale/yuv2rgb.c +++ b/libswscale/yuv2rgb.c @@ -100,9 +100,9 @@ const int *sws_getCoefficients(int colorspace)

Re: [FFmpeg-devel] [PATCH 6/6] avfilter/af_surround: Check av_channel_layout_channel_from_index() stays within the fixed array used

2024-07-07 Thread James Almer
On 7/7/2024 6:59 PM, Michael Niedermayer wrote: On Sun, Jul 07, 2024 at 09:12:06PM +0200, Andreas Rheinhardt wrote: Andreas Rheinhardt: Michael Niedermayer: Fixes: CID1516994 Out-of-bounds access Fixes: CID1516996 Out-of-bounds access Fixes: CID1516999 Out-of-bounds access Sponsored-by:

[FFmpeg-devel] [PATCH] avcodec/cbs_h265: fix range of sps_max_sub_layers_minus1

2024-07-07 Thread James Almer
The VPS referenced by the SPS must always be present as the max value for sps_max_sub_layers_minus1 is vps_max_sub_layers_minus1. This replaces a buggy custom range check for the aforementioned field. Also, add the missing conformance check for sps_temporal_id_nesting_flag while at it.

Re: [FFmpeg-devel] [PATCH 6/6] avfilter/af_surround: Check av_channel_layout_channel_from_index() stays within the fixed array used

2024-07-07 Thread Michael Niedermayer
On Sun, Jul 07, 2024 at 09:12:06PM +0200, Andreas Rheinhardt wrote: > Andreas Rheinhardt: > > Michael Niedermayer: > >> Fixes: CID1516994 Out-of-bounds access > >> Fixes: CID1516996 Out-of-bounds access > >> Fixes: CID1516999 Out-of-bounds access > >> > >> Sponsored-by: Sovereign Tech Fund > >>

Re: [FFmpeg-devel] [PATCH 1/9] avformat/rtpenc_vc2hq: Check sizes

2024-07-07 Thread Michael Niedermayer
On Sun, Jun 09, 2024 at 01:10:38AM +0200, Michael Niedermayer wrote: > Fixes: CID1452585 Untrusted loop bound > > Sponsored-by: Sovereign Tech Fund > Signed-off-by: Michael Niedermayer > --- > libavformat/rtpenc_vc2hq.c | 15 --- > 1 file changed, 12 insertions(+), 3 deletions(-)

Re: [FFmpeg-devel] [PATCH 5/6] swscale/swscale: Use ptrdiff_t for linesize computations

2024-07-07 Thread Michael Niedermayer
Hi will apply this and the next patch On Sun, Jun 09, 2024 at 05:47:45PM +0200, Michael Niedermayer wrote: > This is unlikely to make a difference > > Fixes: CID1591896 Unintentional integer overflow > Fixes: CID1591901 Unintentional integer overflow > > Sponsored-by: Sovereign Tech Fund >

Re: [FFmpeg-devel] [PATCH 1/6] avutil/hwcontext_d3d11va: correct sizeof AVD3D11FrameDescriptor

2024-07-07 Thread Michael Niedermayer
Hi Steve you are listed as maintainer for d3d11va, there are some trivial patches in this patchset that i cannot easily test can you either apply/approve/reject/test/review them thx On Sun, Jun 09, 2024 at 05:47:41PM +0200, Michael Niedermayer wrote: > Fixes: CID1591909 Wrong sizeof argument >

Re: [FFmpeg-devel] [PATCH 1/3] avfilter/af_afftdn: Assert format

2024-07-07 Thread Michael Niedermayer
On Mon, Jun 10, 2024 at 09:09:54PM +0200, Michael Niedermayer wrote: > Maybe helps: CID1515514 Uninitialized scalar variable > Maybe helps: CID1515517 Uninitialized scalar variable > > Sponsored-by: Sovereign Tech Fund > Signed-off-by: Michael Niedermayer > --- > libavfilter/af_afftdn.c | 5

Re: [FFmpeg-devel] [PATCH] MAINTAINERS: add myself to the general developers list

2024-07-07 Thread Michael Niedermayer
On Sun, Jun 30, 2024 at 02:17:42PM +0800, fei.w.wang-at-intel@ffmpeg.org wrote: > From: Fei Wang > > Signed-off-by: Fei Wang > --- > It has been 4.5 years since my 1st patch to FFmpeg. During the past > years, I have fully understand the rules of a committer. Because > sometimes, patch

Re: [FFmpeg-devel] [PATCH] tools/coverity: Phase 1 study of anti-halicogenic for coverity av_rescale()

2024-07-07 Thread Michael Niedermayer
On Fri, Jul 05, 2024 at 02:50:41PM +0200, Michael Niedermayer wrote: > Signed-off-by: Michael Niedermayer > --- > tools/coverity.c | 18 ++ > 1 file changed, 18 insertions(+) will apply [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB When the

Re: [FFmpeg-devel] [PATCH 1/4] avfilter/af_aresample: Cleanup on av_channel_layout_copy() failure

2024-07-07 Thread Michael Niedermayer
On Tue, Jun 11, 2024 at 03:44:19PM +0200, Michael Niedermayer wrote: > Fixes: CID1503078 Resource leak > > Sponsored-by: Sovereign Tech Fund > Signed-off-by: Michael Niedermayer > --- > libavfilter/af_aresample.c | 5 - > 1 file changed, 4 insertions(+), 1 deletion(-) will apply patchset

Re: [FFmpeg-devel] [PATCH 04/17] avcodec/dxva2: initialize hr in ff_dxva2_common_end_frame()

2024-07-07 Thread Michael Niedermayer
On Sun, Jun 02, 2024 at 10:27:55PM +0200, Michael Niedermayer wrote: > On Sun, Jun 02, 2024 at 09:10:33PM +0200, Andreas Rheinhardt wrote: > > Michael Niedermayer: > > > Fixes: CID1591924 Uninitialized scalar variable > > > Fixes: CID1591938 Uninitialized scalar variable > > > > > > Sponsored-by:

Re: [FFmpeg-devel] [PATCH 6/6] avfilter/af_surround: Check av_channel_layout_channel_from_index() stays within the fixed array used

2024-07-07 Thread Andreas Rheinhardt
Andreas Rheinhardt: > Michael Niedermayer: >> Fixes: CID1516994 Out-of-bounds access >> Fixes: CID1516996 Out-of-bounds access >> Fixes: CID1516999 Out-of-bounds access >> >> Sponsored-by: Sovereign Tech Fund >> Signed-off-by: Michael Niedermayer >> --- >> libavfilter/af_surround.c | 3 +++ >> 1

Re: [FFmpeg-devel] [PATCH 6/6] avfilter/af_surround: Check av_channel_layout_channel_from_index() stays within the fixed array used

2024-07-07 Thread Andreas Rheinhardt
Michael Niedermayer: > Fixes: CID1516994 Out-of-bounds access > Fixes: CID1516996 Out-of-bounds access > Fixes: CID1516999 Out-of-bounds access > > Sponsored-by: Sovereign Tech Fund > Signed-off-by: Michael Niedermayer > --- > libavfilter/af_surround.c | 3 +++ > 1 file changed, 3 insertions(+)

Re: [FFmpeg-devel] [PATCH v2 3/8] swscale/options: relax src/dst_h/v_chr_pos value range

2024-07-07 Thread Michael Niedermayer
On Thu, Jul 04, 2024 at 04:30:59PM +0200, Niklas Haas wrote: > From: Niklas Haas > > When dealing with 4x subsampling ratios (log2 == 2), such as can arise > with 4:1:1 or 4:1:0, a value range of 512 is not enough to cover the > range of possible scenarios. > > For example, bottom-sited chroma

[FFmpeg-devel] [PATCH] lavc/h264dsp: R-V V 8-bit chroma_dc_dequant_idct

2024-07-07 Thread Rémi Denis-Courmont
Performance gains is around 0.5% on K230 cycle counter, and not measurable with the architecture timer, so probably no worth merging. --- libavcodec/riscv/h264dsp_init.c | 4 +++ libavcodec/riscv/h264idct_rvv.S | 57 + 2 files changed, 61 insertions(+) diff --git

[FFmpeg-devel] [PATCH 6/6] avfilter/af_surround: Check av_channel_layout_channel_from_index() stays within the fixed array used

2024-07-07 Thread Michael Niedermayer
Fixes: CID1516994 Out-of-bounds access Fixes: CID1516996 Out-of-bounds access Fixes: CID1516999 Out-of-bounds access Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavfilter/af_surround.c | 3 +++ 1 file changed, 3 insertions(+) diff --git

[FFmpeg-devel] [PATCH 5/6] avfilter: Free out on error

2024-07-07 Thread Michael Niedermayer
CID1197065 Resource leak Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavfilter/af_aderivative.c | 1 + libavfilter/vf_deshake.c | 6 -- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/libavfilter/af_aderivative.c

[FFmpeg-devel] [PATCH 4/6] avdevice/dshow_capture: Fix error handling in ff_dshow_##prefix##_Create()

2024-07-07 Thread Michael Niedermayer
Untested, needs review Fixes: CID1591856 Resource leak Fixes: CID1591887 Resource leak Fixes: CID1591874 Resource leak Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavdevice/dshow_capture.h | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git

[FFmpeg-devel] [PATCH 3/6] avcodec/vvc/refs: Use unsigned mask

2024-07-07 Thread Michael Niedermayer
Not a bugfix, but might fix CID1604361 Overflowed constant Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavcodec/vvc/refs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/vvc/refs.c b/libavcodec/vvc/refs.c index

[FFmpeg-devel] [PATCH 2/6] avcodec/vaapi_h264: Do not store our error code in VASliceParameterBufferH264

2024-07-07 Thread Michael Niedermayer
I am not sure this is possible (thus this requires review) Fixes: CID1604570 Overflowed constant Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavcodec/vaapi_h264.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/libavcodec/vaapi_h264.c

[FFmpeg-devel] [PATCH 1/6] avcodec/tiff: Check value on positive signed targets

2024-07-07 Thread Michael Niedermayer
Fixes: CID1604593 Overflowed constant Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavcodec/tiff.c | 20 ++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/libavcodec/tiff.c b/libavcodec/tiff.c index fd4116aec4d..37b56e9757e 100644

[FFmpeg-devel] [PATCH] lavc/flacdsp: implement wasted32 DSP function for VSX on POWER

2024-07-07 Thread Sean McGovern
RaptorCS POWER9 (8c4t) @ 2.2GHz: flac_wasted_32_c: 50.1 flac_wasted_32_vsx: 14.1 --- libavcodec/flacdsp.c | 2 ++ libavcodec/flacdsp.h | 1 + libavcodec/ppc/Makefile | 2 ++ libavcodec/ppc/flacdsp_init.c | 38 + libavcodec/ppc/flacdsp_vsx.c | 53

Re: [FFmpeg-devel] [PATCH] avformat/avisynth: remove atexit() handler

2024-07-07 Thread Stephen Hutchinson
On 7/7/24 9:50 AM, Andreas Rheinhardt wrote: avisynth_context_destroy() is currently always called while holding the lock (i.e. avisynth_mutex). Is this even necessary? It is clear that avisynth_load_library() (and the check for whether it should be called) need the lock, but does anything else

Re: [FFmpeg-devel] [PATCH 2/2] lavc/flacdsp: implement wasted32 DSP function for VSX on POWER

2024-07-07 Thread Sean McGovern
Hi, On Sat, Jul 6, 2024, 16:18 Rémi Denis-Courmont wrote: > Le lauantaina 6. heinäkuuta 2024, 23.00.47 EEST Sean McGovern a écrit : > > Does wasted32 (and I guess wasted33 by proxy) not have to worry about > loops > > tails? I noticed the other vectorized versions don't do anything special > in

Re: [FFmpeg-devel] lavfi: add perlin noise generator

2024-07-07 Thread Nicolas George
Stefano Sabatini (12024-07-06): > Can someone elaborate about why .activate is favoured in this case > (sorry I missed the activate discussion altogether and I cannot graps > it from the docs)? I do not know why Paul believes that source filters need to use activate. It should not be necessary,

Re: [FFmpeg-devel] [PATCH 01/11] avformat/mov: add support for lhvC box parsing

2024-07-07 Thread James Almer
On 7/7/2024 12:43 PM, Andreas Rheinhardt wrote: James Almer: Signed-off-by: James Almer --- libavformat/mov.c | 48 +++ 1 file changed, 48 insertions(+) diff --git a/libavformat/mov.c b/libavformat/mov.c index a3951a6942..30e8086855 100644 ---

Re: [FFmpeg-devel] [PATCH 04/11] avformat/hevc: don't write NALUs with nuh_layer_id > 0 in hvcC boxes

2024-07-07 Thread James Almer
On 7/7/2024 12:46 PM, Andreas Rheinhardt wrote: James Almer: hvcC should only contain nuh_layer_id == 0 NALUs. Support for a box meant to contain higher layer NALUs will be added in a following patch. To achieve this, all sources are parsed and filtered, including hvcC source that until now

Re: [FFmpeg-devel] [PATCH 04/11] avformat/hevc: don't write NALUs with nuh_layer_id > 0 in hvcC boxes

2024-07-07 Thread Andreas Rheinhardt
James Almer: > hvcC should only contain nuh_layer_id == 0 NALUs. Support for a box meant to > contain higher layer NALUs will be added in a following patch. > To achieve this, all sources are parsed and filtered, including hvcC source > that until now were propagated untouched. This is reflected

Re: [FFmpeg-devel] [PATCH 01/11] avformat/mov: add support for lhvC box parsing

2024-07-07 Thread Andreas Rheinhardt
James Almer: > Signed-off-by: James Almer > --- > libavformat/mov.c | 48 +++ > 1 file changed, 48 insertions(+) > > diff --git a/libavformat/mov.c b/libavformat/mov.c > index a3951a6942..30e8086855 100644 > --- a/libavformat/mov.c > +++

Re: [FFmpeg-devel] [PATCH 01/11] avformat/mov: add support for lhvC box parsing

2024-07-07 Thread James Almer
On 7/3/2024 6:26 PM, James Almer wrote: Signed-off-by: James Almer --- libavformat/mov.c | 48 +++ 1 file changed, 48 insertions(+) diff --git a/libavformat/mov.c b/libavformat/mov.c index a3951a6942..30e8086855 100644 --- a/libavformat/mov.c +++

Re: [FFmpeg-devel] [PATCH] avformat/avisynth: remove atexit() handler

2024-07-07 Thread Andreas Rheinhardt
Stephen Hutchinson: > The atexit() handler in the avisynth demuxer was added because > there was a conflict in AvxSynth that arose due to their use > of C++ global objects, particularly in relation to having > added a logging function relying on log4cpp. > > This conflict was responsible for

Re: [FFmpeg-devel] [PATCH 1/2] lavc/h264dsp: remove MMI 8-bit chroma DC dequant

2024-07-07 Thread Rémi Denis-Courmont
Le sunnuntaina 7. heinäkuuta 2024, 14.44.47 EEST Rémi Denis-Courmont a écrit : > The function is exactly identical to the C reference, only with the > constant propagated manually. It does not optimise anything. There are presently no (other) implementations for

[FFmpeg-devel] [PATCH 1/2] lavc/h264dsp: remove MMI 8-bit chroma DC dequant

2024-07-07 Thread Rémi Denis-Courmont
The function is exactly identical to the C reference, only with the constant propagated manually. It does not optimise anything. --- libavcodec/mips/h264dsp_init_mips.c | 5 + libavcodec/mips/h264dsp_mips.h | 1 - libavcodec/mips/h264dsp_mmi.c | 14 -- 3 files

[FFmpeg-devel] [PATCH 2/2] lavc/h264dsp: remove MMI 8-bit 4:2:2 chroma DC dequant

2024-07-07 Thread Rémi Denis-Courmont
The function is exactly identical to the C reference, only with the constant propagated and the loop unrolled manually. --- libavcodec/mips/h264dsp_init_mips.c | 4 libavcodec/mips/h264dsp_mips.h | 1 - libavcodec/mips/h264dsp_mmi.c | 33 - 3 files

Re: [FFmpeg-devel] [PATCH] MAINTAINERS: add myself to the general developers list

2024-07-07 Thread Wang, Fei W
> -Original Message- > From: Wang, Fei W > Sent: Sunday, June 30, 2024 2:18 PM > To: ffmpeg-devel@ffmpeg.org > Cc: Wang, Fei W > Subject: [FFmpeg-devel][PATCH] MAINTAINERS: add myself to the general > developers list > > From: Fei Wang > > Signed-off-by: Fei Wang > --- > It has been

Re: [FFmpeg-devel] 0001-Fix-HLG-10bit-color-transfer

2024-07-07 Thread Zhao Zhili
> On Jul 7, 2024, at 18:08, 激情澎湃 via ffmpeg-devel > wrote: Thanks for your contribution. There is a similar patch on the mailing list already https://patchwork.ffmpeg.org/project/ffmpeg/patch/20240621060820.3215-1-hgua...@gmail.com/ > > 激情澎湃 > 12685...@qq.com > > > >

Re: [FFmpeg-devel] [PATCH] avcodec/videotoolboxenc: fix vtctx reset condition

2024-07-07 Thread Zhao Zhili
> On Jun 21, 2024, at 14:08, Hao Guan wrote: > > In vtenc_populate_extradata, the cleanup function vtenc_reset should not > be used when no error occurs, otherwise some color information is lost > (#11036). > > This patch checks the status code and conducts the correct cleanup. LGTM,

[FFmpeg-devel] [PATCH v2 3/5] avcodec/videotoolboxenc: Use BufNode as sourceFrameRefcon

2024-07-07 Thread Zhao Zhili
From: Zhao Zhili ExtraSEI is used as the sourceFrameRefcon of VTCompressionSessionEncodeFrame. It cannot hold other information which is necessary to fix another issue in the following patch. This patch also fixed leak of ExtraSEI on the error path of vtenc_output_callback. --- v2: Fix inverted

  1   2   3   4   5   6   7   8   9   10   >