Re: [FFmpeg-devel] [PATCH 5/5] checkasm: add vvc_sao

2025-05-10 Thread Nuo Mi
On Wed, May 7, 2025 at 5:26 AM Martin Storsjö  wrote:

> On Sat, 3 May 2025, Nuo Mi wrote:
>
> > Hi Martin,Great, it works!
> > HEVC is included in v2.
>
> Thanks great, thanks for looking into it! The checkasm aspects of patches
> 5-7/7 look good to me.
>
Thank you, Martin.
I’ll merge if there are no other objections

>
> // Martin
>
___
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 v1 23/23] Changelog: VVC supports all content of SCC

2025-05-10 Thread Nuo Mi
On Thu, May 1, 2025 at 10:48 PM  wrote:

> From: Wu Jianhua 
>
> Signed-off-by: Wu Jianhua 
> ---
>  Changelog | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/Changelog b/Changelog
> index a09dcd82c2..4f47b30038 100644
> --- a/Changelog
> +++ b/Changelog
> @@ -11,6 +11,8 @@ version :
>  - Enhanced FLV v2: Multitrack audio/video, modern codec support
>  - Animated JPEG XL encoding (via libjxl)
>  - VVC in Matroska
> +- VVC decoder supports all content of SCC (Screen Content Coding):
> +  IBC (Inter Block Copy), Palette Mode and ACT (Adaptive Color Transform)
>
👍 Thank you for your excellent work, Jianhua.
will merge this if no objections.
After this is merged, please add one clip for each feature in the FATE.

>
>  version 7.1:
>  - Raw Captions with Time (RCWT) closed caption demuxer
> @@ -53,7 +55,6 @@ version 7.1:
>constrains
>  - FFV1 parser
>
> -
>  version 7.0:
>  - DXV DXT1 encoder
>  - LEAD MCMP decoder
> --
> 2.44.0.windows.1
>
> ___
> 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".
>
___
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] hwcontext_vulkan: fix exporting multi-plane DRM modifiers

2025-05-10 Thread Russell Greene
Lynne,

Any thoughts on this?
___
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] avformat/wavdec: increase requested probe score for codec probe

2025-05-10 Thread Michael Niedermayer
On Fri, May 09, 2025 at 01:54:22PM +0200, Marton Balint wrote:
> 
> 
> On Fri, 9 May 2025, Michael Niedermayer wrote:
> 
> > On Fri, May 09, 2025 at 12:28:00AM +0200, Marton Balint wrote:
> > > Codec probing was primarily added to the wav demuxer to support DTS-in-wav
> > > files, but DTS probing functions return AVPROBE_SCORE_EXTENSION+1, so we 
> > > can be
> > > a bit more strict with the required score.
> > > 
> > > This fixes MP3 misdetections for some wav files.
> > > 
> > > Fixes ticket #11581.
> > > 
> > > Signed-off-by: Marton Balint 
> > > ---
> > >  libavformat/wavdec.c | 2 +-
> > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > > 
> > > diff --git a/libavformat/wavdec.c b/libavformat/wavdec.c
> > > index dc7e49abc4..c65e0a2723 100644
> > > --- a/libavformat/wavdec.c
> > > +++ b/libavformat/wavdec.c
> > > @@ -178,7 +178,7 @@ static void handle_stream_probing(AVStream *st)
> > >  {
> > >  if (st->codecpar->codec_id == AV_CODEC_ID_PCM_S16LE) {
> > >  FFStream *const sti = ffstream(st);
> > > -sti->request_probe = AVPROBE_SCORE_EXTENSION;
> > > +sti->request_probe = AVPROBE_SCORE_EXTENSION + 1;
> > >  sti->probe_packets = FFMIN(sti->probe_packets, 32);
> > >  }
> > >  }
> > 
> > please add a testcase to fate, if possible. Such corner cases
> > are important to be in fate
> 
> Sample is in the ticket, so it should be pretty trivial to do so. Can't we

> fund someone to do this and the other fixed trac tickets without fate tests?

Iam in favor of funding that

see https://trac.ffmpeg.org/wiki/SponsoringPrograms/STF/2025

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

