Re: [FFmpeg-devel] [PATCH 3/3] h264: fix data-race with FF_DECODE_ERROR_DECODE_SLICES

2023-09-12 Thread Thomas Guillem via ffmpeg-devel
On Tue, Sep 12, 2023, at 15:11, Andreas Rheinhardt wrote: > Thomas Guillem via ffmpeg-devel: >> Same than the previous commit but with FF_DECODE_ERROR_DECODE_SLICES >> >> Fix the following data-race: >> >> WARNING: ThreadSanitizer: data race (pid=55935) >> Write of size 4 at 0x7b509378 b

Re: [FFmpeg-devel] [PATCH 1/3] avcodec/av1dec: Pass AVCodecContext* as logctx in get_sw_pixel_format()

2023-09-12 Thread James Almer
On 9/12/2023 9:22 PM, Andreas Rheinhardt wrote: Andreas Rheinhardt: It indicates to the reader that said function does not modify any state. Signed-off-by: Andreas Rheinhardt --- libavcodec/av1dec.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/libavcodec/

Re: [FFmpeg-devel] [PATCH 1/3] avcodec/av1dec: Pass AVCodecContext* as logctx in get_sw_pixel_format()

2023-09-12 Thread Andreas Rheinhardt
Andreas Rheinhardt: > It indicates to the reader that said function does not modify > any state. > > Signed-off-by: Andreas Rheinhardt > --- > libavcodec/av1dec.c | 12 ++-- > 1 file changed, 6 insertions(+), 6 deletions(-) > > diff --git a/libavcodec/av1dec.c b/libavcodec/av1dec.c > in

Re: [FFmpeg-devel] trac backups

2023-09-12 Thread Michael Niedermayer
On Wed, Sep 13, 2023 at 12:32:28AM +0200, Marvin Scholz wrote: > > > On 13 Sep 2023, at 0:13, Michael Niedermayer wrote: > > > Hi all > > > > our trac backups died 6 months ago > > i just noticed as i checked the backups before deleting spam with trac-admin > > backups are working again > > > >

Re: [FFmpeg-devel] trac backups

2023-09-12 Thread Marvin Scholz
On 13 Sep 2023, at 0:13, Michael Niedermayer wrote: > Hi all > > our trac backups died 6 months ago > i just noticed as i checked the backups before deleting spam with trac-admin > backups are working again > > failure reason where expired gpg keys > > thx > > PS: yeah, iam slightly unhappy noo

[FFmpeg-devel] trac backups

2023-09-12 Thread Michael Niedermayer
Hi all our trac backups died 6 months ago i just noticed as i checked the backups before deleting spam with trac-admin backups are working again failure reason where expired gpg keys thx PS: yeah, iam slightly unhappy noone noticed this for 6 months -- Michael GnuPG fingerprint: 9FF2128B1

Re: [FFmpeg-devel] Trac spam

2023-09-12 Thread Michael Niedermayer
On Tue, Sep 12, 2023 at 07:03:33AM +0200, Michael Koch wrote: > > I guess deleting users requires full admin rights, so i guess, just make a > > list > of users which are in need of a deletion and post that and i or less likely > some other admin will disable/delete them. > > Please delete user "

Re: [FFmpeg-devel] [PATCH 1/5] avformat/wtvdec: Don't truncate GUIDs

2023-09-12 Thread Peter Ross
On Tue, Sep 12, 2023 at 02:27:17PM +0200, Andreas Rheinhardt wrote: > Each of the 16 bytes of a GUID is written as a two-character > hex value and three hyphens, leading to a length of 35. > GCC 13 emits a -Wformat-truncation= warning because of this. > > Signed-off-by: Andreas Rheinhardt > --- >

Re: [FFmpeg-devel] [RFC PATCH 1/3] aacdec: always skip the first 2048 samples if there's no side data

2023-09-12 Thread Thierry Foucu
On Tue, Sep 12, 2023 at 9:25 AM Lynne wrote: > Sep 12, 2023, 09:43 by andreas.rheinha...@outlook.com: > > > Lynne: > > > >> For some reason, this was never set, which meant all **raw** AAC in ADTS > >> streams, except faac, had extra samples at the start. > >> > >> Despite this being a standard M

[FFmpeg-devel] [PATCH 2/2] avcodec/h264dec: Fix data race when updating decode_error_flags

2023-09-12 Thread Andreas Rheinhardt
When using multi-threaded decoding, every decoding thread has its own DBP consisting of H264Pictures and each of these points to its own AVFrames. They are synced during update_thread_context via av_frame_ref() and therefore the threads actually decoding (as well as all the others) must not modify

[FFmpeg-devel] [PATCH 1/2] avcodec/error_resilience: Make applying decode_error_flags optional

2023-09-12 Thread Andreas Rheinhardt
Add a pointer parameter that if supplied will be used to return the updated decode_error_flags. This will allow to fix several races when using frame-threading; these resulted from AVFrame that the earlier code updated concurrently being used as source in an av_frame_ref() call in the decoder's upd

Re: [FFmpeg-devel] [PATCH 1/3] error_resilience: set the decode_error_flags outside

2023-09-12 Thread Michael Niedermayer
On Tue, Sep 12, 2023 at 01:40:13PM +0200, Thomas Guillem via ffmpeg-devel wrote: > This will allow to fix data-races when ff_er_frame_end() is called after > ff_thread_finish_setup() > --- > libavcodec/error_resilience.c | 12 ++-- > libavcodec/error_resilience.h | 2 +- > libavcodec/h263

[FFmpeg-devel] [PATCH] avcodec/libkvazaar: Respect codec context color settings.

2023-09-12 Thread John Mather via ffmpeg-devel
This patch makes the libkvazaar encoder respect color settings that are present on the codec context, including color range, primaries, transfer function and colorspace. --- libavcodec/libkvazaar.c | 55 + 1 file changed, 55 insertions(+) diff --git a/libav

Re: [FFmpeg-devel] [PATCH 03/10] avformat/avformat: use the side data from AVStream.codecpar

2023-09-12 Thread James Almer
On 9/12/2023 1:43 PM, Andreas Rheinhardt wrote: James Almer: On 9/11/2023 4:19 PM, Andreas Rheinhardt wrote: James Almer: Deprecate AVStream.side_data and its helpers in favor of the AVStream's codecpar.side_data. This will considerably simplify the propagation of global side data to decoders

Re: [FFmpeg-devel] [PATCH 03/10] avformat/avformat: use the side data from AVStream.codecpar

2023-09-12 Thread Andreas Rheinhardt
James Almer: > On 9/11/2023 4:19 PM, Andreas Rheinhardt wrote: >> James Almer: >>> Deprecate AVStream.side_data and its helpers in favor of the AVStream's >>> codecpar.side_data. >>> >>> This will considerably simplify the propagation of global side data >>> to decoders >>> and from encoders. Inste

Re: [FFmpeg-devel] [PATCH 02/10] avcodec/codec_par: add side data to AVCodecParameters

2023-09-12 Thread James Almer
On 9/11/2023 2:45 PM, Andreas Rheinhardt wrote: James Almer: This will simplify the propagation of side data to decoders and from encoders. Global side data will now reside in the AVCodecContext, thus be available during init(), removing the need to propagate it inside packets. Global and frame

Re: [FFmpeg-devel] [PATCH 03/10] avformat/avformat: use the side data from AVStream.codecpar

2023-09-12 Thread James Almer
On 9/11/2023 4:19 PM, Andreas Rheinhardt wrote: James Almer: Deprecate AVStream.side_data and its helpers in favor of the AVStream's codecpar.side_data. This will considerably simplify the propagation of global side data to decoders and from encoders. Instead of having to do it inside packets,

Re: [FFmpeg-devel] [RFC PATCH 1/3] aacdec: always skip the first 2048 samples if there's no side data

2023-09-12 Thread Lynne
Sep 12, 2023, 09:43 by andreas.rheinha...@outlook.com: > Lynne: > >> For some reason, this was never set, which meant all **raw** AAC in ADTS >> streams, except faac, had extra samples at the start. >> >> Despite this being a standard MDCT-based codec with a frame size of 1024, >> hence a delay of

Re: [FFmpeg-devel] [PATCH v3] avformat/avio: Don't use incompatible function pointer type for call

2023-09-12 Thread Andreas Rheinhardt
Andreas Rheinhardt: > It is undefined behaviour even in cases where it works > (it works because it is only a const uint8_t* vs. uint8_t* difference). > > Instead add a cbuf parameter to pass a const buffer (for writing) > as well as a parameter indicating whether we are reading or writing; > retr

Re: [FFmpeg-devel] [PATCH 3/3] h264: fix data-race with FF_DECODE_ERROR_DECODE_SLICES

2023-09-12 Thread Andreas Rheinhardt
Thomas Guillem via ffmpeg-devel: > Same than the previous commit but with FF_DECODE_ERROR_DECODE_SLICES > > Fix the following data-race: > > WARNING: ThreadSanitizer: data race (pid=55935) > Write of size 4 at 0x7b509378 by thread T1 (mutexes: write M608): > #0 decode_nal_units src/liba

[FFmpeg-devel] [PATCH 5/5] avformat/wtvdec: Avoid unnecessary allocations

2023-09-12 Thread Andreas Rheinhardt
Signed-off-by: Andreas Rheinhardt --- libavformat/wtvdec.c | 47 ++-- 1 file changed, 19 insertions(+), 28 deletions(-) diff --git a/libavformat/wtvdec.c b/libavformat/wtvdec.c index 9fe00590c8..e70470f79b 100644 --- a/libavformat/wtvdec.c +++ b/libavforma