"You are 36 times more likely to die in a bathtub than at the hands of a
terrorist. Also, you are 2.5 times more likely to become a president and
2 times more likely to become an astronaut, than to die in a terrorist
attack." -- Thoughty2



signature.asc
Description: PGP signature
___
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".


[FFmpeg-devel] [PATCH] avformat/iamf_parse: increase PutBytes buffer when writing AAC extradata

2025-05-10 Thread James Almer
We may write up to 43 bits, so 5 bytes is not enough.

Fixes: Assertion n>=0 && n<=32 failed at ./libavcodec/get_bits.h:406
Fixes: 
398527871/clusterfuzz-testcase-minimized-ffmpeg_dem_IAMF_fuzzer-6602025714647040

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: James Almer 
---
 libavformat/iamf_parse.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/iamf_parse.c b/libavformat/iamf_parse.c
index abedfdb066..14b69855c9 100644
--- a/libavformat/iamf_parse.c
+++ b/libavformat/iamf_parse.c
@@ -285,7 +285,7 @@ static int update_extradata(AVCodecParameters *codecpar)
 AV_WL16A(codecpar->extradata + 16, AV_RB16A(codecpar->extradata + 
16)); // Byte swap Output Gain
 break;
 case AV_CODEC_ID_AAC: {
-uint8_t buf[5];
+uint8_t buf[6];
 
 init_put_bits(&pb, buf, sizeof(buf));
 ret = init_get_bits8(&gb, codecpar->extradata, 
codecpar->extradata_size);
-- 
2.49.0

___
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".


[FFmpeg-devel] [PATCH 4/8] avformat/imf_cpl: fix indention after previous commit

2025-05-10 Thread Michael Niedermayer
---
 libavformat/imf_cpl.c | 36 ++--
 1 file changed, 18 insertions(+), 18 deletions(-)

diff --git a/libavformat/imf_cpl.c b/libavformat/imf_cpl.c
index 6ddea62abef..8c3530f4122 100644
--- a/libavformat/imf_cpl.c
+++ b/libavformat/imf_cpl.c
@@ -711,29 +711,29 @@ static int fill_virtual_tracks(void *log_ctx, xmlNodePtr 
cpl_element, FFIMFCPL *
 sequence_list_elem = 
ff_imf_xml_get_child_element_by_name(segment_elem, "SequenceList");
 if (sequence_list_elem) {
 
-sequence_elem = xmlFirstElementChild(sequence_list_elem);
-while (sequence_elem) {
-if (xmlStrcmp(sequence_elem->name, "MarkerSequence") == 0)
-ret = push_marker_sequence(log_ctx, sequence_elem, cpl);
+sequence_elem = xmlFirstElementChild(sequence_list_elem);
+while (sequence_elem) {
+if (xmlStrcmp(sequence_elem->name, "MarkerSequence") == 0)
+ret = push_marker_sequence(log_ctx, sequence_elem, cpl);
 
-else if (xmlStrcmp(sequence_elem->name, "MainImageSequence") == 0)
-ret = push_main_image_2d_sequence(log_ctx, sequence_elem, cpl);
+else if (xmlStrcmp(sequence_elem->name, "MainImageSequence") 
== 0)
+ret = push_main_image_2d_sequence(log_ctx, sequence_elem, 
cpl);
 
-else if (xmlStrcmp(sequence_elem->name, "MainAudioSequence") == 0)
-ret = push_main_audio_sequence(log_ctx, sequence_elem, cpl);
+else if (xmlStrcmp(sequence_elem->name, "MainAudioSequence") 
== 0)
+ret = push_main_audio_sequence(log_ctx, sequence_elem, 
cpl);
 
-else
-av_log(log_ctx,
-   AV_LOG_INFO,
-   "The following Sequence is not supported and is 
ignored: %s\n",
-   sequence_elem->name);
+else
+av_log(log_ctx,
+AV_LOG_INFO,
+"The following Sequence is not supported and is 
ignored: %s\n",
+sequence_elem->name);
 
-/* abort parsing only if memory error occurred */
-if (ret == AVERROR(ENOMEM))
-return ret;
+/* abort parsing only if memory error occurred */
+if (ret == AVERROR(ENOMEM))
+return ret;
 
-sequence_elem = xmlNextElementSibling(sequence_elem);
-}
+sequence_elem = xmlNextElementSibling(sequence_elem);
+}
 }
 
 segment_elem = xmlNextElementSibling(segment_elem);
-- 
2.49.0

___
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".


[FFmpeg-devel] [PATCH 5/8] avcodec/aacsbr_template: Check ilb

2025-05-10 Thread Michael Niedermayer
Fixes: index 50 out of bounds for type 'INTFLOAT [40][2]'
Fixes: 
401661737/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_AAC_LATM_fuzzer-4866055713652736

Someone knowing AAC should review this, there is likely a nicer fix

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 
---
 libavcodec/aacsbr_template.c | 6 ++
 1 file changed, 6 insertions(+)

diff --git a/libavcodec/aacsbr_template.c b/libavcodec/aacsbr_template.c
index 9fae44d9a5c..a126bd6f060 100644
--- a/libavcodec/aacsbr_template.c
+++ b/libavcodec/aacsbr_template.c
@@ -1626,6 +1626,9 @@ static void sbr_env_estimate(AAC_FLOAT (*e_curr)[48], 
INTFLOAT X_high[64][40][2]
 int ilb = ch_data->t_env[e] * 2 + ENVELOPE_ADJUSTMENT_OFFSET;
 int iub = ch_data->t_env[e + 1] * 2 + ENVELOPE_ADJUSTMENT_OFFSET;
 
+if (ilb >= 40)
+return;
+
 for (m = 0; m < sbr->m[1]; m++) {
 AAC_FLOAT sum = sbr->dsp.sum_square(X_high[m+kx1] + ilb, iub - 
ilb);
 #if USE_FIXED
@@ -1644,6 +1647,9 @@ static void sbr_env_estimate(AAC_FLOAT (*e_curr)[48], 
INTFLOAT X_high[64][40][2]
 int iub = ch_data->t_env[e + 1] * 2 + ENVELOPE_ADJUSTMENT_OFFSET;
 const uint16_t *table = ch_data->bs_freq_res[e + 1] ? 
sbr->f_tablehigh : sbr->f_tablelow;
 
+if (ilb >= 40)
+return;
+
 for (p = 0; p < sbr->n[ch_data->bs_freq_res[e + 1]]; p++) {
 #if USE_FIXED
 SoftFloat sum = FLOAT_0;
-- 
2.49.0

___
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".


[FFmpeg-devel] [PATCH 3/8] avformat/imf_cpl: do not continue looping forever

2025-05-10 Thread Michael Niedermayer
Fixes: infinite loop
Fixes: 
401658595/clusterfuzz-testcase-minimized-ffmpeg_DEMUXER_fuzzer-5756875014733824
Regression since: 61fa1e14e4178d3f2550c76f7a36484220f6dc0c

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 
---
 libavformat/imf_cpl.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavformat/imf_cpl.c b/libavformat/imf_cpl.c
index 137cff2a63c..6ddea62abef 100644
--- a/libavformat/imf_cpl.c
+++ b/libavformat/imf_cpl.c
@@ -709,8 +709,7 @@ static int fill_virtual_tracks(void *log_ctx, xmlNodePtr 
cpl_element, FFIMFCPL *
 av_log(log_ctx, AV_LOG_DEBUG, "Processing IMF CPL Segment\n");
 
 sequence_list_elem = 
ff_imf_xml_get_child_element_by_name(segment_elem, "SequenceList");
-if (!sequence_list_elem)
-continue;
+if (sequence_list_elem) {
 
 sequence_elem = xmlFirstElementChild(sequence_list_elem);
 while (sequence_elem) {
@@ -735,6 +734,7 @@ static int fill_virtual_tracks(void *log_ctx, xmlNodePtr 
cpl_element, FFIMFCPL *
 
 sequence_elem = xmlNextElementSibling(sequence_elem);
 }
+}
 
 segment_elem = xmlNextElementSibling(segment_elem);
 }
-- 
2.49.0

___
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".


[FFmpeg-devel] [PATCH 2/8] avformat/mov: reject negative ELST durations

2025-05-10 Thread Michael Niedermayer
Fixes: multiple integer overflows
Fixes: 
401016767/clusterfuzz-testcase-minimized-ffmpeg_dem_MOV_fuzzer-6242067591790592

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 
---
 libavformat/mov.c | 5 +
 1 file changed, 5 insertions(+)

diff --git a/libavformat/mov.c b/libavformat/mov.c
index cb81b6c4da8..8a094b1ea0a 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -6295,6 +6295,11 @@ static int mov_read_elst(MOVContext *c, AVIOContext *pb, 
MOVAtom atom)
c->fc->nb_streams-1, i, e->time);
 return AVERROR_INVALIDDATA;
 }
+if (e->duration < 0) {
+av_log(c->fc, AV_LOG_ERROR, "Track %d, edit %d: Invalid edit list 
duration=%"PRId64"\n",
+   c->fc->nb_streams-1, i, e->duration);
+return AVERROR_INVALIDDATA;
+}
 }
 sc->elst_count = i;
 
-- 
2.49.0

___
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".


[FFmpeg-devel] [PATCH 1/8] avcodec/dnxuc_parser: Use ff_parse_close()

2025-05-10 Thread Michael Niedermayer
Fixes: buffer leak
Fixes: 
398894512/clusterfuzz-testcase-minimized-ffmpeg_DEMUXER_fuzzer-6716597473705984

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 
---
 libavcodec/dnxuc_parser.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libavcodec/dnxuc_parser.c b/libavcodec/dnxuc_parser.c
index 14f19efe676..34088ac3b1c 100644
--- a/libavcodec/dnxuc_parser.c
+++ b/libavcodec/dnxuc_parser.c
@@ -85,4 +85,5 @@ const AVCodecParser ff_dnxuc_parser = {
 .codec_ids  = { AV_CODEC_ID_DNXUC },
 .priv_data_size = sizeof(DNxUcParseContext),
 .parser_parse   = dnxuc_parse,
+.parser_close   = ff_parse_close,
 };
-- 
2.49.0

___
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".


[FFmpeg-devel] [PATCH 6/8] avcodec/sonic: Check num_taps

2025-05-10 Thread Michael Niedermayer
The encoder uses max 128 taps, which is quiet a lot already
If work is done to improve sonic, it will be more radical than changing the taps

Fixes: Timeout
Fixes: 
402539974/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SONIC_fuzzer-6122944271286272

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 
---
 libavcodec/sonic.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/libavcodec/sonic.c b/libavcodec/sonic.c
index 60b077de47d..8b1d092ec91 100644
--- a/libavcodec/sonic.c
+++ b/libavcodec/sonic.c
@@ -924,6 +924,9 @@ static av_cold int sonic_decode_init(AVCodecContext *avctx)
 if (get_bits1(&gb)) // XXX FIXME
 av_log(avctx, AV_LOG_INFO, "Custom quant table\n");
 
+if (s->num_taps > 128)
+return AVERROR_INVALIDDATA;
+
 s->block_align = 2048LL*s->samplerate/(44100*s->downsampling);
 s->frame_size = s->channels*s->block_align*s->downsampling;
 //avctx->frame_size = s->block_align;
-- 
2.49.0

___
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".


[FFmpeg-devel] [PATCH 8/8] avcodec/svq3: Check there are bits left before decompression

2025-05-10 Thread Michael Niedermayer
Fixes: out of array read
Fixes: 
402587670/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SVQ3_fuzzer-6343867775647744

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 
---
 libavcodec/svq3.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libavcodec/svq3.c b/libavcodec/svq3.c
index 30bc9334af7..7a95aa4cff9 100644
--- a/libavcodec/svq3.c
+++ b/libavcodec/svq3.c
@@ -1253,6 +1253,7 @@ static av_cold int svq3_decode_init(AVCodecContext *avctx)
 uint8_t *buf;
 
 if (watermark_height <= 0 ||
+get_bits_left(&gb) <= 0 ||
 (uint64_t)watermark_width * 4 > UINT_MAX / watermark_height)
 return AVERROR_INVALIDDATA;
 
-- 
2.49.0

___
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".


[FFmpeg-devel] [PATCH 7/8] avcodec/svq3: Check that for 8 byte space before subtracting

2025-05-10 Thread Michael Niedermayer
No testcase

Signed-off-by: Michael Niedermayer 
---
 libavcodec/svq3.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/svq3.c b/libavcodec/svq3.c
index f730358e2f9..30bc9334af7 100644
--- a/libavcodec/svq3.c
+++ b/libavcodec/svq3.c
@@ -1173,7 +1173,7 @@ static av_cold int svq3_decode_init(AVCodecContext *avctx)
 int w,h;
 
 size = AV_RB32(&extradata[4]);
-if (size > extradata_end - extradata - 8)
+if (extradata_end - extradata < 8 || size > extradata_end - extradata 
- 8)
 return AVERROR_INVALIDDATA;
 init_get_bits(&gb, extradata + 8, size * 8);
 
-- 
2.49.0

___
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".


[FFmpeg-devel] [PATCH] lavf: vvc_probe: enforce SPS -> PPS -> IRAP detection order to fix invalid stream detection

2025-05-10 Thread xiongweixiao
The current vvc_probe function checks for SPS, PPS, and IRAP NAL units but does 
not enforce their detection order. This can lead to false positives when PPS or 
IRAP appear before SPS, causing malformed or non-compliant bitstreams to be 
incorrectly identified as valid VVC streams.

This patch modifies the logic to use boolean flags and enforces the correct 
detection sequence: SPS must be detected before PPS, and PPS before IRAP. This 
ensures more accurate probing and prevents invalid bitstreams from being 
misidentified.

This change addresses issues reported in:
- https://trac.ffmpeg.org/ticket/11496
- https://trac.ffmpeg.org/ticket/11087

Signed-off-by: xiongweixiao 
---
 libavformat/vvcdec.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavformat/vvcdec.c b/libavformat/vvcdec.c
index 0a0e24b71c..573b352f41 100644
--- a/libavformat/vvcdec.c
+++ b/libavformat/vvcdec.c
@@ -60,11 +60,11 @@ static int vvc_probe(const AVProbeData *p)
 
 switch (type) {
 case VVC_SPS_NUT:   sps++;  break;
-case VVC_PPS_NUT:   pps++;  break;
+case VVC_PPS_NUT:   if (sps) pps++;  break;
 case VVC_IDR_N_LP:
 case VVC_IDR_W_RADL:
 case VVC_CRA_NUT:
-case VVC_GDR_NUT:   irap++; break;
+case VVC_GDR_NUT:   if (pps) irap++; break;
 }
 }
 }
-- 
2.34.1

___
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".


[FFmpeg-devel] [PATCH] avcodec/h2645_sei: allow building h2645_sei without

2025-05-10 Thread dev
Hello,

This is my first time sending a patch here, please let me know if I got the 
process wrong.

I was building a minimal libav for WebAssembly with Emscripten, with only H264 
and AAC. It fails unless I also enable other configs that would increase code 
size.
Seems like someone forgot to guard a call with a config macro. This patch adds 
it, just like the other occurrences in this same file. Everything works fine 
after that.

Thanks!




0001-avcodec-h2645_sei-allow-building-h2645_sei-without-C.patch
Description: Binary data
___
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".


[FFmpeg-devel] [PATCH 3/3] avformat/iamf_parse: check space left for AAC

2025-05-10 Thread Michael Niedermayer
Fixes: Assertion n>=0 && n<=32 failed at ./libavcodec/get_bits.h:406
Fixes: 
398527871/clusterfuzz-testcase-minimized-ffmpeg_dem_IAMF_fuzzer-6602025714647040

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 
---
 libavformat/iamf_parse.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavformat/iamf_parse.c b/libavformat/iamf_parse.c
index abedfdb0668..37fb25962c4 100644
--- a/libavformat/iamf_parse.c
+++ b/libavformat/iamf_parse.c
@@ -304,6 +304,8 @@ static int update_extradata(AVCodecParameters *codecpar)
 skip_bits(&gb, 4);
 put_bits(&pb, 4, codecpar->ch_layout.nb_channels); // set channel 
config
 ret = put_bits_left(&pb);
+if (ret < 0)
+return AVERROR_INVALIDDATA;
 put_bits(&pb, ret, get_bits_long(&gb, ret));
 flush_put_bits(&pb);
 
-- 
2.49.0

___
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".


[FFmpeg-devel] [PATCH 2/3] avformat/avidec: Ignore duplicate GAB2

2025-05-10 Thread Michael Niedermayer
Fixes: memleak
Fixes: 
398401912/clusterfuzz-testcase-minimized-ffmpeg_dem_AVI_fuzzer-4669849976766464

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 
---
 libavformat/avidec.c | 4 
 1 file changed, 4 insertions(+)

diff --git a/libavformat/avidec.c b/libavformat/avidec.c
index 1ae09efc150..81a0ae31bab 100644
--- a/libavformat/avidec.c
+++ b/libavformat/avidec.c
@@ -1122,6 +1122,10 @@ static int read_gab2_sub(AVFormatContext *s, AVStream 
*st, AVPacket *pkt)
 int size;
 AVProbeData pd;
 unsigned int desc_len;
+
+if (ast->sub_ctx)
+return 0;
+
 AVIOContext *pb = avio_alloc_context(pkt->data + 7,
  pkt->size - 7,
  0, NULL, NULL, NULL, NULL);
-- 
2.49.0

___
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".


[FFmpeg-devel] [PATCH 1/3] avformat/flvdec: Set last_ts before its timestamp is lost in ff_buffer_packet()

2025-05-10 Thread Michael Niedermayer
Fixes: signed integer overflow: -9223372036315799519 + -9223372036854775807 
cannot be represented in type 'long'
Fixes: 
398356258/clusterfuzz-testcase-minimized-ffmpeg_dem_LIVE_FLV_fuzzer-4905723095482368

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 
---
 libavformat/flvdec.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/libavformat/flvdec.c b/libavformat/flvdec.c
index b90ed34b1c5..8af317f3cc9 100644
--- a/libavformat/flvdec.c
+++ b/libavformat/flvdec.c
@@ -1852,6 +1852,7 @@ retry_duration:
 stream_type == FLV_STREAM_TYPE_DATA)
 pkt->flags |= AV_PKT_FLAG_KEY;
 
+flv->last_ts = pkt->dts;
 ret = ff_buffer_packet(s, pkt);
 if (ret < 0)
 return ret;
@@ -1906,8 +1907,6 @@ leave:
 }
 }
 
-if (ret >= 0)
-flv->last_ts = pkt->dts;
 
 return ret ? ret : res;
 }
-- 
2.49.0

___
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 3/3] avformat/iamf_parse: check space left for AAC

2025-05-10 Thread James Almer

On 5/10/2025 11:36 AM, Michael Niedermayer wrote:

Fixes: Assertion n>=0 && n<=32 failed at ./libavcodec/get_bits.h:406
Fixes: 
398527871/clusterfuzz-testcase-minimized-ffmpeg_dem_IAMF_fuzzer-6602025714647040

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 
---
  libavformat/iamf_parse.c | 2 ++
  1 file changed, 2 insertions(+)

diff --git a/libavformat/iamf_parse.c b/libavformat/iamf_parse.c
index abedfdb0668..37fb25962c4 100644
--- a/libavformat/iamf_parse.c
+++ b/libavformat/iamf_parse.c
@@ -304,6 +304,8 @@ static int update_extradata(AVCodecParameters *codecpar)
  skip_bits(&gb, 4);
  put_bits(&pb, 4, codecpar->ch_layout.nb_channels); // set channel 
config
  ret = put_bits_left(&pb);
+if (ret < 0)
+return AVERROR_INVALIDDATA;
  put_bits(&pb, ret, get_bits_long(&gb, ret));
  flush_put_bits(&pb);


No, there's something wrong because the buffer for PutBytes is fixed and 
local. Maybe 5 bytes was not enough.


Will have a look.



OpenPGP_signature.asc
Description: OpenPGP digital signature
___
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".


[FFmpeg-devel] Version 4.4.6 is stable?

2025-05-10 Thread johannakity-00--- via ffmpeg-devel
Hello everybody,

In the branch release/4.4 I can see update for 4.4.6 but the latest stable 
release for 4.4 is the version 4.4.5.
Is version 4.4.6 stable?

Thanks,
Giovanni
___
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".