[FFmpeg-devel] [PATCH 4/5] avformat/wtvdec: Use smaller upper bound for buffer

2023-09-12 Thread Andreas Rheinhardt
Every code point in the BMP is representable with at most three bytes in UTF-8 and every code point not in the BMP takes four bytes. For each of the latter, the encoding of UTF-16 takes as many bytes; for each of the former, it takes at most 3/2 as many. Therefore one can decrease the size of the b

[FFmpeg-devel] [PATCH 3/5] avformat/wtvdec: Fix signed integer overflow

2023-09-12 Thread Andreas Rheinhardt
Happens when length > INT_MAX / 2; use unsigned for the computation, but restrict the value to INT_MAX, because avio_get_str16le() accepts an int as buf_len argument. Notice that it can happen that the string read by avio_get_str16le() is truncated in this case. Signed-off-by: Andreas Rheinhardt

[FFmpeg-devel] [PATCH 2/5] avformat/wtvdec: Skip too big tags

2023-09-12 Thread Andreas Rheinhardt
get_tag() is not designed with negative length in mind; in this case, it will allocate a very small buffer (LEN_PRETTY_GUID + 1) and might call avio_get_str16le() with a negative maxlen (which relies on these parameters to be signed). Signed-off-by: Andreas Rheinhardt --- libavformat/wtvdec.c |

Re: [FFmpeg-devel] [PATCH v27 2/2] avcodec/evc_decoder: Provided support for EVC decoder

2023-09-12 Thread Dawid Kozinski/Multimedia (PLT) /SRPOL/Staff Engineer/Samsung Electronics
> -Original Message- > From: ffmpeg-devel On Behalf Of James > Almer > Sent: poniedziałek, 11 września 2023 00:56 > To: ffmpeg-devel@ffmpeg.org > Subject: Re: [FFmpeg-devel] [PATCH v27 2/2] avcodec/evc_decoder: Provided > support for EVC decoder > > On 8/16/2023 8:11 AM, Dawid Kozins

[FFmpeg-devel] [PATCH 1/5] avformat/wtvdec: Don't truncate GUIDs

2023-09-12 Thread Andreas Rheinhardt
Each of the 16 bytes of a GUID is written as a two-character hex value and three hyphens, leading to a length of 35. GCC 13 emits a -Wformat-truncation= warning because of this. Signed-off-by: Andreas Rheinhardt --- Is there actually a reason this is using a different format than the one used by

Re: [FFmpeg-devel] [PATCH 1/4] lavc/aarch64: new optimization for 8-bit hevc_epel_uni_v

2023-09-12 Thread Martin Storsjö
Hi, Sorry for not tending to your patches sooner. Unfortunately, this patchset is impossible to apply - there seems to be garbled whitespace in the patch which would require me to manually apply all the changes. Can you try sending the patches again in a way that doesn't corrupt whitespace?

[FFmpeg-devel] [PATCH 2/3] h264: fix data-race with FF_DECODE_ERROR_CONCEALMENT_ACTIVE

2023-09-12 Thread Thomas Guillem via ffmpeg-devel
Set the FF_DECODE_ERROR_CONCEALMENT_ACTIVE flags on the AVFrane before outputing it. Store in in the H264Picture in the meantime, where it won't be read/write by other threads. Fix the following data-race: WARNING: ThreadSanitizer: data race (pid=55134) Write of size 4 at 0x7b507f78 by thre

[FFmpeg-devel] [PATCH 3/3] h264: fix data-race with FF_DECODE_ERROR_DECODE_SLICES

2023-09-12 Thread Thomas Guillem via ffmpeg-devel
Same than the previous commit but with FF_DECODE_ERROR_DECODE_SLICES Fix the following data-race: WARNING: ThreadSanitizer: data race (pid=55935) Write of size 4 at 0x7b509378 by thread T1 (mutexes: write M608): #0 decode_nal_units src/libavcodec/h264dec.c:742 (ffmpeg+0xb19dd6) #1 h

[FFmpeg-devel] [PATCH 1/3] error_resilience: set the decode_error_flags outside

2023-09-12 Thread Thomas Guillem via ffmpeg-devel
This will allow to fix data-races when ff_er_frame_end() is called after ff_thread_finish_setup() --- libavcodec/error_resilience.c | 12 ++-- libavcodec/error_resilience.h | 2 +- libavcodec/h263dec.c | 6 -- libavcodec/h264dec.c | 3 ++- libavcodec/mpeg12dec.c

Re: [FFmpeg-devel] [RFC PATCH 1/3] aacdec: always skip the first 2048 samples if there's no side data

2023-09-12 Thread Andreas Rheinhardt
Lynne: > For some reason, this was never set, which meant all **raw** AAC in ADTS > streams, except faac, had extra samples at the start. > > Despite this being a standard MDCT-based codec with a frame size of 1024, > hence a delay of 1024 samples at the start, all major encoders, excluding > faac