[FFmpeg-cvslog] [ffmpeg] branch master updated. b815431126 Revert "avformat/tls_openssl: add av_assert0() for tls_shared"

2025-09-22 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  b815431126c8feb7557f61bb16bf6b572993089a (commit)
  from  db6cd6c6bfe6f306dd8d9de2a0086586cbd27ec1 (commit)


- Log -
commit b815431126c8feb7557f61bb16bf6b572993089a
Author: Andreas Rheinhardt 
AuthorDate: Thu Sep 18 14:58:55 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Mon Sep 22 22:02:03 2025 +0200

Revert "avformat/tls_openssl: add av_assert0() for tls_shared"

This reverts commits fd55c4b5f72a157fbb128d0ef203e9922b53552b
(for tls_openssl.c) and c74181a04b5f4e650eae662231e56518daef64d4
(for tls_gnutls.c).

It is impossible for a pointer to a member of a structure
to be NULL: If the containing structure exists, the member
exists and can't have a NULL address; if the containing
structure does not exist, then getting a pointer to the
substructure via &c->tls_shared would already be undefined
behavior.

Reviewed-by: Kacper Michajłow 
Reviewed-by: Steven Liu 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavformat/tls_gnutls.c b/libavformat/tls_gnutls.c
index fe2fd53291..e4fe53318c 100644
--- a/libavformat/tls_gnutls.c
+++ b/libavformat/tls_gnutls.c
@@ -30,7 +30,6 @@
 #include "os_support.h"
 #include "url.h"
 #include "tls.h"
-#include "libavutil/avassert.h"
 #include "libavutil/opt.h"
 #include "libavutil/thread.h"
 
@@ -156,7 +155,6 @@ static int tls_open(URLContext *h, const char *uri, int 
flags, AVDictionary **op
 TLSShared *s = &c->tls_shared;
 uint16_t gnutls_flags = 0;
 int ret;
-av_assert0(s);
 
 ff_gnutls_init();
 
@@ -262,7 +260,6 @@ static int dtls_open(URLContext *h, const char *uri, int 
flags, AVDictionary **o
 {
 TLSContext *c = h->priv_data;
 TLSShared *s = &c->tls_shared;
-av_assert0(s);
 s->is_dtls = 1;
 return tls_open(h, uri, flags, options);
 }
diff --git a/libavformat/tls_openssl.c b/libavformat/tls_openssl.c
index 86b4d21799..5fc0b639d7 100644
--- a/libavformat/tls_openssl.c
+++ b/libavformat/tls_openssl.c
@@ -20,7 +20,6 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "libavutil/avassert.h"
 #include "libavutil/mem.h"
 #include "network.h"
 #include "os_support.h"
@@ -746,7 +745,6 @@ static int dtls_start(URLContext *h, const char *url, int 
flags, AVDictionary **
 TLSContext *c = h->priv_data;
 TLSShared *s = &c->tls_shared;
 int ret = 0;
-av_assert0(s);
 s->is_dtls = 1;
 
 c->ctx = SSL_CTX_new(s->listen ? DTLS_server_method() : 
DTLS_client_method());
@@ -847,7 +845,6 @@ static int tls_open(URLContext *h, const char *uri, int 
flags, AVDictionary **op
 TLSShared *s = &c->tls_shared;
 int ret;
 
-av_assert0(s);
 if ((ret = ff_tls_open_underlying(s, h, uri, options)) < 0)
 goto fail;
 

---

Summary of changes:
 libavformat/tls_gnutls.c  | 3 ---
 libavformat/tls_openssl.c | 3 ---
 2 files changed, 6 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. b1cbc7c8ff configure: strip non numeric trailer from gcc version

2025-09-22 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  b1cbc7c8ff515159130bc4290ef6ab204e7101e8 (commit)
  from  b815431126c8feb7557f61bb16bf6b572993089a (commit)


- Log -
commit b1cbc7c8ff515159130bc4290ef6ab204e7101e8
Author: Michael Niedermayer 
AuthorDate: Sun Sep 21 16:49:45 2025 +0200
Commit: michaelni 
CommitDate: Mon Sep 22 21:41:42 2025 +

configure: strip non numeric trailer from gcc version

Fixes: ../configure: 7820: [: Illegal number: 13-win32

Signed-off-by: Michael Niedermayer 

diff --git a/configure b/configure
index 98de8e5dff..9d5a6ffc14 100755
--- a/configure
+++ b/configure
@@ -7816,7 +7816,7 @@ if enabled icc; then
 fi
 elif enabled gcc; then
 gcc_version=$($cc -dumpversion)
-major_version=${gcc_version%%.*}
+major_version=${gcc_version%%[!0-9]*}
 if [ $major_version -lt 13 ]; then
 # Disable tree-vectorize for GCC <13 - it has historically been buggy.
 check_optflags -fno-tree-vectorize

---

Summary of changes:
 configure | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch release/8.0 updated. b9adbf0fcc fftools/ffmpeg: fix gracefully shutdown

2025-09-22 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, release/8.0 has been updated
   via  b9adbf0fcc26e04a0f291c9f8857affb4540a6e3 (commit)
  from  e322e2e5d94100a2be0853033d6c124ec8249b78 (commit)


- Log -
commit b9adbf0fcc26e04a0f291c9f8857affb4540a6e3
Author: Patrick Wang 
AuthorDate: Fri Aug 29 02:58:16 2025 +0800
Commit: Marton Balint 
CommitDate: Mon Sep 22 22:46:25 2025 +0200

fftools/ffmpeg: fix gracefully shutdown

d119ae2fd82a494d9430ff4d4fc262961a68c598 removed the loop-breaking condition
received_sigterm.
Thus, signals no longer gracefully shutdown ffmpeg.

Fixes: #10834

Signed-off-by: Patrick Wang 
Signed-off-by: Michael Niedermayer 
(cherry picked from commit d7173e982ec815dcf70999c8683c465b99ce249c)

diff --git a/fftools/ffmpeg.c b/fftools/ffmpeg.c
index de607cac93..cbeefb71d6 100644
--- a/fftools/ffmpeg.c
+++ b/fftools/ffmpeg.c
@@ -806,8 +806,6 @@ static int check_keyboard_interaction(int64_t cur_time)
 {
 int i, key;
 static int64_t last_time;
-if (received_nb_signals)
-return AVERROR_EXIT;
 /* read_key() returns 0 on EOF */
 if (cur_time - last_time >= 10) {
 key =  read_key();
@@ -891,6 +889,9 @@ static int transcode(Scheduler *sch)
 while (!sch_wait(sch, stats_period, &transcode_ts)) {
 int64_t cur_time= av_gettime_relative();
 
+if (received_nb_signals)
+break;
+
 /* if 'q' pressed, exits */
 if (stdin_interaction)
 if (check_keyboard_interaction(cur_time) < 0)

---

Summary of changes:
 fftools/ffmpeg.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. ced4a6ebc9 libavutil/arm: Rename the HWCAP defines

2025-09-22 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  ced4a6ebc9e7cd92d0ca9b9fb8f9d1013d23cbfa (commit)
  from  cdae5c3639f4adcd289e643a203d43d4e01d87f5 (commit)


- Log -
commit ced4a6ebc9e7cd92d0ca9b9fb8f9d1013d23cbfa
Author: Brad Smith 
AuthorDate: Mon Sep 22 07:28:21 2025 -0400
Commit: Brad Smith 
CommitDate: Mon Sep 22 07:28:21 2025 -0400

libavutil/arm: Rename the HWCAP defines

Rename the HWCAP defines to use the same naming scheme as AArch64 and PPC.

Signed-off-by: Brad Smith 

diff --git a/libavutil/arm/cpu.c b/libavutil/arm/cpu.c
index 8ec28143d7..2e2977efc9 100644
--- a/libavutil/arm/cpu.c
+++ b/libavutil/arm/cpu.c
@@ -47,12 +47,12 @@
 #endif
 
 /* Relevant HWCAP values from kernel headers */
-#define HWCAP_VFP   (1 << 6)
-#define HWCAP_EDSP  (1 << 7)
-#define HWCAP_THUMBEE   (1 << 11)
-#define HWCAP_NEON  (1 << 12)
-#define HWCAP_VFPv3 (1 << 13)
-#define HWCAP_TLS   (1 << 15)
+#define HWCAP_ARM_VFP (1 << 6)
+#define HWCAP_ARM_EDSP(1 << 7)
+#define HWCAP_ARM_THUMBEE (1 << 11)
+#define HWCAP_ARM_NEON(1 << 12)
+#define HWCAP_ARM_VFPv3   (1 << 13)
+#define HWCAP_ARM_TLS (1 << 15)
 
 static int get_auxval(uint32_t *hwcap)
 {
@@ -101,19 +101,19 @@ static int get_cpuinfo(uint32_t *hwcap)
 while (fgets(buf, sizeof(buf), f)) {
 if (av_strstart(buf, "Features", NULL)) {
 if (strstr(buf, " edsp "))
-*hwcap |= HWCAP_EDSP;
+*hwcap |= HWCAP_ARM_EDSP;
 if (strstr(buf, " tls "))
-*hwcap |= HWCAP_TLS;
+*hwcap |= HWCAP_ARM_TLS;
 if (strstr(buf, " thumbee "))
-*hwcap |= HWCAP_THUMBEE;
+*hwcap |= HWCAP_ARM_THUMBEE;
 if (strstr(buf, " vfp "))
-*hwcap |= HWCAP_VFP;
+*hwcap |= HWCAP_ARM_VFP;
 if (strstr(buf, " vfpv3 "))
-*hwcap |= HWCAP_VFPv3;
+*hwcap |= HWCAP_ARM_VFPv3;
 if (strstr(buf, " neon ") || strstr(buf, " asimd "))
-*hwcap |= HWCAP_NEON;
+*hwcap |= HWCAP_ARM_NEON;
 if (strstr(buf, " fp ")) // Listed on 64 bit ARMv8 kernels
-*hwcap |= HWCAP_VFP | HWCAP_VFPv3;
+*hwcap |= HWCAP_ARM_VFP | HWCAP_ARM_VFPv3;
 break;
 }
 }
@@ -135,7 +135,7 @@ int ff_get_cpu_flags_arm(void)
 return flags;
 
 #define check_cap(cap, flag) do {   \
-if (hwcap & HWCAP_ ## cap)  \
+if (hwcap & HWCAP_ARM_ ## cap)  \
 flags |= AV_CPU_FLAG_ ## flag;  \
 } while (0)
 

---

Summary of changes:
 libavutil/arm/cpu.c | 28 ++--
 1 file changed, 14 insertions(+), 14 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 15a9c8dea3 avcodec/liblc3enc: Avoid allocating buffer to send a zero frame

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  15a9c8dea32048d9746329430313f5700ba74ff3 (commit)
  from  ab7d1c64c9aa9186acb1d988d020e59f2d3defce (commit)


- Log -
commit 15a9c8dea32048d9746329430313f5700ba74ff3
Author: Andreas Rheinhardt 
AuthorDate: Tue Sep 30 18:53:08 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Sat Oct 4 06:07:37 2025 +0200

avcodec/liblc3enc: Avoid allocating buffer to send a zero frame

liblc3 supports arbitrary strides, so one can simply use a stride
of zero to make it read the same zero value again and again.

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/liblc3enc.c b/libavcodec/liblc3enc.c
index 66007a90f3..72c117b993 100644
--- a/libavcodec/liblc3enc.c
+++ b/libavcodec/liblc3enc.c
@@ -137,7 +137,6 @@ static int liblc3_encode(AVCodecContext *avctx, AVPacket 
*pkt,
 LibLC3EncContext *liblc3 = avctx->priv_data;
 int block_bytes = liblc3->block_bytes;
 int channels = avctx->ch_layout.nb_channels;
-void *zero_frame = NULL;
 uint8_t *data_ptr;
 int ret;
 
@@ -152,25 +151,20 @@ static int liblc3_encode(AVCodecContext *avctx, AVPacket 
*pkt,
 return 0;
 
 liblc3->remaining_samples = 0;
-zero_frame = av_mallocz(avctx->frame_size * sizeof(float));
-if (!zero_frame)
-return AVERROR(ENOMEM);
 }
 
 data_ptr = pkt->data;
 for (int ch = 0; ch < channels; ch++) {
-const float *pcm = zero_frame ? zero_frame : frame->data[ch];
+const float *pcm = frame ? (const float*)frame->data[ch] : (const 
float[]){ 0 };
+int stride = !!frame; // use a stride of zero to send a zero frame
 int nbytes = block_bytes / channels + (ch < block_bytes % channels);
 
 lc3_encode(liblc3->encoder[ch],
-   LC3_PCM_FORMAT_FLOAT, pcm, 1, nbytes, data_ptr);
+   LC3_PCM_FORMAT_FLOAT, pcm, stride, nbytes, data_ptr);
 
 data_ptr += nbytes;
 }
 
-if (zero_frame)
-av_free(zero_frame);
-
 *got_packet_ptr = 1;
 
 return 0;

---

Summary of changes:
 libavcodec/liblc3enc.c | 12 +++-
 1 file changed, 3 insertions(+), 9 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. a24e0f536d avcodec/x86/hpeldsp_init: Remove check for inline mmx

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  a24e0f536dc1056756ad56775a3d1564a2cb0a3f (commit)
  from  b0c77e5a126b00a02a63359ed279d6e8e966a963 (commit)


- Log -
commit a24e0f536dc1056756ad56775a3d1564a2cb0a3f
Author: Andreas Rheinhardt 
AuthorDate: Sun Oct 12 05:14:24 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Tue Oct 14 12:31:15 2025 +0200

avcodec/x86/hpeldsp_init: Remove check for inline mmx

Forgotten in 4c55724da86ddc5ef10966f287a3d50fe1a1cbbe.

Reviewed-by: Michael Niedermayer 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/x86/hpeldsp_init.c b/libavcodec/x86/hpeldsp_init.c
index f4b123ce03..1640ff83b6 100644
--- a/libavcodec/x86/hpeldsp_init.c
+++ b/libavcodec/x86/hpeldsp_init.c
@@ -143,7 +143,7 @@ av_cold void ff_hpeldsp_init_x86(HpelDSPContext *c, int 
flags)
 {
 int cpu_flags = av_get_cpu_flags();
 
-if (INLINE_MMX(cpu_flags))
+if (EXTERNAL_MMX(cpu_flags))
 hpeldsp_init_mmx(c, flags);
 
 if (EXTERNAL_MMXEXT(cpu_flags))

---

Summary of changes:
 libavcodec/x86/hpeldsp_init.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 1608aa38a2 doc/infra: More details about hosting and security

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  1608aa38a2ca9bd49debc5577ee38e2726303eda (commit)
  from  fd136a4d826d9eb2509dbb8d2869575ff8e74434 (commit)


- Log -
commit 1608aa38a2ca9bd49debc5577ee38e2726303eda
Author: Nikolay Aleksandrov 
AuthorDate: Mon Nov 25 17:26:53 2024 +0100
Commit: Michael Niedermayer 
CommitDate: Tue Sep 30 13:14:03 2025 +0200

doc/infra: More details about hosting and security

Signed-off-by: Michael Niedermayer 

I have redacted the exact location of the FFmpeg server as writing
that in public seems just a bad idea

diff --git a/doc/infra.txt b/doc/infra.txt
index 490c6cdbd9..b5546aedd4 100644
--- a/doc/infra.txt
+++ b/doc/infra.txt
@@ -24,6 +24,26 @@ Our Main server is hosted at telepoint.bg
 for more details see: https://www.ffmpeg.org/#thanks_sponsor_0001
 Nothing runs on our main server directly, instead several VMs run on it.
 
+Main server security:
+-
+Telepoint is one of the largest Bulgarian DC providers with multiple sibling 
companies offering
+Internet, SDH, DWDM, peering exchange and hosting. They have multiple DC 
buildings in Sofia and
+FFmpeg is hosted in XXX. The building is locked 
down and accessible
+only with personal key cards that are registered. People who are granted 
access to a rack have
+to go through the access center with their ID to get logged and receive a 
one-time access card
+that can open the service elevator and only the hall where the destination 
rack is. All racks are
+locked, once access is granted to someone they will get a key for the rack for 
the duration of
+their visit. There are security cameras everywhere and personnel in the access 
center 24/7. As for
+software security, our BIOS and IPMI are protected by password and encrypted 
connection, and
+the machines can be accessed only by root administrators with their SSH keys. 
They're using
+a Ubuntu LTS release and get regular security updates as they are released. We 
also get
+notified by email for various security related events (e.g. failed sudo).
+
+Side note - Telepoint provides the rack and physical infrastructure, their 
sibling company called
+Telehouse which is an ISP provides the connectivity, they are 
directly connected with
+over 15 tier-1 service providers and have over 100 PoPs (points of 
presence)
+in various cities. You can see more on www.telehouse.bg
+
 
 ffmpeg.org VM:
 --

---

Summary of changes:
 doc/infra.txt | 20 
 1 file changed, 20 insertions(+)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. e5ac70042e avformat/aiff: add support for ADPCM N64 decoder

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  e5ac70042e91d19110a04a52b7e6fa4703f61200 (commit)
   via  00eef7433641a0af7741eee2b5f6b1c1870c2a15 (commit)
   via  745cb6f8c7ffb957c598d12e83791c9f480a157e (commit)
   via  97bfb606e33f7457ccf405f755ca01424a7aa0d1 (commit)
   via  e0638cee0aa1bdd94af0e0898f24afa5e5b54e14 (commit)
   via  066432ebcf94a753d44be8b60b9dd725a14e704f (commit)
   via  5d6c9a15eb147feb90140e90d04a9340bf8454e2 (commit)
   via  f6dfb20302ec56dd89bc0ef6fcd98f7e14db90bf (commit)
   via  a4f778890bbdc351d1abc5da2516fd2ee5e6ba85 (commit)
   via  30fc5b1baaa0823f134768823ab6695211d0fe21 (commit)
   via  58c0711fca17cb5231506c63f63a2aa5568a4997 (commit)
   via  1943b31cdd179c3fc998430c40cde0e28257b692 (commit)
   via  5fc9c79f53d799f76a8f69e5821ad0a5867512b0 (commit)
   via  648b5d017d0478a0cd30f3753ab556b7721ff2b6 (commit)
   via  424dbb03ae2870a1edc9c43890b174f27ffc0746 (commit)
   via  e95171fbffd8bafcab42f9a22e257dce733c5b97 (commit)
   via  b2e821310b9c78b866306ad2b01ce63c1481382a (commit)
  from  b1cbc7c8ff515159130bc4290ef6ab204e7101e8 (commit)


- Log -
commit e5ac70042e91d19110a04a52b7e6fa4703f61200
Author: Paul B Mahol 
AuthorDate: Mon Nov 25 13:30:45 2024 +
Commit: michaelni 
CommitDate: Mon Sep 22 23:46:29 2025 +

avformat/aiff: add support for ADPCM N64 decoder

(cherry picked from commit 0fdf549a890f276243ba62f194e0ec08b10df60f)
Signed-off-by: Michael Niedermayer 

diff --git a/libavformat/aiff.c b/libavformat/aiff.c
index 907f7d8d28..3e94dad671 100644
--- a/libavformat/aiff.c
+++ b/libavformat/aiff.c
@@ -50,6 +50,7 @@ const AVCodecTag ff_codec_aiff_tags[] = {
 { AV_CODEC_ID_CBD2_DPCM,MKTAG('C','B','D','2') },
 { AV_CODEC_ID_SDX2_DPCM,MKTAG('S','D','X','2') },
 { AV_CODEC_ID_ADPCM_IMA_WS, MKTAG('A','D','P','4') },
+{ AV_CODEC_ID_ADPCM_N64,MKTAG('V','A','P','C') },
 { AV_CODEC_ID_NONE, 0 },
 };
 
diff --git a/libavformat/aiffdec.c b/libavformat/aiffdec.c
index aeb00cccd0..d9d580bdb5 100644
--- a/libavformat/aiffdec.c
+++ b/libavformat/aiffdec.c
@@ -177,6 +177,9 @@ static int get_aiff_header(AVFormatContext *s, int64_t size,
 case AV_CODEC_ID_G728:
 par->block_align = 5;
 break;
+case AV_CODEC_ID_ADPCM_N64:
+par->block_align = 9;
+break;
 default:
 aiff->block_duration = 1;
 break;
@@ -353,6 +356,31 @@ static int aiff_read_header(AVFormatContext *s)
 
 goto got_sound;
 break;
+case MKTAG('A','P','P','L'):
+if (size > 4) {
+uint32_t chunk = avio_rl32(pb);
+
+size -= 4;
+if (chunk == MKTAG('s','t','o','c')) {
+int len = avio_r8(pb);
+
+size--;
+if (len == 11 && size > 11) {
+uint8_t chunk[11];
+
+ret = avio_read(pb, chunk, 11);
+if (ret > 0)
+size -= ret;
+if (!memcmp(chunk, "VADPCMCODES", sizeof(chunk))) {
+if ((ret = ff_get_extradata(s, st->codecpar, pb, 
size)) < 0)
+return ret;
+size -= ret;
+}
+}
+}
+}
+avio_skip(pb, size);
+break;
 case 0:
 if (offset > 0 && st->codecpar->block_align) // COMM && SSND
 goto got_sound;

commit 00eef7433641a0af7741eee2b5f6b1c1870c2a15
Author: Paul B Mahol 
AuthorDate: Mon Nov 18 19:04:42 2024 +
Commit: michaelni 
CommitDate: Mon Sep 22 23:46:29 2025 +

avformat/adxdec: add AHX support

(cherry picked from commit b40bb6ad1e5739dd7927f3be5c2a06fb8aeef0cb)
Signed-off-by: Michael Niedermayer 

diff --git a/libavformat/Makefile b/libavformat/Makefile
index 0171f1c480..19ed1d4374 100644
--- a/libavformat/Makefile
+++ b/libavformat/Makefile
@@ -92,7 +92,7 @@ OBJS-$(CONFIG_ADP_DEMUXER)   += adp.o
 OBJS-$(CONFIG_ADS_DEMUXER)   += ads.o
 OBJS-$(CONFIG_ADTS_MUXER)+= adtsenc.o apetag.o img2.o \
 id3v2enc.o
-OBJS-$(CONFIG_ADX_DEMUXER)   += adxdec.o
+OBJS-$(CONFIG_ADX_DEMUXER)   += adxdec.o rawdec.o
 OBJS-$(CONFIG_ADX_MUXER) += rawenc.o
 OBJS-$(CONFIG_AEA_DEMUXER)   += aeadec.o pcm.o
 OBJS-$(CONFIG_AEA_MUXER) += aeaenc.o rawenc.o
diff --git a/libavformat/adxdec.c b/libavformat/adxdec.c
index 0909884f19..00b652315f 100644
--- a/libavformat/adxdec.c
+++ b/libavformat/adxdec.c
@@ -27,11 +27,13 @@
 #include "avformat.h"
 #include "demux.h"
 #include "internal.h"
+#include "rawdec.h"
 
 #define BLOCK_S

[FFmpeg-cvslog] [ffmpeg] branch master updated. 469aad3897 avformat/whip: add ICE consent freshness support

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  469aad38977e47574f019c8d69715dc7be74f92d (commit)
   via  aba84db96fb440403c162177d82e3f259db7432a (commit)
  from  aa91ae25b88e195e6af4248e0ab30605735ca1cd (commit)


- Log -
commit 469aad38977e47574f019c8d69715dc7be74f92d
Author: Jack Lau 
AuthorDate: Wed Sep 10 15:26:22 2025 +0800
Commit: stevenliu 
CommitDate: Thu Oct 9 09:29:25 2025 +

avformat/whip: add ICE consent freshness support

Refer to RFC 9725 4.2,
"Once a session is set up, consent freshness as per
[RFC7675] SHALL be used to detect non-graceful
disconnection by full ICE implementations and DTLS
teardown for session termination by either side"

Refer to RFC 7675,
send STUN Binding request every 5s,
expire consent after 30s without response,
terminate session when the consent expired.

TODO:
Random consent check interval (4-6s) will be
added later.

Co-authored-by: Sergio Garcia Murillo 
Signed-off-by: Jack Lau 

diff --git a/libavformat/whip.c b/libavformat/whip.c
index b8350ff98c..dff2502afd 100644
--- a/libavformat/whip.c
+++ b/libavformat/whip.c
@@ -161,6 +161,17 @@
 #define WHIP_SDP_SESSION_ID "4489045141692799359"
 #define WHIP_SDP_CREATOR_IP "127.0.0.1"
 
+/**
+ * Refer to RFC 7675 5.1,
+ *
+ * To prevent expiry of consent, a STUN binding request can be sent 
periodically.
+ * Implementations SHOULD set a default interval of 5 seconds(5000ms).
+ *
+ * Consent expires after 30 seconds(3ms).
+ */
+#define WHIP_ICE_CONSENT_CHECK_INTERVAL 5000
+#define WHIP_ICE_CONSENT_EXPIRED_TIMER 3
+
 /* Calculate the elapsed time from starttime to endtime in milliseconds. */
 #define ELAPSED(starttime, endtime) ((float)(endtime - starttime) / 1000)
 
@@ -273,6 +284,8 @@ typedef struct WHIPContext {
 int64_t whip_ice_time;
 int64_t whip_dtls_time;
 int64_t whip_srtp_time;
+int64_t whip_last_consent_tx_time;
+int64_t whip_last_consent_rx_time;
 
 /* The certificate and private key content used for DTLS handshake */
 char cert_buf[MAX_CERTIFICATE_SIZE];
@@ -1338,6 +1351,8 @@ next_packet:
 
 /* If got any DTLS messages, handle it. */
 if (is_dtls_packet(whip->buf, ret) && whip->state >= 
WHIP_STATE_ICE_CONNECTED || whip->state == WHIP_STATE_DTLS_CONNECTING) {
+/* Start consent timer when ICE selected */
+whip->whip_last_consent_tx_time = whip->whip_last_consent_rx_time 
= av_gettime_relative();
 whip->state = WHIP_STATE_DTLS_CONNECTING;
 ret = ffurl_handshake(whip->dtls_uc);
 if (ret < 0) {
@@ -1848,8 +1863,26 @@ static int whip_write_packet(AVFormatContext *s, 
AVPacket *pkt)
 WHIPContext *whip = s->priv_data;
 AVStream *st = s->streams[pkt->stream_index];
 AVFormatContext *rtp_ctx = st->priv_data;
-
-/* TODO: Send binding request every 1s as WebRTC heartbeat. */
+int64_t now = av_gettime_relative();
+/**
+ * Refer to RFC 7675
+ * Periodically send Consent Freshness STUN Binding Request
+ */
+if (now - whip->whip_last_consent_tx_time > 
WHIP_ICE_CONSENT_CHECK_INTERVAL * WHIP_US_PER_MS) {
+int size;
+ret = ice_create_request(s, whip->buf, sizeof(whip->buf), &size);
+if (ret < 0) {
+av_log(whip, AV_LOG_ERROR, "Failed to create STUN binding request, 
size=%d\n", size);
+goto end;
+}
+ret = ffurl_write(whip->udp, whip->buf, size);
+if (ret < 0) {
+av_log(whip, AV_LOG_ERROR, "Failed to send STUN binding request, 
size=%d\n", size);
+goto end;
+}
+whip->whip_last_consent_tx_time = now;
+av_log(whip, AV_LOG_DEBUG, "Consent Freshness check sent\n");
+}
 
 /**
  * Receive packets from the server such as ICE binding requests, DTLS 
messages,
@@ -1866,6 +1899,10 @@ static int whip_write_packet(AVFormatContext *s, 
AVPacket *pkt)
 av_log(whip, AV_LOG_ERROR, "Receive EOF from UDP socket\n");
 goto end;
 }
+if (ice_is_binding_response(whip->buf, ret)) {
+whip->whip_last_consent_rx_time = av_gettime_relative();
+av_log(whip, AV_LOG_DEBUG, "Consent Freshness check received\n");
+}
 if (is_dtls_packet(whip->buf, ret)) {
 if ((ret = ffurl_write(whip->dtls_uc, whip->buf, ret)) < 0) {
 av_log(whip, AV_LOG_ERROR, "Failed to handle DTLS message\n");
@@ -1886,6 +1923,14 @@ static int whip_write_packet(AVFormatContext *s, 
AVPacket *pkt)
 handle_nack_rtx(s, ret);
 }
 write_packet:
+now = av_gettime_relative();
+if (now - whip->whip_last_consent_rx_time > WHIP_ICE_CONSENT_EXPIRED_TIMER 
* WHIP_US_PER_MS) {
+av_log(whip, AV_LOG_ERROR,
+"Consent Freshness expired after %.2fms (limited %dms), terminate 
session\n",
+ELAPSED(now, whip->whip_last_consent_rx_time), 
WHIP_ICE_CONSENT

[FFmpeg-cvslog] [ffmpeg] branch master updated. f1e9032a20 configure: unbreak glslang build

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  f1e9032a2000b8b885cffd6fed8eacd47b37673f (commit)
  from  d975dbd7b70e0b2f3f3b2950e5513c299b838810 (commit)


- Log -
commit f1e9032a2000b8b885cffd6fed8eacd47b37673f
Author: Gyan Doshi 
AuthorDate: Sun Sep 28 13:20:23 2025 +0530
Commit: Gyan Doshi 
CommitDate: Tue Sep 30 04:26:18 2025 +

configure: unbreak glslang build

Don't unconditionally link to libSPVRemapper which was removed in 16.0 in 
3a7f787

diff --git a/configure b/configure
index aaa72c9f93..399b1ce128 100755
--- a/configure
+++ b/configure
@@ -7132,12 +7132,16 @@ enabled libfontconfig && require_pkg_config 
libfontconfig fontconfig "fontco
 enabled libfreetype   && require_pkg_config libfreetype freetype2 
"ft2build.h FT_FREETYPE_H" FT_Init_FreeType
 enabled libfribidi&& require_pkg_config libfribidi fribidi fribidi.h 
fribidi_version_info
 enabled libharfbuzz   && require_pkg_config libharfbuzz harfbuzz hb.h 
hb_buffer_create
-enabled libglslang && { check_lib spirv_compiler 
glslang/Include/glslang_c_interface.h glslang_initialize_process \
+if enabled libglslang; then
+spvremap="-lSPVRemapper"
+require_headers "glslang/build_info.h" && { test_cpp_condition 
glslang/build_info.h "GLSLANG_VERSION_MAJOR >= 16" && spvremap="" ; }
+check_lib spirv_compiler glslang/Include/glslang_c_interface.h 
glslang_initialize_process \
 -lglslang -lMachineIndependent -lGenericCodeGen \
--lSPVRemapper -lSPIRV -lSPIRV-Tools-opt 
-lSPIRV-Tools -lpthread -lstdc++ -lm ||
+${spvremap} -lSPIRV -lSPIRV-Tools-opt 
-lSPIRV-Tools -lpthread -lstdc++ -lm ||
 require spirv_compiler 
glslang/Include/glslang_c_interface.h glslang_initialize_process \
 -lglslang -lMachineIndependent -lOSDependent 
-lHLSL -lOGLCompiler -lGenericCodeGen \
--lSPVRemapper -lSPIRV -lSPIRV-Tools-opt 
-lSPIRV-Tools -lpthread -lstdc++ -lm ; }
+${spvremap} -lSPIRV -lSPIRV-Tools-opt 
-lSPIRV-Tools -lpthread -lstdc++ -lm ;
+fi
 enabled libgme&& { check_pkg_config libgme libgme gme/gme.h 
gme_new_emu ||
require libgme gme/gme.h gme_new_emu -lgme 
-lstdc++; }
 enabled libgsm&& { for gsm_hdr in "gsm.h" "gsm/gsm.h"; do

---

Summary of changes:
 configure | 10 +++---
 1 file changed, 7 insertions(+), 3 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 95850f339e tests/checkasm: add a test for dcadsp

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  95850f339e96ac4ea82dd32cecc2c8795edcb47e (commit)
   via  99034b581f5608c1bb4edd52864b1bc973ad2dfb (commit)
  from  e05f8acabff468c1382277c1f31fa8e9d90c3202 (commit)


- Log -
commit 95850f339e96ac4ea82dd32cecc2c8795edcb47e
Author: James Almer 
AuthorDate: Sat Oct 4 14:14:32 2025 -0300
Commit: James Almer 
CommitDate: Sun Oct 5 10:09:04 2025 -0300

tests/checkasm: add a test for dcadsp

Signed-off-by: James Almer 

diff --git a/tests/checkasm/Makefile b/tests/checkasm/Makefile
index 1589a15e2f..82bcc21b01 100644
--- a/tests/checkasm/Makefile
+++ b/tests/checkasm/Makefile
@@ -31,7 +31,7 @@ AVCODECOBJS-$(CONFIG_AAC_DECODER)   += aacpsdsp.o \
 AVCODECOBJS-$(CONFIG_AAC_ENCODER)   += aacencdsp.o
 AVCODECOBJS-$(CONFIG_ALAC_DECODER)  += alacdsp.o
 AVCODECOBJS-$(CONFIG_APV_DECODER)   += apv_dsp.o
-AVCODECOBJS-$(CONFIG_DCA_DECODER)   += synth_filter.o
+AVCODECOBJS-$(CONFIG_DCA_DECODER)   += dcadsp.o synth_filter.o
 AVCODECOBJS-$(CONFIG_DIRAC_DECODER) += diracdsp.o
 AVCODECOBJS-$(CONFIG_EXR_DECODER)   += exrdsp.o
 AVCODECOBJS-$(CONFIG_FLAC_DECODER)  += flacdsp.o
diff --git a/tests/checkasm/checkasm.c b/tests/checkasm/checkasm.c
index e59d366f2b..d542f953e8 100644
--- a/tests/checkasm/checkasm.c
+++ b/tests/checkasm/checkasm.c
@@ -142,6 +142,7 @@ static const struct {
 { "bswapdsp", checkasm_check_bswapdsp },
 #endif
 #if CONFIG_DCA_DECODER
+{ "dcadsp", checkasm_check_dcadsp },
 { "synth_filter", checkasm_check_synth_filter },
 #endif
 #if CONFIG_DIRAC_DECODER
diff --git a/tests/checkasm/checkasm.h b/tests/checkasm/checkasm.h
index eda806e870..0382963daa 100644
--- a/tests/checkasm/checkasm.h
+++ b/tests/checkasm/checkasm.h
@@ -92,6 +92,7 @@ void checkasm_check_blockdsp(void);
 void checkasm_check_bswapdsp(void);
 void checkasm_check_colordetect(void);
 void checkasm_check_colorspace(void);
+void checkasm_check_dcadsp(void);
 void checkasm_check_diracdsp(void);
 void checkasm_check_exrdsp(void);
 void checkasm_check_fdctdsp(void);
diff --git a/tests/checkasm/dcadsp.c b/tests/checkasm/dcadsp.c
new file mode 100644
index 00..809a0a0974
--- /dev/null
+++ b/tests/checkasm/dcadsp.c
@@ -0,0 +1,101 @@
+/*
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FFmpeg; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
+#include 
+#include 
+
+#include "libavcodec/dcadata.h"
+#include "libavcodec/dcadsp.h"
+#include "libavutil/common.h"
+#include "libavutil/mem_internal.h"
+
+#include "checkasm.h"
+
+#define N 32
+#define BLOCKSIZE 128
+#define BUF_SIZE (N * BLOCKSIZE)
+#define LFE_HISTORY 8
+#define LFE_SIZE (N + LFE_HISTORY + 1)
+
+/* sign_extend(rnd(), 23) would be the correct approach here,
+ * but it results in differences that would require a much
+ * bigger EPS value, thus we use 16 (simplified as a cast). */
+#define randomize(buf, len) do {   \
+for (int i = 0; i < len; i++)  \
+(buf)[i] = (int16_t)rnd(); \
+} while (0)
+
+#define EPS 0.0005f
+
+static void test_lfe_fir_float(const DCADSPContext *dca)
+{
+LOCAL_ALIGNED_16(float, dst0,  [BUF_SIZE]);
+LOCAL_ALIGNED_16(float, dst1,  [BUF_SIZE]);
+LOCAL_ALIGNED_16(int32_t, lfe, [LFE_SIZE]);
+
+declare_func(void, float *pcm_samples, const int32_t *lfe_samples,
+   const float *filter_coeff, ptrdiff_t npcmblocks);
+
+for (int i = 0; i < 2; i++) {
+const float *coeffs = i ? ff_dca_lfe_fir_128 : ff_dca_lfe_fir_64;
+if (check_func(dca->lfe_fir_float[i], "lfe_fir%d_float", i)) {
+memset(dst0, 0, BUF_SIZE * sizeof(float));
+memset(dst1, 0, BUF_SIZE * sizeof(float));
+randomize(lfe, LFE_SIZE);
+call_ref(dst0, lfe + LFE_HISTORY, coeffs, N);
+call_new(dst1, lfe + LFE_HISTORY, coeffs, N);
+if (!float_near_abs_eps_array(dst0, dst1, EPS, BUF_SIZE))
+fail();
+bench_new(dst1, lfe + LFE_HISTORY, coeffs, N);
+}
+}
+}
+
+static void test_lfe_fir_fixed(void)
+{
+LOCAL_ALIGNED_16(int32_t, dst0, [BUF_SIZE]);
+LOCAL_ALIGNED_16(int32_t, dst1, [BUF_SIZE]);
+LOCAL_ALIGNED_16(int32_t, lfe,  [LFE_SIZE]);
+const int32_t *coeffs = ff_dca_lfe_fir_64_fixed;
+

[FFmpeg-cvslog] [ffmpeg] branch release/8.0 updated. d1f31a829d avformat/rtsp: fix leading space in RTSP reason

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, release/8.0 has been updated
   via  d1f31a829d018a3d9d46da93480182e565762000 (commit)
   via  1e56c51d3b4cb17c64dd6adf646fd87bd22d6de6 (commit)
   via  45fcd5567a4402c172aa7e92ad082a686dcddb83 (commit)
  from  558994b051424534fc598d7569fe2b896f103110 (commit)


- Log -
commit d1f31a829d018a3d9d46da93480182e565762000
Author: Marvin Scholz 
AuthorDate: Fri Aug 22 21:41:26 2025 +0200
Commit: Marvin Scholz 
CommitDate: Thu Oct 16 15:57:19 2025 +0200

avformat/rtsp: fix leading space in RTSP reason

When parsing the RTSP message reason, the whole remainder
after parsing the status code was used, which would lead to
a leading space in the parsed reason string.

(cherry picked from commit e63e040f0cef2d6af2fb57aefa6250fc450fa049)
Signed-off-by: Marvin Scholz 

diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c
index 13507d1858..d601d63a89 100644
--- a/libavformat/rtsp.c
+++ b/libavformat/rtsp.c
@@ -1274,6 +1274,7 @@ start:
 if (!strncmp(buf1, "RTSP/", 5)) {
 get_word(buf1, sizeof(buf1), &p);
 reply->status_code = atoi(buf1);
+p += strspn(p, SPACE_CHARS);
 av_strlcpy(reply->reason, p, sizeof(reply->reason));
 } else {
 av_strlcpy(reply->reason, buf1, sizeof(reply->reason)); // 
method

commit 1e56c51d3b4cb17c64dd6adf646fd87bd22d6de6
Author: Marvin Scholz 
AuthorDate: Fri Aug 22 16:50:34 2025 +0200
Commit: Marvin Scholz 
CommitDate: Thu Oct 16 15:57:19 2025 +0200

avformat/rtsp: do not log invalid values

When reading fails the first time, ch would be uninitialized and
printed in the log message. Instead check for an error early and
log it properly.

(cherry picked from commit 2ed47ab72509bbee60288d245a0aebb7eb05e41a)
Signed-off-by: Marvin Scholz 

diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c
index 10355b89b8..13507d1858 100644
--- a/libavformat/rtsp.c
+++ b/libavformat/rtsp.c
@@ -1239,9 +1239,12 @@ start:
 q = buf;
 for (;;) {
 ret = ffurl_read_complete(rt->rtsp_hd, &ch, 1);
+if (ret != 1) {
+ret = (ret < 0) ? ret : AVERROR(EIO);
+av_log(s, AV_LOG_WARNING, "Failed reading RTSP data: %s\n", 
av_err2str(ret));
+return ret;
+}
 av_log(s, AV_LOG_TRACE, "ret=%d c=%02x [%c]\n", ret, ch, ch);
-if (ret != 1)
-return ret < 0 ? ret : AVERROR(EIO);
 if (ch == '\n')
 break;
 if (ch == '$' && q == buf) {

commit 45fcd5567a4402c172aa7e92ad082a686dcddb83
Author: Marvin Scholz 
AuthorDate: Thu May 22 20:14:49 2025 +0200
Commit: Marvin Scholz 
CommitDate: Thu Oct 16 15:57:19 2025 +0200

avformat/http: Handle IPv6 Zone ID in hostname

When using a literal IPv6 address as hostname, it can contain a Zone ID
especially in the case of link-local addresses. Sending this to the
server in the Host header is not useful to the server and in some cases
servers refuse such requests.

To prevent any such issues, strip the Zone ID from the address if it's
an IPv6 address. This also removes it for the Cookies lookup.

Based on a patch by: Daniel N Pettersson 

(cherry picked from commit 5cb6d2221a6d4c07453b6c301ecfcaed48402680)
Signed-off-by: Marvin Scholz 

diff --git a/libavformat/http.c b/libavformat/http.c
index 0d4077512b..49d750b512 100644
--- a/libavformat/http.c
+++ b/libavformat/http.c
@@ -24,6 +24,7 @@
 #include "config.h"
 #include "config_components.h"
 
+#include 
 #include 
 #if CONFIG_ZLIB
 #include 
@@ -214,7 +215,7 @@ static int http_open_cnx_internal(URLContext *h, 
AVDictionary **options)
 const char *path, *proxy_path, *lower_proto = "tcp", *local_path;
 char *env_http_proxy, *env_no_proxy;
 char *hashmark;
-char hostname[1024], hoststr[1024], proto[10];
+char hostname[1024], hoststr[1024], proto[10], tmp_host[1024];
 char auth[1024], proxyauth[1024] = "";
 char path1[MAX_URL_SIZE], sanitized_path[MAX_URL_SIZE + 1];
 char buf[1024], urlbuf[MAX_URL_SIZE];
@@ -224,7 +225,14 @@ static int http_open_cnx_internal(URLContext *h, 
AVDictionary **options)
 av_url_split(proto, sizeof(proto), auth, sizeof(auth),
  hostname, sizeof(hostname), &port,
  path1, sizeof(path1), s->location);
-ff_url_join(hoststr, sizeof(hoststr), NULL, NULL, hostname, port, NULL);
+
+av_strlcpy(tmp_host, hostname, sizeof(tmp_host));
+// In case of an IPv6 address, we need to strip the Zone ID,
+// if any. We do it at the first % sign, as percent encoding
+// can be used in the Zone ID itself.
+if (strchr(tmp_host, ':'))
+tmp_host[strcspn(tmp_host, "%")] = '\0';
+ff_url_join(hoststr, sizeof(hoststr), NULL, NULL, tmp_host, port, NULL);
 

[FFmpeg-cvslog] [ffmpeg] branch master updated. 6f1ab828d3 libavfilter/vf_libplacebo: add `temperature` option

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  6f1ab828d3da168d28c65c03b80ad89a61c19d06 (commit)
  from  eab3b68237bb9b76425fbd75bda4dd69327d2928 (commit)


- Log -
commit 6f1ab828d3da168d28c65c03b80ad89a61c19d06
Author: Niklas Haas 
AuthorDate: Mon Oct 6 14:06:30 2025 +0200
Commit: Niklas Haas 
CommitDate: Thu Oct 9 20:45:09 2025 +

libavfilter/vf_libplacebo: add `temperature` option

diff --git a/doc/filters.texi b/doc/filters.texi
index 262e7ad009..5863041d1a 100644
--- a/doc/filters.texi
+++ b/doc/filters.texi
@@ -16795,6 +16795,11 @@ coefficients for RGB inputs.
 @item gamma
 Gamma adjustment, between @code{0.0} and @code{16.0}. Defaults to @code{1.0}.
 
+@item temperature
+Color temperature adjustment. Lower values make the output warmer/redder,
+down to @code{1667}, while higher values make the output cooler/bluer, up to
+@code{25000}. Defaults to @code{6500} (neutral white).
+
 @item cones
 Cone model to use for color blindness simulation. Accepts any combination of
 @code{l}, @code{m} and @code{s}. Here are some examples:
diff --git a/libavfilter/vf_libplacebo.c b/libavfilter/vf_libplacebo.c
index 2b3738c8e0..2d8dd29be0 100644
--- a/libavfilter/vf_libplacebo.c
+++ b/libavfilter/vf_libplacebo.c
@@ -261,6 +261,7 @@ typedef struct LibplaceboContext {
 float saturation;
 float hue;
 float gamma;
+float temperature;
 
 /* pl_peak_detect_params */
 int peakdetect;
@@ -446,6 +447,8 @@ static int update_settings(AVFilterContext *ctx)
 .saturation = s->saturation,
 .hue = s->hue,
 .gamma = s->gamma,
+// libplacebo uses a normalized/relative scale for CCT
+.temperature = (s->temperature - 6500.0) / 3500.0,
 };
 
 opts->peak_detect_params = *pl_peak_detect_params(
@@ -1723,6 +1726,7 @@ static const AVOption libplacebo_options[] = {
 { "saturation", "Saturation gain", OFFSET(saturation), AV_OPT_TYPE_FLOAT, 
{.dbl = 1.0}, 0.0, 16.0, DYNAMIC },
 { "hue", "Hue shift", OFFSET(hue), AV_OPT_TYPE_FLOAT, {.dbl = 0.0}, -M_PI, 
M_PI, DYNAMIC },
 { "gamma", "Gamma adjustment", OFFSET(gamma), AV_OPT_TYPE_FLOAT, {.dbl = 
1.0}, 0.0, 16.0, DYNAMIC },
+{ "temperature", "Color temperature adjustment (kelvin)", 
OFFSET(temperature), AV_OPT_TYPE_FLOAT, {.dbl = 6500.0}, 1667.0, 25000.0, 
DYNAMIC },
 
 { "peak_detect", "Enable dynamic peak detection for HDR tone-mapping", 
OFFSET(peakdetect), AV_OPT_TYPE_BOOL, {.i64 = 1}, 0, 1, DYNAMIC },
 { "smoothing_period", "Peak detection smoothing period", 
OFFSET(smoothing), AV_OPT_TYPE_FLOAT, {.dbl = 100.0}, 0.0, 1000.0, DYNAMIC },

---

Summary of changes:
 doc/filters.texi| 5 +
 libavfilter/vf_libplacebo.c | 4 
 2 files changed, 9 insertions(+)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. bc561013c9 avformat/whip: add RTX initial support

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  bc561013c9a809a90c0d1b84413814ba612f7c44 (commit)
  from  f1e9032a2000b8b885cffd6fed8eacd47b37673f (commit)


- Log -
commit bc561013c9a809a90c0d1b84413814ba612f7c44
Author: Jack Lau 
AuthorDate: Thu Sep 18 09:23:31 2025 +0800
Commit: stevenliu 
CommitDate: Tue Sep 30 05:42:40 2025 +

avformat/whip: add RTX initial support

Refer to RFC 4588.

Add and set the basic param of RTX like
ssrc, payload_type, srtp.

Modify the SDP to add RTX info so that
the peer be able to parse the RTX packet.

There are more pateches to make RTX really
work.

Signed-off-by: Jack Lau 

diff --git a/libavformat/whip.c b/libavformat/whip.c
index cfdc861c5b..472c6dbf16 100644
--- a/libavformat/whip.c
+++ b/libavformat/whip.c
@@ -122,6 +122,7 @@
 /* Referring to Chrome's definition of RTP payload types. */
 #define WHIP_RTP_PAYLOAD_TYPE_H264 106
 #define WHIP_RTP_PAYLOAD_TYPE_OPUS 111
+#define WHIP_RTP_PAYLOAD_TYPE_VIDEO_RTX 105
 
 /**
  * The STUN message header, which is 20 bytes long, comprises the
@@ -229,12 +230,14 @@ typedef struct WHIPContext {
 /* The SSRC of the audio and video stream, generated by the muxer. */
 uint32_t audio_ssrc;
 uint32_t video_ssrc;
+uint32_t video_rtx_ssrc;
 
 uint16_t audio_first_seq;
 uint16_t video_first_seq;
 /* The PT(Payload Type) of stream, generated by the muxer. */
 uint8_t audio_payload_type;
 uint8_t video_payload_type;
+uint8_t video_rtx_payload_type;
 /**
  * This is the SDP offer generated by the muxer based on the codec 
parameters,
  * DTLS, and ICE information.
@@ -290,6 +293,7 @@ typedef struct WHIPContext {
 /* The SRTP send context, to encrypt outgoing packets. */
 SRTPContext srtp_audio_send;
 SRTPContext srtp_video_send;
+SRTPContext srtp_video_rtx_send;
 SRTPContext srtp_rtcp_send;
 /* The SRTP receive context, to decrypt incoming packets. */
 SRTPContext srtp_recv;
@@ -602,9 +606,11 @@ static int generate_sdp_offer(AVFormatContext *s)
 
 whip->audio_ssrc = av_lfg_get(&whip->rnd);
 whip->video_ssrc = whip->audio_ssrc + 1;
+whip->video_rtx_ssrc = whip->video_ssrc + 1;
 
 whip->audio_payload_type = WHIP_RTP_PAYLOAD_TYPE_OPUS;
 whip->video_payload_type = WHIP_RTP_PAYLOAD_TYPE_H264;
+whip->video_rtx_payload_type = WHIP_RTP_PAYLOAD_TYPE_VIDEO_RTX;
 
 av_bprintf(&bp, ""
 "v=0\r\n"
@@ -657,7 +663,7 @@ static int generate_sdp_offer(AVFormatContext *s)
 }
 
 av_bprintf(&bp, ""
-"m=video 9 UDP/TLS/RTP/SAVPF %u\r\n"
+"m=video 9 UDP/TLS/RTP/SAVPF %u %u\r\n"
 "c=IN IP4 0.0.0.0\r\n"
 "a=ice-ufrag:%s\r\n"
 "a=ice-pwd:%s\r\n"
@@ -671,9 +677,13 @@ static int generate_sdp_offer(AVFormatContext *s)
 "a=rtpmap:%u %s/9\r\n"
 "a=fmtp:%u 
level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=%02x%02x%02x\r\n"
 "a=rtcp-fb%u nack\r\n"
+"a=rtpmap:%u rtx/9\r\n"
+"a=fmtp:%u apt=%u\r\n"
+"a=ssrc-group:FID %u %u\r\n"
 "a=ssrc:%u cname:FFmpeg\r\n"
 "a=ssrc:%u msid:FFmpeg video\r\n",
 whip->video_payload_type,
+whip->video_rtx_payload_type,
 whip->ice_ufrag_local,
 whip->ice_pwd_local,
 whip->dtls_fingerprint,
@@ -684,6 +694,11 @@ static int generate_sdp_offer(AVFormatContext *s)
 profile_iop,
 level,
 whip->video_payload_type,
+whip->video_rtx_payload_type,
+whip->video_rtx_payload_type,
+whip->video_payload_type,
+whip->video_ssrc,
+whip->video_rtx_ssrc,
 whip->video_ssrc,
 whip->video_ssrc);
 }
@@ -1408,6 +1423,12 @@ static int setup_srtp(AVFormatContext *s)
 goto end;
 }
 
+ret = ff_srtp_set_crypto(&whip->srtp_video_rtx_send, suite, buf);
+if (ret < 0) {
+av_log(whip, AV_LOG_ERROR, "Failed to set crypto for video rtx 
send\n");
+goto end;
+}
+
 ret = ff_srtp_set_crypto(&whip->srtp_rtcp_send, suite, buf);
 if (ret < 0) {
 av_log(whip, AV_LOG_ERROR, "Failed to set crypto for rtcp send\n");
@@ -1924,6 +1945,7 @@ static av_cold void whip_deinit(AVFormatContext *s)
 av_freep(&whip->key_file);
 ff_srtp_free(&whip->srtp_audio_send);
 ff_srtp_free(&whip->srtp_video_send);
+ff_srtp_free(&whip->srtp_video_rtx_send);
 ff_srtp_free(&whip->srtp_rtcp_send);
 ff_srtp_free(&whip->srtp_recv);
 ffurl_close(whip->dtls_uc);

---

Summary of changes:
 libavformat/whip.c | 24 +++-
 1 file changed, 23 insertions(+), 1 deletion(-)


hooks/post-receive
-- 

__

[FFmpeg-cvslog] [ffmpeg] branch master updated. b0c77e5a12 lavc/vvc: Store RefStruct references to referenced PSs/headers in slice

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  b0c77e5a126b00a02a63359ed279d6e8e966a963 (commit)
  from  31f0749cd44dfbf9f970df412e7fac596c133dfb (commit)


- Log -
commit b0c77e5a126b00a02a63359ed279d6e8e966a963
Author: Frank Plowman 
AuthorDate: Thu Sep 18 21:24:29 2025 +0100
Commit: Frank Plowman 
CommitDate: Mon Oct 13 19:05:36 2025 +0100

lavc/vvc: Store RefStruct references to referenced PSs/headers in slice

This loosens the coupling between CBS and the decoder by no longer using
CodedBitstreamH266Context (containing the most recently parsed PSs & PH)
to retrieve the PSs & PH in the decoder. Doing so is beneficial in two
ways:
1. It improves robustness to the case in which an AVPacket doesn't
   contain precisely one PU.
2. It allows the decoder parameter set manager to properly handle the
   case in which a single PU (erroneously) contains conflicting
   parameter sets.

Signed-off-by: Frank Plowman 

diff --git a/libavcodec/cbs_h2645.c b/libavcodec/cbs_h2645.c
index 75784b03a9..f537686245 100644
--- a/libavcodec/cbs_h2645.c
+++ b/libavcodec/cbs_h2645.c
@@ -1086,6 +1086,7 @@ static int cbs_h266_read_nal_unit(CodedBitstreamContext 
*ctx,
 {
 GetBitContext gbc;
 int err;
+CodedBitstreamH266Context *h266 = ctx->priv_data;
 
 err = init_get_bits8(&gbc, unit->data, unit->data_size);
 if (err < 0)
@@ -1201,7 +1202,13 @@ static int cbs_h266_read_nal_unit(CodedBitstreamContext 
*ctx,
 err = cbs_h266_replace_ph(ctx, unit, 
&slice->header.sh_picture_header);
 if (err < 0)
 return err;
+slice->ph_ref = NULL;
+} else {
+slice->ph_ref = av_refstruct_ref(h266->ph_ref);
 }
+slice->ph = h266->ph;
+slice->pps= 
av_refstruct_ref(h266->pps[slice->ph->ph_pic_parameter_set_id]);
+slice->sps= 
av_refstruct_ref(h266->sps[slice->pps->pps_seq_parameter_set_id]);
 
 slice->header_size = pos / 8;
 slice->data_size = len - pos / 8;
@@ -2037,6 +2044,16 @@ static const CodedBitstreamUnitTypeDescriptor 
cbs_h265_unit_types[] = {
 CBS_UNIT_TYPE_END_OF_LIST
 };
 
+static void cbs_h266_free_slice(AVRefStructOpaque unused, void *content)
+{
+H266RawSlice *slice = content;
+av_buffer_unref(&slice->data_ref);
+av_refstruct_unref(&slice->sps);
+av_refstruct_unref(&slice->pps);
+av_refstruct_unref(&slice->ph_ref);
+}
+
+
 static void cbs_h266_free_sei(AVRefStructOpaque unused, void *content)
 {
 H266RawSEI *sei = content;
@@ -2065,11 +2082,12 @@ static const CodedBitstreamUnitTypeDescriptor 
cbs_h266_unit_types[] = {
 CBS_UNIT_TYPE_POD(VVC_PH_NUT , H266RawPH),
 CBS_UNIT_TYPE_POD(VVC_AUD_NUT, H266RawAUD),
 
-CBS_UNIT_RANGE_INTERNAL_REF(VVC_TRAIL_NUT, VVC_RASL_NUT,
-H266RawSlice, data),
-
-CBS_UNIT_RANGE_INTERNAL_REF(VVC_IDR_W_RADL, VVC_GDR_NUT,
-H266RawSlice, data),
+CBS_UNIT_TYPES_COMPLEX((VVC_TRAIL_NUT, VVC_STSA_NUT, VVC_RADL_NUT),
+   H266RawSlice, cbs_h266_free_slice),
+CBS_UNIT_TYPES_COMPLEX((VVC_RASL_NUT, VVC_IDR_W_RADL, VVC_IDR_N_LP),
+   H266RawSlice, cbs_h266_free_slice),
+CBS_UNIT_TYPES_COMPLEX((VVC_CRA_NUT, VVC_GDR_NUT),
+   H266RawSlice, cbs_h266_free_slice),
 
 CBS_UNIT_TYPES_COMPLEX((VVC_PREFIX_SEI_NUT, VVC_SUFFIX_SEI_NUT),
H266RawSEI, cbs_h266_free_sei),
diff --git a/libavcodec/cbs_h266.h b/libavcodec/cbs_h266.h
index 67a3ff6151..8d851a0bfb 100644
--- a/libavcodec/cbs_h266.h
+++ b/libavcodec/cbs_h266.h
@@ -848,6 +848,11 @@ typedef struct H266RawSlice {
 size_t   header_size;
 size_t   data_size;
 int  data_bit_start;
+
+H266RawSPS   *sps; ///< RefStruct reference to referred-to SPS
+H266RawPPS   *pps; ///< RefStruct reference to referred-to PPS
+H266RawPictureHeader *ph;
+void *ph_ref;  ///< RefStruct reference backing 
referred-to PH above
 } H266RawSlice;
 
 typedef struct H266RawSEI {
diff --git a/libavcodec/vvc/dec.c b/libavcodec/vvc/dec.c
index b31fceef40..bfe330e028 100644
--- a/libavcodec/vvc/dec.c
+++ b/libavcodec/vvc/dec.c
@@ -852,8 +852,6 @@ static int slice_start(SliceContext *sc, VVCContext *s, 
VVCFrameContext *fc,
 if (ret < 0)
 return ret;
 
-av_refstruct_replace(&sc->ref, unit->content_ref);
-
 if (is_first_slice) {
 ret = frame_start(s, fc, sc);
 if (ret < 0)
@@ -927,7 +925,7 @@ static int export_frame_params(VVCContext *s, const 
VVCFrameContext *fc)
 
 static int frame_setup(VVCFrameContext *fc, VVCContext *s)
 {
-int ret = ff_vvc_decode_frame_ps(&fc->ps, s);
+int ret = ff_vvc_decode_frame_ps(fc, s);
 if (ret < 0)
 return re

[FFmpeg-cvslog] [ffmpeg] branch master updated. 7896cc67c1 avcodec/exr: Check that DWA has 3 channels

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  7896cc67c13037abba8941e39a74c56d26b775a7 (commit)
   via  c911e0001115bbda904ad103b12c27b9a3c0c265 (commit)
   via  8e078826da6f2a1dffa25162121b43b272f5e5fa (commit)
  from  ef60d5ac32a71d62e09630acc73b56f09a7d5ef2 (commit)


- Log -
commit 7896cc67c13037abba8941e39a74c56d26b775a7
Author: Michael Niedermayer 
AuthorDate: Fri Sep 19 00:18:30 2025 +0200
Commit: michaelni 
CommitDate: Wed Oct 8 00:27:49 2025 +

avcodec/exr: Check that DWA has 3 channels

The implementation hardcodes access to 3 channels, so we need to check that
Fixes: out of array access
Fixes: BIGSLEEP-445394503-crash.exr

Found-by: Google Big Sleep
Signed-off-by: Michael Niedermayer 

diff --git a/libavcodec/exr.c b/libavcodec/exr.c
index 9da935b382..c83325aa52 100644
--- a/libavcodec/exr.c
+++ b/libavcodec/exr.c
@@ -1005,6 +1005,11 @@ static int dwa_uncompress(const EXRContext *s, const 
uint8_t *src, int compresse
 if (version != 2)
 return AVERROR_INVALIDDATA;
 
+if (s->nb_channels < 3) {
+avpriv_request_sample(s->avctx, "Gray DWA");
+return AVERROR_PATCHWELCOME;
+}
+
 lo_usize = AV_RL64(src + 8);
 lo_size = AV_RL64(src + 16);
 ac_size = AV_RL64(src + 24);

commit c911e0001115bbda904ad103b12c27b9a3c0c265
Author: Michael Niedermayer 
AuthorDate: Thu Sep 18 21:28:04 2025 +0200
Commit: michaelni 
CommitDate: Wed Oct 8 00:27:49 2025 +

avcodec/exr: Round dc_w/h up

Without rounding them up there are too few dc coeffs for the blocks.
We do not know if this way of handling odd dimensions is correct, as we have
no such DWA sample.
thus we ask the user for a sample if she encounters such a file

Fixes: out of array access
Fixes: BIGSLEEP-445392027-crash.exr

Found-by: Google Big Sleep
Signed-off-by: Michael Niedermayer 

diff --git a/libavcodec/exr.c b/libavcodec/exr.c
index b772f1f74a..9da935b382 100644
--- a/libavcodec/exr.c
+++ b/libavcodec/exr.c
@@ -992,8 +992,8 @@ static int dwa_uncompress(const EXRContext *s, const 
uint8_t *src, int compresse
 int64_t version, lo_usize, lo_size;
 int64_t ac_size, dc_size, rle_usize, rle_csize, rle_raw_size;
 int64_t ac_count, dc_count, ac_compression;
-const int dc_w = td->xsize >> 3;
-const int dc_h = td->ysize >> 3;
+const int dc_w = (td->xsize + 7) >> 3;
+const int dc_h = (td->ysize + 7) >> 3;
 GetByteContext gb, agb;
 int skip, ret;
 int have_rle = 0;
@@ -1031,6 +1031,10 @@ static int dwa_uncompress(const EXRContext *s, const 
uint8_t *src, int compresse
 return AVERROR_INVALIDDATA;
 }
 
+if (td->xsize % 8 || td->ysize % 8) {
+avpriv_request_sample(s->avctx, "odd dimensions DWA");
+}
+
 bytestream2_init(&gb, src + 88, compressed_size - 88);
 skip = bytestream2_get_le16(&gb);
 if (skip < 2)

commit 8e078826da6f2a1dffa25162121b43b272f5e5fa
Author: Michael Niedermayer 
AuthorDate: Thu Sep 18 17:32:46 2025 +0200
Commit: michaelni 
CommitDate: Wed Oct 8 00:27:49 2025 +

avcodec/exr: check ac_size

Fixes: out of array read
Fixes: dwa_uncompress.py.crash.exr

The code will read from the ac data even if ac_size is 0, thus that case
is not implemented and we ask for a sample and error out cleanly

Found-by: Google Big Sleep

Signed-off-by: Michael Niedermayer 

diff --git a/libavcodec/exr.c b/libavcodec/exr.c
index e6051567d1..b772f1f74a 100644
--- a/libavcodec/exr.c
+++ b/libavcodec/exr.c
@@ -1021,6 +1021,11 @@ static int dwa_uncompress(const EXRContext *s, const 
uint8_t *src, int compresse
 )
 return AVERROR_INVALIDDATA;
 
+if (ac_size <= 0) {
+avpriv_request_sample(s->avctx, "Zero ac_size");
+return AVERROR_INVALIDDATA;
+}
+
 if ((uint64_t)rle_raw_size > INT_MAX) {
 avpriv_request_sample(s->avctx, "Too big rle_raw_size");
 return AVERROR_INVALIDDATA;

---

Summary of changes:
 libavcodec/exr.c | 18 --
 1 file changed, 16 insertions(+), 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 41c168444e avcodec/hevc/sei: don't attempt to use stale values in HEVCSEITimeCode

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  41c168444e6a62aeef1e2f08378064316006e822 (commit)
   via  8e01bff774aeacdeb8cc9fb5a6fe8c958bdfa704 (commit)
   via  d448d6d1a0a4cdc76499c137742fdd8b30b9e7de (commit)
  from  a934d48440dbeca60b1ca701ce46cd7f3653021c (commit)


- Log -
commit 41c168444e6a62aeef1e2f08378064316006e822
Author: James Almer 
AuthorDate: Thu Oct 9 00:32:39 2025 -0300
Commit: James Almer 
CommitDate: Thu Oct 9 12:09:35 2025 -0300

avcodec/hevc/sei: don't attempt to use stale values in HEVCSEITimeCode

Invalidate the whole struct on SEI reset.

Signed-off-by: James Almer 

diff --git a/libavcodec/hevc/sei.h b/libavcodec/hevc/sei.h
index d6891d60a6..2fcd0e8d57 100644
--- a/libavcodec/hevc/sei.h
+++ b/libavcodec/hevc/sei.h
@@ -127,6 +127,7 @@ int ff_hevc_decode_nal_sei(GetBitContext *gb, void *logctx, 
HEVCSEI *s,
  */
 static inline void ff_hevc_reset_sei(HEVCSEI *sei)
 {
+sei->timecode.present = 0;
 sei->tdrdi.present = 0;
 ff_h2645_sei_reset(&sei->common);
 }

commit 8e01bff774aeacdeb8cc9fb5a6fe8c958bdfa704
Author: James Almer 
AuthorDate: Thu Oct 9 00:31:57 2025 -0300
Commit: James Almer 
CommitDate: Thu Oct 9 12:09:35 2025 -0300

avcodec/hevc/sei: don't attempt to use stale values in HEVCSEITDRDI

Invalidate the whole struct on SEI reset.

Signed-off-by: James Almer 

diff --git a/libavcodec/hevc/hevcdec.c b/libavcodec/hevc/hevcdec.c
index b27d1d79e8..8d432a9a1f 100644
--- a/libavcodec/hevc/hevcdec.c
+++ b/libavcodec/hevc/hevcdec.c
@@ -4106,7 +4106,7 @@ static int hevc_sei_to_context(AVCodecContext *avctx, 
HEVCSEI *sei)
 {
 int ret;
 
-if (sei->tdrdi.num_ref_displays) {
+if (sei->tdrdi.present) {
 AVBufferRef *buf;
 size_t size;
 AV3DReferenceDisplaysInfo *tdrdi = 
av_tdrdi_alloc(sei->tdrdi.num_ref_displays, &size);
diff --git a/libavcodec/hevc/sei.c b/libavcodec/hevc/sei.c
index e81dfcbff9..5fd4e763b3 100644
--- a/libavcodec/hevc/sei.c
+++ b/libavcodec/hevc/sei.c
@@ -217,6 +217,8 @@ static int 
decode_nal_sei_3d_reference_displays_info(HEVCSEITDRDI *s, GetBitCont
 }
 s->three_dimensional_reference_displays_extension_flag = get_bits1(gb);
 
+s->present = 1;
+
 return 0;
 }
 
diff --git a/libavcodec/hevc/sei.h b/libavcodec/hevc/sei.h
index c4714bb7c5..d6891d60a6 100644
--- a/libavcodec/hevc/sei.h
+++ b/libavcodec/hevc/sei.h
@@ -93,6 +93,7 @@ typedef struct HEVCSEITDRDI {
 uint8_t additional_shift_present_flag[32];
 int16_t num_sample_shift[32];
 uint8_t three_dimensional_reference_displays_extension_flag;
+int present;
 } HEVCSEITDRDI;
 
 typedef struct HEVCSEIRecoveryPoint {
@@ -126,6 +127,7 @@ int ff_hevc_decode_nal_sei(GetBitContext *gb, void *logctx, 
HEVCSEI *s,
  */
 static inline void ff_hevc_reset_sei(HEVCSEI *sei)
 {
+sei->tdrdi.present = 0;
 ff_h2645_sei_reset(&sei->common);
 }
 

commit d448d6d1a0a4cdc76499c137742fdd8b30b9e7de
Author: James Almer 
AuthorDate: Thu Oct 9 00:31:10 2025 -0300
Commit: James Almer 
CommitDate: Thu Oct 9 12:09:35 2025 -0300

avcodec/hevc/sei: prevent storing a potentially bogus num_ref_displays 
value in HEVCSEITDRDI

Fixes: 
439711052/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HEVC_fuzzer-4956250308935680
Fixes: out of array access

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: James Almer 

diff --git a/libavcodec/hevc/sei.c b/libavcodec/hevc/sei.c
index b8e98cde89..e81dfcbff9 100644
--- a/libavcodec/hevc/sei.c
+++ b/libavcodec/hevc/sei.c
@@ -167,6 +167,8 @@ static int decode_nal_sei_timecode(HEVCSEITimeCode *s, 
GetBitContext *gb)
 
 static int decode_nal_sei_3d_reference_displays_info(HEVCSEITDRDI *s, 
GetBitContext *gb)
 {
+unsigned num_ref_displays;
+
 s->prec_ref_display_width = get_ue_golomb(gb);
 if (s->prec_ref_display_width > 31)
 return AVERROR_INVALIDDATA;
@@ -176,10 +178,10 @@ static int 
decode_nal_sei_3d_reference_displays_info(HEVCSEITDRDI *s, GetBitCont
 if (s->prec_ref_viewing_dist > 31)
 return AVERROR_INVALIDDATA;
 }
-s->num_ref_displays = get_ue_golomb(gb);
-if (s->num_ref_displays > 31)
+num_ref_displays = get_ue_golomb(gb);
+if (num_ref_displays > 31)
 return AVERROR_INVALIDDATA;
-s->num_ref_displays += 1;
+s->num_ref_displays = num_ref_displays + 1;
 
 for (int i = 0; i < s->num_ref_displays; i++) {
 int length;

---

Summary of changes:
 libavcodec/hevc/hevcdec.c |  2 +-
 libavcodec/hevc/sei.c | 10 +++---
 libavcodec/hevc/sei.h |  3 +++
 3 files changed, 11 insertions(+), 4 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe 

[FFmpeg-cvslog] [ffmpeg] branch master updated. 31f0749cd4 avcodec/vp3: Optimize alignment check away when possible

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  31f0749cd44dfbf9f970df412e7fac596c133dfb (commit)
   via  5823ab347af64d7d6c4a1f223d38841bda076f77 (commit)
   via  e3ca57ae8f21da56b1fe86dd575bc17c58bc6dc9 (commit)
   via  5d9a392bce7d9ad28f3ac5caa6c0d1fafaad89d5 (commit)
  from  0bc54cddb1050c3c55bc65adbd3c8aa90d7eb457 (commit)


- Log -
commit 31f0749cd44dfbf9f970df412e7fac596c133dfb
Author: Andreas Rheinhardt 
AuthorDate: Fri Oct 10 15:49:04 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Mon Oct 13 18:59:49 2025 +0200

avcodec/vp3: Optimize alignment check away when possible

Check only on arches that need said check.

(Btw: I do not see how h_loop_filter benefits from alignment
at all and why h_loop_filter_unaligned exists.)

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/vp3.c b/libavcodec/vp3.c
index 406c4f499b..0613254c14 100644
--- a/libavcodec/vp3.c
+++ b/libavcodec/vp3.c
@@ -2031,7 +2031,7 @@ static int vp4_mc_loop_filter(Vp3DecodeContext *s, int 
plane, int motion_x, int
  plane_height);
 
 #define safe_loop_filter(name, ptr, stride, bounding_values) \
-if ((uintptr_t)(ptr) & 7) \
+if (VP3_LOOP_FILTER_NO_UNALIGNED_SUPPORT && (uintptr_t)(ptr) & 7) \
 s->vp3dsp.name##_unaligned(ptr, stride, bounding_values); \
 else \
 s->vp3dsp.name(ptr, stride, bounding_values);
diff --git a/libavcodec/vp3dsp.h b/libavcodec/vp3dsp.h
index 1d5dd4b738..7512676379 100644
--- a/libavcodec/vp3dsp.h
+++ b/libavcodec/vp3dsp.h
@@ -22,6 +22,10 @@
 #include 
 #include 
 
+// If this is one, {v,h}_loop_filter expect src to be aligned on eight bytes;
+// otherwise they don't have any alignment requirements for src.
+#define VP3_LOOP_FILTER_NO_UNALIGNED_SUPPORT (ARCH_ARM || ARCH_MIPS)
+
 typedef struct VP3DSPContext {
 /**
  * Copy 8xH pixels from source to destination buffer using a bilinear
diff --git a/tests/checkasm/vp3dsp.c b/tests/checkasm/vp3dsp.c
index 81f096dc2a..4f985ae62a 100644
--- a/tests/checkasm/vp3dsp.c
+++ b/tests/checkasm/vp3dsp.c
@@ -68,8 +68,8 @@ static void vp3_check_loop_filter(void)
 #define TEST(NAME) .name = #NAME, .offset = offsetof(VP3DSPContext, NAME)
 { TEST(v_loop_filter_unaligned), 2, 1, 0, 7, 1, 0 },
 { TEST(h_loop_filter_unaligned), 0, 7, 2, 1, 1, 1 },
-{ TEST(v_loop_filter),   2, 1, 0, 7, 8, 0 },
-{ TEST(h_loop_filter),   0, 7, 2, 1, 8, 1 },
+{ TEST(v_loop_filter),   2, 1, 0, 7, 
VP3_LOOP_FILTER_NO_UNALIGNED_SUPPORT ? 8 : 1, 0 },
+{ TEST(h_loop_filter),   0, 7, 2, 1, 
VP3_LOOP_FILTER_NO_UNALIGNED_SUPPORT ? 8 : 1, 1 },
 };
 declare_func(void, uint8_t *src, ptrdiff_t stride, int *bounding_values);
 

commit 5823ab347af64d7d6c4a1f223d38841bda076f77
Author: Andreas Rheinhardt 
AuthorDate: Thu Oct 9 18:56:37 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Mon Oct 13 18:59:24 2025 +0200

avcodec/vp3dsp: Remove unused flags parameter from ff_vp3dsp_init()

No longer necessary now that the x86 loop filter functions are
bitexact.

Reviewed-by: Sean McGovern 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/arm/vp3dsp_init_arm.c b/libavcodec/arm/vp3dsp_init_arm.c
index 65ea53fe0f..905c3dd624 100644
--- a/libavcodec/arm/vp3dsp_init_arm.c
+++ b/libavcodec/arm/vp3dsp_init_arm.c
@@ -30,7 +30,7 @@ void ff_vp3_idct_dc_add_neon(uint8_t *dest, ptrdiff_t stride, 
int16_t *data);
 void ff_vp3_v_loop_filter_neon(uint8_t *, int, int *);
 void ff_vp3_h_loop_filter_neon(uint8_t *, int, int *);
 
-av_cold void ff_vp3dsp_init_arm(VP3DSPContext *c, int flags)
+av_cold void ff_vp3dsp_init_arm(VP3DSPContext *c)
 {
 int cpu_flags = av_get_cpu_flags();
 
diff --git a/libavcodec/mips/vp3dsp_init_mips.c 
b/libavcodec/mips/vp3dsp_init_mips.c
index 4252ff790e..7388386d2b 100644
--- a/libavcodec/mips/vp3dsp_init_mips.c
+++ b/libavcodec/mips/vp3dsp_init_mips.c
@@ -26,7 +26,7 @@
 #include "libavcodec/vp3dsp.h"
 #include "vp3dsp_mips.h"
 
-av_cold void ff_vp3dsp_init_mips(VP3DSPContext *c, int flags)
+av_cold void ff_vp3dsp_init_mips(VP3DSPContext *c)
 {
 int cpu_flags = av_get_cpu_flags();
 
diff --git a/libavcodec/ppc/vp3dsp_altivec.c b/libavcodec/ppc/vp3dsp_altivec.c
index a9a48d145b..30551a1a20 100644
--- a/libavcodec/ppc/vp3dsp_altivec.c
+++ b/libavcodec/ppc/vp3dsp_altivec.c
@@ -192,7 +192,7 @@ static void vp3_idct_add_altivec(uint8_t *dst, ptrdiff_t 
stride, int16_t block[6
 
 #endif /* HAVE_ALTIVEC */
 
-av_cold void ff_vp3dsp_init_ppc(VP3DSPContext *c, int flags)
+av_cold void ff_vp3dsp_init_ppc(VP3DSPContext *c)
 {
 #if HAVE_ALTIVEC
 if (!PPC_ALTIVEC(av_get_cpu_flags()))
diff --git a/libavcodec/vp3.c b/libavcodec/vp3.c
index 549c698b77..406c4f499b 100644
--- a/libavcodec/vp3.c
+++ b/libavcodec/vp3.c
@@ -2385,7 +2385,7 @@ static av_cold int vp3_decode_init(AVCodecContext *avctx)
 avctx->chr

[FFmpeg-cvslog] [ffmpeg-web] branch master updated. 98c5740 web/security: add more CVEs

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  98c5740f14cfe8c2b7fdfe81d691e2aa0b13a4c0 (commit)
  from  39d4e357c4389c69bb22193d080dd29b998d2a9e (commit)


- Log -
commit 98c5740f14cfe8c2b7fdfe81d691e2aa0b13a4c0
Author: Michael Niedermayer 
AuthorDate: Wed Sep 24 20:05:14 2025 +0200
Commit: Michael Niedermayer 
CommitDate: Wed Sep 24 20:05:14 2025 +0200

web/security: add more CVEs

diff --git a/src/security b/src/security
index f98b7c9..ea64661 100644
--- a/src/security
+++ b/src/security
@@ -5,6 +5,9 @@
 Fixes following vulnerabilities:
 
 
+CVE-2025-59733, 0469d68acb52081ca8385b844b9650398242be0f, BIGSLEEP-436511754
+CVE-2025-59734, d311382c38df9c2237b33a9e8e860a5da7d2895d, BIGSLEEP-440183164
+CVE-2025-59734, c41a70b6bb79707e1e3a4b0e31950cd986b9f50e, BIGSLEEP-440183164
 
 
 
@@ -25,6 +28,14 @@ CVE-2025-1816,  0526535cd58444dd264e810b2f3348b4d96cff3b, 
ticket/11475,
 CVE-2025-22919, 1446e37d3d032e1452844778b3e6ba2c20f0c322, ticket/11385,
 CVE-2025-22920, 4bf784c0e5615c3f934e677d5de093a8be7da7ae, ticket/11389 never 
affected a release
 CVE-2025-25471, fd1772b7475d0d5673a5dd314ee78443d0be4cf1, ticket/11417 never 
affected a release
+CVE-2025-59728, ce0a655f85c1144d19a4acad59afbb92e4997e30, BIGSLEEP-433502298
+CVE-2025-59729, 33ae6cda71e6d34c9081a612abae00e2c7d39f72, BIGSLEEP-433513232
+CVE-2025-59730, 3ccd7d8c8e85aaae0c6d6cc88ea6cb5309d56cdc, BIGSLEEP-434637586
+CVE-2025-59731, 0d9c003d76383e82b57b6d5aa33776709d0cda2c, BIGSLEEP-436510153
+CVE-2025-59732, f45da79b2c336c5f8f3e563d72b8a22fecdcde0c, BIGSLEEP-436510316
+CVE-2025-59733, de76fb27a6e6da0431154ce9093933281a38a889 / 
0469d68acb52081ca8385b844b9650398242be0f, BIGSLEEP-436511754
+CVE-2025-59734, af310e68db0791b94753a9670c9a9ef0d717e32a / 
d311382c38df9c2237b33a9e8e860a5da7d2895d, BIGSLEEP-440183164
+CVE-2025-59734, c3747e011e7c7107ad6ef4c9e0a1c26490e2c30f / 
c41a70b6bb79707e1e3a4b0e31950cd986b9f50e, BIGSLEEP-440183164
 
 
 
@@ -36,6 +47,10 @@ Fixes following vulnerabilities:
 
 
 CVE-2025-1594,  c2184b65d214d60f2d3df86a11ca502567a3d134, ticket/11418
+CVE-2025-59728, 342ea86330ae388baf686fa220892833d55a1c3f / 
ce0a655f85c1144d19a4acad59afbb92e4997e30, BIGSLEEP-433502298,
+CVE-2025-59731, d7e188f33f638d85a1ab70943bde70359454b05c / 
0d9c003d76383e82b57b6d5aa33776709d0cda2c, BIGSLEEP-436510153,
+CVE-2025-59732, 97932677dbc29c1173f3361886022426ac74197e / 
f45da79b2c336c5f8f3e563d72b8a22fecdcde0c, BIGSLEEP-436510316,
+CVE-2025-59733, a9ec8317498b62192cc3df95ef2523eae8ec0294 / 
0469d68acb52081ca8385b844b9650398242be0f, BIGSLEEP-436511754,
 
 
 7.1.1
@@ -68,7 +83,15 @@ CVE-2024-35368, 4513300989502090c4fd6560544dce399a8cd53c 
(specific to builds wit
 Fixes following vulnerabilities:
 
 
+CVE-2023-6602,  8e95a9177eb95c260b16e154c71c35767a14ed10 / 
91d96dc8ddaebe0b6cb393f672085e6bfaf15a31
+CVE-2023-6604,  8e95a9177eb95c260b16e154c71c35767a14ed10 / 
91d96dc8ddaebe0b6cb393f672085e6bfaf15a31
+CVE-2023-6605,  7dd232e5876f5144a53389aa744c2614a5a3151d / 
4c96d6bf75357ab13808efc9f08c1b41b1bf5bdf
+CVE-2024-35368, 26737680d3f3f5b27cd0c0a7049d8330a2746172 / 
4513300989502090c4fd6560544dce399a8cd53c
+CVE-2025-0518,  1e3b60a916c3d6f7e1e0642f8bd50639c14a07c8 / 
b5b6391d64807578ab872dc58fb8aa621dcfc38a
 CVE-2025-1594,  f98f142da571653436596ccad2d09c7e39bfd4fb, ticket/11418
+CVE-2025-1816,  695dcf29c21911db19cc41722af94ece131303d8 / 
0526535cd58444dd264e810b2f3348b4d96cff3b, ticket/11475,
+CVE-2025-22919, ab650a52845bd8df25fbd4710b2c25c676461438 / 
1446e37d3d032e1452844778b3e6ba2c20f0c322, ticket/11385
+CVE-2025-59728, cc6371d48d10f90571b40eb9680ce7198c4b4532 / 
ce0a655f85c1144d19a4acad59afbb92e4997e30, BIGSLEEP-433502298
 
 
 7.0.2
@@ -116,6 +139,10 @@ CVE-2024-35367, bed04417b4d38af7a1b477b24ea6e26547e32373 / 
09e6840cf7a3ee07a73c3
 CVE-2024-35368, b43a12363c1fef0efa7eac15b6b830417656db15 / 
4513300989502090c4fd6560544dce399a8cd53c
 CVE-2025-0518,  43f64690ad9df72976bcbd6ea9e41b2542db2464 / 
b5b6391d64807578ab872dc58fb8aa621dcfc38a
 CVE-2025-22919, e2b20632b8c71a4e174511f8ff6e8342e0c63bd3 / 
1446e37d3d032e1452844778b3e6ba2c20f0c322, ticket/11385
+CVE-2025-59728, 01c3093510a5b69d3c7ac3a976eb6a58c2510cfd / 
ce0a655f85c1144d19a4acad59afbb92e4997e30, BIGSLEEP-433502298
+CVE-2025-59731, be682029ae18b80fa9b27f0715ca77323409379c / 
0d9c003d76383e82b57b6d5aa33776709d0cda2c, BIGSLEEP-436510153
+CVE-2025-59732, fa543b33f63478090137d124c20ff97f76251254 / 
f45da79b2c336c5f8f3e563d72b8a22fecdcde0c, BIGSLEEP-436510316
+CVE-2025-59733, a2e8dc01c0a50d2ec8c85d836bda8eaef6891e50 / 
0469d68acb52081ca8385b844b9650398242be0f, BIGSLEEP-436511754
 
 
 6.1.2
@@ -179,6 +206,10 @@ CVE-2024-35367, 1a874e645d4a0adef9b494482fc67d12d35395cd / 
09e6840cf7a3ee07a73c3
 CVE-2024-35368, d45964ac04a83f02cb6ddc63af6d0b646c7d9082 / 
4513300989502090c4fd6560544dce399a8cd53c
 CVE-2025-0518,  edfcade702b41de4417e2597ba2aff6ecbdead0e / 
b5b6391d64807578ab872dc58fb8aa621dcfc38a
 CVE-2025-22919, a01eaecf6325cefab5b26e0d905df6662db37be1 

[FFmpeg-cvslog] [ffmpeg] branch master updated. cd4b01707d Revert "avformat/movenc: sidx earliest_presentation_time is applied after editlist"

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  cd4b01707dd8275fb6f77e9a4d5ddd6fb02eaeef (commit)
   via  0de3b1f3588e1fc9e292098902ac79d8dd9792bc (commit)
  from  2e1d702cfc5c530c213361e6a1b77dca847a30e7 (commit)


- Log -
commit cd4b01707dd8275fb6f77e9a4d5ddd6fb02eaeef
Author: Zhao Zhili 
AuthorDate: Sun Sep 28 17:35:41 2025 +0800
Commit: Zhao Zhili 
CommitDate: Thu Oct 16 11:22:37 2025 +0800

Revert "avformat/movenc: sidx earliest_presentation_time is applied after 
editlist"

This reverts commit 301141b57636c4430e7440e8ff4956daf9cb0fb3.

cluster[0].dts, pts and frag_info[0].time are already in presentation
timeline, so they shouldn't be shift by start_pts.

Signed-off-by: Zhao Zhili 

diff --git a/libavformat/movenc.c b/libavformat/movenc.c
index 067d38b14b..b76d56dac4 100644
--- a/libavformat/movenc.c
+++ b/libavformat/movenc.c
@@ -5690,8 +5690,7 @@ static int mov_write_sidx_tag(AVIOContext *pb,
 
 if (track->entry) {
 entries = 1;
-presentation_time = track->cluster[0].dts + track->cluster[0].cts -
-track->start_dts - track->start_cts;
+presentation_time = track->cluster[0].dts + track->cluster[0].cts;
 duration = track->end_pts -
(track->cluster[0].dts + track->cluster[0].cts);
 starts_with_SAP = track->cluster[0].flags & MOV_SYNC_SAMPLE;
@@ -5706,9 +5705,6 @@ static int mov_write_sidx_tag(AVIOContext *pb,
 if (entries <= 0)
 return 0;
 presentation_time = track->frag_info[0].time;
-/* presentation_time <= 0 is handled by mov_add_tfra_entries() */
-if (presentation_time > 0)
-presentation_time -= track->start_dts + track->start_cts;
 }
 
 avio_wb32(pb, 0); /* size */
diff --git a/tests/ref/fate/movenc b/tests/ref/fate/movenc
index 5c12aeb29f..f2b95ea957 100644
--- a/tests/ref/fate/movenc
+++ b/tests/ref/fate/movenc
@@ -101,28 +101,28 @@ write_data len 1223, time nopts, type header atom ftyp
 041ac8efc35a0d023c26d05eedb20403 1223 delay-moov-elst-signal-init
 write_data len 1004, time -3, type sync atom sidx
 write_data len 996, time 97, type sync atom sidx
-69c9025ffb10302c7b5c2ed9fde86c44 996 delay-moov-elst-signal-second-frag
+5a583d89318827d2569eecbeaa18c238 996 delay-moov-elst-signal-second-frag
 write_data len 148, time nopts, type trailer atom -
 write_data len 1223, time nopts, type header atom ftyp
 041ac8efc35a0d023c26d05eedb20403 1223 delay-moov-elst-signal-init-discont
 write_data len 996, time 97, type sync atom sidx
-69c9025ffb10302c7b5c2ed9fde86c44 996 delay-moov-elst-signal-second-frag-discont
+5a583d89318827d2569eecbeaa18c238 996 delay-moov-elst-signal-second-frag-discont
 write_data len 110, time nopts, type trailer atom -
 write_data len 1247, time nopts, type header atom ftyp
 80511a51d1ac9cde62337eed7176ae03 1247 
delay-moov-elst-signal-init-discont-largets
 write_data len 996, time 27962123, type sync atom sidx
-471fc64644a6bf4065c489fe4e04be7d 996 
delay-moov-elst-signal-second-frag-discont-largets
+dc695d65e8a0cdafee28acd8a5ccf81a 996 
delay-moov-elst-signal-second-frag-discont-largets
 write_data len 110, time nopts, type trailer atom -
 write_data len 1223, time nopts, type header atom ftyp
 write_data len 2572, time -33, type sync atom sidx
 write_data len 996, time 517, type sync atom sidx
 write_data len 148, time nopts, type trailer atom -
-5c873f6e37d5af09e3c6329cf94cd6ca 4939 vfr
+d37a7eda807912b9ed05ccfe003a9e4f 4939 vfr
 write_data len 1223, time nopts, type header atom ftyp
 write_data len 2572, time -33, type sync atom sidx
 write_data len 996, time 517, type sync atom sidx
 write_data len 148, time nopts, type trailer atom -
-5c873f6e37d5af09e3c6329cf94cd6ca 4939 vfr-noduration
+d37a7eda807912b9ed05ccfe003a9e4f 4939 vfr-noduration
 write_data len 1231, time nopts, type header atom ftyp
 write_data len 1500, time -33, type sync atom moof
 write_data len 1500, time nopts, type unknown atom -

commit 0de3b1f3588e1fc9e292098902ac79d8dd9792bc
Author: Zhao Zhili 
AuthorDate: Sun Sep 28 17:23:05 2025 +0800
Commit: Zhao Zhili 
CommitDate: Thu Oct 16 11:22:37 2025 +0800

avformat/mov: don't shift sidx_pts

sidx_pts is already in presentation time, so it shouldn't be shift
by sc->time_offset again.

Signed-off-by: Zhao Zhili 

diff --git a/libavformat/mov.c b/libavformat/mov.c
index 922e001e5e..a962594990 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -5845,7 +5845,7 @@ static int mov_read_trun(MOVContext *c, AVIOContext *pb, 
MOVAtom atom)
 } else if (has_sidx && !c->use_tfdt || fallback_sidx) {
 // FIXME: sidx earliest_presentation_time is *PTS*, s.b.
 // pts = frag_stream_info->sidx_pts;
-dts = frag_stream_info->sidx_pts - sc->time_offset;
+dts = frag_strea

[FFmpeg-cvslog] [ffmpeg] branch release/7.1 updated. 8f77695e65 avcodec/svq1enc: restrict Altivec acceleration to big-endian POWER configurations

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, release/7.1 has been updated
   via  8f77695e65a69c8009804e9d457762d2d394403d (commit)
  from  8320e6b4155d4488e3ed2665a05d2b2f389fa20d (commit)


- Log -
commit 8f77695e65a69c8009804e9d457762d2d394403d
Author: Sean McGovern 
AuthorDate: Thu Jan 16 16:30:52 2025 -0500
Commit: brad 
CommitDate: Fri Sep 26 12:49:26 2025 +

avcodec/svq1enc: restrict Altivec acceleration to big-endian POWER 
configurations

This was disabled in da60b99a8857d5ca236f32c1799a066e0135a866 and then
accidentally re-enabled in 172b0e2e88832822632841e8e0d3794f974cbc93.

The code in question was never properly adapted for litte-endian mode.

refs: trac/10955
Signed-off-by: Michael Niedermayer 
(cherry picked from commit 4322be512b2bd6c7d8ee61a2b0230546f3107be0)

diff --git a/libavcodec/ppc/svq1enc_altivec.c b/libavcodec/ppc/svq1enc_altivec.c
index 5721bede34..78c79a68dc 100644
--- a/libavcodec/ppc/svq1enc_altivec.c
+++ b/libavcodec/ppc/svq1enc_altivec.c
@@ -29,7 +29,7 @@
 
 #include "libavcodec/svq1encdsp.h"
 
-#if HAVE_ALTIVEC
+#if HAVE_ALTIVEC && HAVE_BIGENDIAN
 static int ssd_int8_vs_int16_altivec(const int8_t *pix1, const int16_t *pix2,
  intptr_t size)
 {
@@ -69,14 +69,14 @@ static int ssd_int8_vs_int16_altivec(const int8_t *pix1, 
const int16_t *pix2,
 
 return u.score[3];
 }
-#endif /* HAVE_ALTIVEC */
+#endif /* HAVE_ALTIVEC && HAVE_BIGENDIAN */
 
 av_cold void ff_svq1enc_init_ppc(SVQ1EncDSPContext *c)
 {
-#if HAVE_ALTIVEC
+#if HAVE_ALTIVEC && HAVE_BIGENDIAN
 if (!PPC_ALTIVEC(av_get_cpu_flags()))
 return;
 
 c->ssd_int8_vs_int16 = ssd_int8_vs_int16_altivec;
-#endif /* HAVE_ALTIVEC */
+#endif /* HAVE_ALTIVEC && HAVE_BIGENDIAN */
 }

---

Summary of changes:
 libavcodec/ppc/svq1enc_altivec.c | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. fd136a4d82 ffv1enc_vulkan: fix empty struct build error on msvc

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  fd136a4d826d9eb2509dbb8d2869575ff8e74434 (commit)
  from  bc561013c9a809a90c0d1b84413814ba612f7c44 (commit)


- Log -
commit fd136a4d826d9eb2509dbb8d2869575ff8e74434
Author: Koushik Dutta via ffmpeg-devel 
AuthorDate: Mon Sep 29 11:44:49 2025 -0700
Commit: Lynne 
CommitDate: Tue Sep 30 19:36:56 2025 +0900

ffv1enc_vulkan: fix empty struct build error on msvc

Signed-off-by: Koushik Dutta 

diff --git a/libavcodec/ffv1enc_vulkan.c b/libavcodec/ffv1enc_vulkan.c
index 259bc75d4c..a54180a98b 100644
--- a/libavcodec/ffv1enc_vulkan.c
+++ b/libavcodec/ffv1enc_vulkan.c
@@ -1367,6 +1367,7 @@ static int init_encode_shader(AVCodecContext *avctx, 
FFVkSPIRVCompiler *spv)
 .buf_content = "uint64_t slice_results[2048];",
 },
 { /* place holder for desc_set[3] */
+.name   = "placeholder",
 },
 };
 if (fv->is_rgb) {

---

Summary of changes:
 libavcodec/ffv1enc_vulkan.c | 1 +
 1 file changed, 1 insertion(+)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 9970dc32bf avfilter/af_whisper: fix srt index

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  9970dc32bf85628e53ed0952d87d384080d8976e (commit)
  from  96065d12612180a57fceee58256de47077f6ec9a (commit)


- Log -
commit 9970dc32bf85628e53ed0952d87d384080d8976e
Author: Vittorio Palmisano 
AuthorDate: Sun Sep 21 15:33:17 2025 +0200
Commit: Zhao Zhili 
CommitDate: Thu Sep 25 11:34:10 2025 +

avfilter/af_whisper: fix srt index

The srt index should be incremented for each segment.

diff --git a/libavfilter/af_whisper.c b/libavfilter/af_whisper.c
index 90b2fc89a0..3c0eba42f0 100644
--- a/libavfilter/af_whisper.c
+++ b/libavfilter/af_whisper.c
@@ -251,6 +251,8 @@ static void run_transcription(AVFilterContext *ctx, AVFrame 
*frame, int samples)
  (start_t / 6) % 60, (start_t / 1000) % 60,
  start_t % 1000, end_t / 360, (end_t / 6) % 60,
  (end_t / 1000) % 60, end_t % 1000, text_cleaned);
+
+wctx->index++;
 } else if (!av_strcasecmp(wctx->format, "json")) {
 buf = av_asprintf("{\"start\":%" PRId64 ",\"end\":%" PRId64 
",\"text\":\"%s\"}\n", start_t, end_t, text_cleaned);
 } else
@@ -265,8 +267,6 @@ static void run_transcription(AVFilterContext *ctx, AVFrame 
*frame, int samples)
 av_freep(&text_cleaned);
 }
 
-wctx->index++;
-
 AVDictionary **metadata = &frame->metadata;
 if (metadata && segments_text) {
 av_dict_set(metadata, "lavfi.whisper.text", segments_text, 0);

---

Summary of changes:
 libavfilter/af_whisper.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 36896af64a movenc: Make the hybrid_fragmented mode more robust

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  36896af64a9ecf6835758186e7161a2e954c364d (commit)
  from  a45d30a67579f00926525ffd23c7a6b5470d77a0 (commit)


- Log -
commit 36896af64a9ecf6835758186e7161a2e954c364d
Author: Martin Storsjö 
AuthorDate: Fri Jun 27 15:11:13 2025 +0300
Commit: Martin Storsjö 
CommitDate: Thu Oct 16 18:58:54 2025 +

movenc: Make the hybrid_fragmented mode more robust

Write the moov tag at the end first, before overwriting the mdat size
at the start of the file.

In case writing the final moov box fails (e.g. due to being out
of disk), we haven't broken the initial moov box yet.

Thus if writing stops between these steps, we could end up with
a file with two moov boxes - which arguably is more feasible to
recover from, than from a file with no moov boxes at all.

diff --git a/libavformat/movenc.c b/libavformat/movenc.c
index b76d56dac4..cd66a39518 100644
--- a/libavformat/movenc.c
+++ b/libavformat/movenc.c
@@ -8546,6 +8546,28 @@ static int shift_data(AVFormatContext *s)
 return ff_format_shift_data(s, mov->reserved_header_pos, moov_size);
 }
 
+static void mov_write_mdat_size(AVFormatContext *s)
+{
+MOVMuxContext *mov = s->priv_data;
+AVIOContext *pb = s->pb;
+
+/* Write size of mdat tag */
+if (mov->mdat_size + 8 <= UINT32_MAX) {
+avio_seek(pb, mov->mdat_pos, SEEK_SET);
+avio_wb32(pb, mov->mdat_size + 8);
+if (mov->flags & FF_MOV_FLAG_HYBRID_FRAGMENTED)
+ffio_wfourcc(pb, "mdat"); // overwrite the original moov into a 
mdat
+} else {
+/* overwrite 'wide' placeholder atom */
+avio_seek(pb, mov->mdat_pos - 8, SEEK_SET);
+/* special value: real atom size will be 64 bit value after
+ * tag field */
+avio_wb32(pb, 1);
+ffio_wfourcc(pb, "mdat");
+avio_wb64(pb, mov->mdat_size + 16);
+}
+}
+
 static int mov_write_trailer(AVFormatContext *s)
 {
 MOVMuxContext *mov = s->priv_data;
@@ -8605,21 +8627,9 @@ static int mov_write_trailer(AVFormatContext *s)
 
 moov_pos = avio_tell(pb);
 
-/* Write size of mdat tag */
-if (mov->mdat_size + 8 <= UINT32_MAX) {
-avio_seek(pb, mov->mdat_pos, SEEK_SET);
-avio_wb32(pb, mov->mdat_size + 8);
-if (mov->flags & FF_MOV_FLAG_HYBRID_FRAGMENTED)
-ffio_wfourcc(pb, "mdat"); // overwrite the original moov into 
a mdat
-} else {
-/* overwrite 'wide' placeholder atom */
-avio_seek(pb, mov->mdat_pos - 8, SEEK_SET);
-/* special value: real atom size will be 64 bit value after
- * tag field */
-avio_wb32(pb, 1);
-ffio_wfourcc(pb, "mdat");
-avio_wb64(pb, mov->mdat_size + 16);
-}
+if (!(mov->flags & FF_MOV_FLAG_HYBRID_FRAGMENTED))
+mov_write_mdat_size(s);
+
 avio_seek(pb, mov->reserved_moov_size > 0 ? mov->reserved_header_pos : 
moov_pos, SEEK_SET);
 
 if (mov->flags & FF_MOV_FLAG_FASTSTART) {
@@ -8647,6 +8657,15 @@ static int mov_write_trailer(AVFormatContext *s)
 if ((res = mov_write_moov_tag(pb, mov, s)) < 0)
 return res;
 }
+
+if (mov->flags & FF_MOV_FLAG_HYBRID_FRAGMENTED) {
+// With hybrid fragmentation, only write the mdat size (hiding
+// the original moov and all the fragments within the mdat)
+// after we've successfully written the complete moov, to avoid
+// risk for an unreadable file if writing the final moov fails.
+mov_write_mdat_size(s);
+}
+
 res = 0;
 } else {
 mov_auto_flush_fragment(s, 1);

---

Summary of changes:
 libavformat/movenc.c | 49 ++---
 1 file changed, 34 insertions(+), 15 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 62d43ba2e3 libavfilter/vf_nlmeans_vulkan: fix str defaults

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  62d43ba2e3c5832cd70c2e852e0e416c7c74fb02 (commit)
   via  e8213f766f7dfadb258081b2fc8a6a6207e6cd02 (commit)
   via  7d65ce776311a75fc0f370143de04a70fa6eff71 (commit)
   via  26dee5b43ee4831263e37eaea9e51a9ec8f3a34c (commit)
   via  71ff349cc1a01484e638dd682dfe3a6aafeacd51 (commit)
   via  2e12b3251d555e809b2cb3a61dc9a2e4adc44b80 (commit)
   via  3fac2d85933c75b936884d6b7d3e14354ed65244 (commit)
  from  36896af64a9ecf6835758186e7161a2e954c364d (commit)


- Log -
commit 62d43ba2e3c5832cd70c2e852e0e416c7c74fb02
Author: Michael Yang 
AuthorDate: Fri Oct 17 08:00:13 2025 +1100
Commit: Lynne 
CommitDate: Thu Oct 16 21:32:43 2025 +

libavfilter/vf_nlmeans_vulkan: fix str defaults

Revert back to NAN as -1.0 was erroneously to 0.0 to fit in the options
range.

Add special handling of str per requested.

diff --git a/libavfilter/vf_nlmeans_vulkan.c b/libavfilter/vf_nlmeans_vulkan.c
index 3803c493b8..b69e8ac0a2 100644
--- a/libavfilter/vf_nlmeans_vulkan.c
+++ b/libavfilter/vf_nlmeans_vulkan.c
@@ -34,9 +34,6 @@
 #define TYPE_BLOCK_SIZE (TYPE_SIZE * TYPE_BLOCK_ELEMS)
 #define WG_SIZE 32
 
-// prevent macro expansion in GLSL
-#undef isinf
-
 typedef struct NLMeansVulkanContext {
 FFVulkanContext vkctx;
 
@@ -160,7 +157,7 @@ static av_cold int init_integral_pipeline(FFVulkanContext 
*vkctx, FFVkExecPool *
 GLSLC(1, uint comp_idx = uint(gl_WorkGroupID.y);   
  );
 GLSLC(1, uint invoc_idx = uint(gl_WorkGroupID.z);  
  );
 GLSLC(0,   
  );
-GLSLC(1, if (isinf(strength[comp_idx]))
  );
+GLSLC(1, if (strength[comp_idx] == 0.0)
  );
 GLSLC(2, return;   
  );
 GLSLC(0,   
  );
 GLSLC(1, offset = integral_size * (invoc_idx * nb_components + 
comp_idx); );
@@ -245,7 +242,7 @@ static av_cold int init_integral_pipeline(FFVulkanContext 
*vkctx, FFVkExecPool *
 GLSLC(1, uint comp_idx = uint(gl_WorkGroupID.y);   
  );
 GLSLC(1, uint invoc_idx = uint(gl_WorkGroupID.z);  
  );
 GLSLC(0,   
  );
-GLSLC(1, if (isinf(strength[comp_idx]))
  );
+GLSLC(1, if (strength[comp_idx] == 0.0)
  );
 GLSLC(2, return;   
  );
 GLSLC(0,   
  );
 GLSLC(1, offset = integral_size * (invoc_idx * nb_components + 
comp_idx); );
@@ -417,7 +414,7 @@ static av_cold int init_weights_pipeline(FFVulkanContext 
*vkctx, FFVkExecPool *e
 GLSLC(1, c_plane = comp_plane[comp_idx];   
  );
 GLSLC(1, p = patch_size[comp_idx]; 
  );
 GLSLC(1, s = strength[comp_idx];   
  );
-GLSLC(1, if (isinf(s) || pos.x < p || pos.y < p || pos.x >= 
width[c_plane] - p || pos.y >= height[c_plane] - p) );
+GLSLC(1, if (s == 0.0 || pos.x < p || pos.y < p || pos.x >= 
width[c_plane] - p || pos.y >= height[c_plane] - p) );
 GLSLC(2, return;   
  );
 GLSLC(0,   
  );
 GLSLC(1, offset = integral_size * (invoc_idx * nb_components + 
comp_idx); );
@@ -635,12 +632,16 @@ static av_cold int init_filter(AVFilterContext *ctx)
 }
 
 for (int i = 0; i < 4; i++) {
-double str = s->opts.sc[i] != -1.0 ? s->opts.sc[i] : s->opts.s;
+double str = !isnan(s->opts.sc[i]) ? s->opts.sc[i] : s->opts.s;
 int ps = (s->opts.pc[i] ? s->opts.pc[i] : s->opts.p);
-str  = 10.0f*str;
-str *= -str;
-str  = 255.0*255.0 / str;
-s->strength[i] = str;
+if (str == 0.0) {
+s->strength[i] = 0.0;
+} else {
+str  = 10.0f*str;
+str *= -str;
+str  = 255.0*255.0 / str;
+s->strength[i] = str;
+}
 if (!(ps & 1)) {
 ps |= 1;
 av_log(ctx, AV_LOG_WARNING, "Patch size should be odd, setting to 
%i",
@@ -1178,10 +1179,10 @@ static const AVOption nlmeans_vulkan_options[] = {
 { "r",  "research window size", OFFSET(opts.r), AV_OPT_TYPE_INT, { .i64 = 
7*2+1 }, 0, 99, FLAGS },
 { "t",  "parallelism", OFFSET(opts.t), AV_OPT_TYPE_INT, { .i64 = 8 }, 1, 
64, FLAGS },
 
-{ "s1", "denoising strength for component 1", OFFSET(opts.sc[0]), 
AV_OPT_TYPE_D

[FFmpeg-cvslog] [ffmpeg] branch master updated. 0bc54cddb1 fftools/opt_common: add long-form license option

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  0bc54cddb1050c3c55bc65adbd3c8aa90d7eb457 (commit)
  from  10e9672a8caca79f0e2f097513d22128787f9ad2 (commit)


- Log -
commit 0bc54cddb1050c3c55bc65adbd3c8aa90d7eb457
Author: zhanghongyuan 
AuthorDate: Fri Oct 10 13:57:24 2025 +0800
Commit: Zhao Zhili 
CommitDate: Sun Oct 12 03:26:21 2025 +

fftools/opt_common: add long-form license option

Add "license" as a long-form command line option alongside the existing
"L" short option for showing license information. This maintains
consistent option naming patterns with other commands that provide both
short and long forms (help/?/help, etc.) and improves command line
usability by providing more descriptive option names.

diff --git a/doc/fftools-common-opts.texi b/doc/fftools-common-opts.texi
index f6d452c40e..7b5a11b634 100644
--- a/doc/fftools-common-opts.texi
+++ b/doc/fftools-common-opts.texi
@@ -98,7 +98,7 @@ These options are shared amongst the ff* tools.
 
 @table @option
 
-@item -L
+@item -L, -license
 Show license.
 
 @item -h, -?, -help, --help [@var{arg}]
diff --git a/fftools/opt_common.h b/fftools/opt_common.h
index 9bb5268472..2a891cdd89 100644
--- a/fftools/opt_common.h
+++ b/fftools/opt_common.h
@@ -198,6 +198,7 @@ int opt_cpucount(void *optctx, const char *opt, const char 
*arg);
 
 #define CMDUTILS_COMMON_OPTIONS
 \
 { "L",OPT_TYPE_FUNC, OPT_EXIT,  { .func_arg = 
show_license }, "show license" },  \
+{ "license",  OPT_TYPE_FUNC, OPT_EXIT,  { .func_arg = 
show_license }, "show license" },  \
 { "h",OPT_TYPE_FUNC, OPT_EXIT,  { .func_arg = 
show_help },"show help", "topic" },\
 { "?",OPT_TYPE_FUNC, OPT_EXIT | OPT_EXPERT, { .func_arg = 
show_help },"show help", "topic" },\
 { "help", OPT_TYPE_FUNC, OPT_EXIT | OPT_EXPERT, { .func_arg = 
show_help },"show help", "topic" },\

---

Summary of changes:
 doc/fftools-common-opts.texi | 2 +-
 fftools/opt_common.h | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. cdae5c3639 libavutil/arm: Make use of elf_aux_info() on FreeBSD/OpenBSD

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  cdae5c3639f4adcd289e643a203d43d4e01d87f5 (commit)
  from  c9168717bf4c7d6f72d5cb02064ce832f4af9c89 (commit)


- Log -
commit cdae5c3639f4adcd289e643a203d43d4e01d87f5
Author: Brad Smith 
AuthorDate: Sat Sep 20 23:06:08 2025 -0400
Commit: Brad Smith 
CommitDate: Mon Sep 22 07:16:24 2025 -0400

libavutil/arm: Make use of elf_aux_info() on FreeBSD/OpenBSD

- FreBSD/OpenBSD have elf_aux_info() on arm
- Wrap AT_HWCAP as the value is different for BSD vs Linux (16 vs 25)

Signed-off-by: Brad Smith 

diff --git a/libavutil/arm/cpu.c b/libavutil/arm/cpu.c
index b84882005a..8ec28143d7 100644
--- a/libavutil/arm/cpu.c
+++ b/libavutil/arm/cpu.c
@@ -31,18 +31,20 @@
  CORE_FLAG(VFPV3)   |   \
  CORE_FLAG(NEON))
 
-#if defined __linux__ || defined __ANDROID__
+#if defined __linux__ || defined __ANDROID__ || HAVE_ELF_AUX_INFO
 
 #include 
 #include 
 #include 
 #include "libavutil/avstring.h"
 
-#if HAVE_GETAUXVAL
+#if HAVE_GETAUXVAL || HAVE_ELF_AUX_INFO
 #include 
 #endif
 
+#ifndef AT_HWCAP
 #define AT_HWCAP16
+#endif
 
 /* Relevant HWCAP values from kernel headers */
 #define HWCAP_VFP   (1 << 6)
@@ -54,7 +56,7 @@
 
 static int get_auxval(uint32_t *hwcap)
 {
-#if HAVE_GETAUXVAL
+#if HAVE_GETAUXVAL || HAVE_ELF_AUX_INFO
 unsigned long ret = ff_getauxval(AT_HWCAP);
 if (ret == 0)
 return -1;
@@ -65,6 +67,7 @@ static int get_auxval(uint32_t *hwcap)
 #endif
 }
 
+#if defined __linux__ || defined __ANDROID__
 static int get_hwcap(uint32_t *hwcap)
 {
 struct { uint32_t a_type; uint32_t a_val; } auxv;
@@ -117,6 +120,7 @@ static int get_cpuinfo(uint32_t *hwcap)
 fclose(f);
 return 0;
 }
+#endif
 
 int ff_get_cpu_flags_arm(void)
 {
@@ -124,8 +128,10 @@ int ff_get_cpu_flags_arm(void)
 uint32_t hwcap;
 
 if (get_auxval(&hwcap) < 0)
+#if defined __linux__ || defined __ANDROID__
 if (get_hwcap(&hwcap) < 0)
 if (get_cpuinfo(&hwcap) < 0)
+#endif
 return flags;
 
 #define check_cap(cap, flag) do {   \

---

Summary of changes:
 libavutil/arm/cpu.c | 12 +---
 1 file changed, 9 insertions(+), 3 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 36f92206bb avcodec/x86/hpeldsp: Improve ff_{avg,put}_pixels8_xy2_ssse3()

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  36f92206bb90d6f0268749bd6fe6aa57974442db (commit)
   via  4c55724da86ddc5ef10966f287a3d50fe1a1cbbe (commit)
   via  f84e06026ac4546fcc5242813de506f997d2b6fa (commit)
  from  ce9d1814449d6ff6323dd1030fb4c8d1093c6744 (commit)


- Log -
commit 36f92206bb90d6f0268749bd6fe6aa57974442db
Author: Andreas Rheinhardt 
AuthorDate: Fri Oct 3 09:29:24 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Sun Oct 12 02:45:37 2025 +0200

avcodec/x86/hpeldsp: Improve ff_{avg,put}_pixels8_xy2_ssse3()

This SSSE3 function uses MMX registers (of course without emms
at the end) and processes eight bytes of input by unpacking
it into two MMX registers. This is very suboptimal given
that one can just use XMM registers to process eight words.
This commit switches them to using XMM registers.

Old benchmarks:
avg_pixels_tab[1][3]_c:114.5 ( 1.00x)
avg_pixels_tab[1][3]_ssse3: 43.6 ( 2.62x)
put_pixels_tab[1][3]_c: 83.6 ( 1.00x)
put_pixels_tab[1][3]_ssse3: 34.0 ( 2.46x)

New benchmarks:
avg_pixels_tab[1][3]_c:115.3 ( 1.00x)
avg_pixels_tab[1][3]_ssse3: 24.6 ( 4.69x)
put_pixels_tab[1][3]_c: 83.8 ( 1.00x)
put_pixels_tab[1][3]_ssse3: 19.7 ( 4.24x)

Reviewed-by: Kieran Kunhya 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/x86/hpeldsp.asm b/libavcodec/x86/hpeldsp.asm
index fc51d72d17..2587e3c315 100644
--- a/libavcodec/x86/hpeldsp.asm
+++ b/libavcodec/x86/hpeldsp.asm
@@ -32,7 +32,6 @@ cextern pb_1
 cextern pw_1
 cextern pw_2
 pb_interleave16: db 0, 8, 1, 9, 2, 10, 3, 11, 4, 12, 5, 13, 6, 14, 7, 15
-pb_interleave8:  db 0, 4, 1, 5, 2, 6, 3, 7
 
 cextern pw_8192
 
@@ -423,9 +422,14 @@ cglobal %1%3_pixels8_xy2, 4,5,5
 movhm1, [r1+r4+1]
 punpcklbw   m0, m1
 pmaddubsw   m0, m4
+%ifidn %3, _no_rnd
 paddusw m2, m3
 paddusw m2, m0
 psrlw   m2, 2
+%else
+paddusw m2, m0
+pmulhrswm2, [pw_8192]
+%endif
 %ifidn %1, avg
 movhm1, [r0+r4]
 packuswbm2, m2
@@ -440,9 +444,14 @@ cglobal %1%3_pixels8_xy2, 4,5,5
 movhm2, [r1+r4+1]
 punpcklbw   m2, m1
 pmaddubsw   m2, m4
+%ifidn %3, _no_rnd
 paddusw m0, m3
 paddusw m0, m2
 psrlw   m0, 2
+%else
+paddusw m0, m2
+pmulhrswm0, [pw_8192]
+%endif
 %ifidn %1, avg
 movhm1, [r0+r4]
 packuswbm0, m0
@@ -459,6 +468,8 @@ cglobal %1%3_pixels8_xy2, 4,5,5
 
 INIT_XMM ssse3
 SET_PIXELS8_XY2 put, pw_1, _no_rnd
+SET_PIXELS8_XY2 avg, pw_8192
+SET_PIXELS8_XY2 put, pw_8192
 
 
 ; void ff_avg_pixels16_xy2(uint8_t *block, const uint8_t *pixels, ptrdiff_t 
line_size, int h)
@@ -542,13 +553,8 @@ SET_PIXELS_XY2 put, pw_1, _no_rnd
 SET_PIXELS_XY2 avg, pw_1, _no_rnd
 
 %macro SSSE3_PIXELS_XY2 1-2
-%if %0 == 2 ; sse2
 cglobal %1_pixels16_xy2, 4,5,%2
 movam4, [pb_interleave16]
-%else
-cglobal %1_pixels8_xy2, 4,5
-movam4, [pb_interleave8]
-%endif
 movam5, [pb_1]
 movum0, [r1]
 movum1, [r1+1]
@@ -601,9 +607,6 @@ cglobal %1_pixels8_xy2, 4,5
 RET
 %endmacro
 
-INIT_MMX ssse3
-SSSE3_PIXELS_XY2 put
-SSSE3_PIXELS_XY2 avg
 INIT_XMM ssse3
 SSSE3_PIXELS_XY2 put, 6
 SSSE3_PIXELS_XY2 avg, 7

commit 4c55724da86ddc5ef10966f287a3d50fe1a1cbbe
Author: Andreas Rheinhardt 
AuthorDate: Fri Oct 3 05:20:32 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Sun Oct 12 02:45:25 2025 +0200

avcodec/x86/hpeldsp: Add ff_put_no_rnd_pixels8_xy2_ssse3()

Given that one has to deal with 16 byte intermediates it is
unsurprising that SSE2 wins against MMX; the MMX version has
therefore been removed (as well as the now unused inline_asm.h).
The new function is even 32B smaller than the old MMX one.

Old benchmarks:
put_no_rnd_pixels_tab[1][3]_c:  84.1 ( 1.00x)
put_no_rnd_pixels_tab[1][3]_mmx:41.1 ( 2.05x)

New benchmarks:
put_no_rnd_pixels_tab[1][3]_c:  84.0 ( 1.00x)
put_no_rnd_pixels_tab[1][3]_ssse3:  22.1 ( 3.80x)

Reviewed-by: Kieran Kunhya 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/x86/hpeldsp.asm b/libavcodec/x86/hpeldsp.asm
index 4c19da3e2a..fc51d72d17 100644
--- a/libavcodec/x86/hpeldsp.asm
+++ b/libavcodec/x86/hpeldsp.asm
@@ -407,6 +407,60 @@ INIT_XMM sse2
 AVG_PIXELS8_Y2
 
 
+; void ff_put_no_rnd_pixels8_xy2(uint8_t *block, const uint8_t *pixels, 
ptrdiff_t line_size, int h)
+%macro SET_PIXELS8_XY2 2-3
+cglobal %1%3_pixels8_xy2, 4,5,5
+movam4, [pb_1]
+movam3, [%2]
+movh

[FFmpeg-cvslog] [ffmpeg] branch master updated. b1f2eea1cd avfilter/vf_noise: Deduplicate option flags

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  b1f2eea1cd72f6ba01d2a3303462b9717a0d043a (commit)
   via  3ba570de8b666f5ae274b99d33cf4d4628cc385b (commit)
   via  adfec0f52e689e9ff47863e7f36297a33d03dd3d (commit)
   via  214b52df4341c610e0159618c08d96e823f26de8 (commit)
   via  ece623b1b32f619116088b0ad203146544423788 (commit)
   via  6a53a4e3417e80b6a5e575788f7ce0e6a6a2cff1 (commit)
   via  94948bd6b95f2a39daa23477f06c12a828c1e562 (commit)
  from  cd4b01707dd8275fb6f77e9a4d5ddd6fb02eaeef (commit)


- Log -
commit b1f2eea1cd72f6ba01d2a3303462b9717a0d043a
Author: Andreas Rheinhardt 
AuthorDate: Mon Oct 13 18:55:15 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Thu Oct 16 19:10:51 2025 +0200

avfilter/vf_noise: Deduplicate option flags

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavfilter/vf_noise.c b/libavfilter/vf_noise.c
index 74d63fe61b..ae4a08ca50 100644
--- a/libavfilter/vf_noise.c
+++ b/libavfilter/vf_noise.c
@@ -46,12 +46,8 @@ typedef struct ThreadData {
 {#name"_seed", "set component #"#x" noise seed", OFFSET(param.seed), 
AV_OPT_TYPE_INT, {.i64=-1}, -1, INT_MAX, FLAGS},\
 {#name"_strength", "set component #"#x" strength", OFFSET(param.strength), 
AV_OPT_TYPE_INT, {.i64=0}, 0, 100, FLAGS},\
 {#name"s", "set component #"#x" strength", OFFSET(param.strength), 
AV_OPT_TYPE_INT, {.i64=0}, 0, 100, FLAGS},\
-{#name"_flags", "set component #"#x" flags", OFFSET(param.flags), 
AV_OPT_TYPE_FLAGS, {.i64=0}, 0, 31, FLAGS, .unit = #name"_flags"}, \
-{#name"f", "set component #"#x" flags", OFFSET(param.flags), 
AV_OPT_TYPE_FLAGS, {.i64=0}, 0, 31, FLAGS, .unit = #name"_flags"},  \
-{"a", "averaged noise", 0, AV_OPT_TYPE_CONST, {.i64=NOISE_AVERAGED}, 0, 0, 
FLAGS, .unit = #name"_flags"},\
-{"p", "(semi)regular pattern", 0, AV_OPT_TYPE_CONST, {.i64=NOISE_PATTERN}, 
 0, 0, FLAGS, .unit = #name"_flags"}, \
-{"t", "temporal noise", 0, AV_OPT_TYPE_CONST, {.i64=NOISE_TEMPORAL}, 0, 0, 
FLAGS, .unit = #name"_flags"},\
-{"u", "uniform noise",  0, AV_OPT_TYPE_CONST, {.i64=NOISE_UNIFORM},  0, 0, 
FLAGS, .unit = #name"_flags"},
+{#name"_flags", "set component #"#x" flags", OFFSET(param.flags), 
AV_OPT_TYPE_FLAGS, {.i64=0}, 0, 31, FLAGS, .unit = "flags"}, \
+{#name"f", "set component #"#x" flags", OFFSET(param.flags), 
AV_OPT_TYPE_FLAGS, {.i64=0}, 0, 31, FLAGS, .unit = "flags"},  \
 
 static const AVOption noise_options[] = {
 NOISE_PARAMS(all, 0, all)
@@ -59,6 +55,10 @@ static const AVOption noise_options[] = {
 NOISE_PARAMS(c1,  1, param[1])
 NOISE_PARAMS(c2,  2, param[2])
 NOISE_PARAMS(c3,  3, param[3])
+{"a", "averaged noise", 0, AV_OPT_TYPE_CONST, {.i64=NOISE_AVERAGED}, 0, 0, 
FLAGS, .unit = "flags"},
+{"p", "(semi)regular pattern", 0, AV_OPT_TYPE_CONST, {.i64=NOISE_PATTERN}, 
 0, 0, FLAGS, .unit = "flags"},
+{"t", "temporal noise", 0, AV_OPT_TYPE_CONST, {.i64=NOISE_TEMPORAL}, 0, 0, 
FLAGS, .unit = "flags"},
+{"u", "uniform noise",  0, AV_OPT_TYPE_CONST, {.i64=NOISE_UNIFORM},  0, 0, 
FLAGS, .unit = "flags"},
 {NULL}
 };
 

commit 3ba570de8b666f5ae274b99d33cf4d4628cc385b
Author: Andreas Rheinhardt 
AuthorDate: Mon Oct 13 15:35:35 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Thu Oct 16 19:09:45 2025 +0200

avfilter/x86/vf_noise: Port line_noise funcs to SSE2

This avoids having to fix up ABI violations via emms_c and
also leads to a 73% speedup for the line noise average version
here.

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavfilter/vf_noise.c b/libavfilter/vf_noise.c
index 43e7ad6c45..74d63fe61b 100644
--- a/libavfilter/vf_noise.c
+++ b/libavfilter/vf_noise.c
@@ -24,7 +24,6 @@
  * noise generator
  */
 
-#include "libavutil/emms.h"
 #include "libavutil/mem.h"
 #include "libavutil/opt.h"
 #include "libavutil/imgutils.h"
@@ -280,7 +279,6 @@ static int filter_frame(AVFilterLink *inlink, AVFrame 
*inpicref)
 ff_filter_execute(ctx, filter_slice, &td, NULL,
   n->slice_threading_impossible ? 1 :
   FFMIN(n->height[0], ff_filter_get_nb_threads(ctx)));
-emms_c();
 
 if (inpicref != out)
 av_frame_free(&inpicref);
diff --git a/libavfilter/x86/vf_noise.c b/libavfilter/x86/vf_noise.c
index 2a7646728f..95f97b3b06 100644
--- a/libavfilter/x86/vf_noise.c
+++ b/libavfilter/x86/vf_noise.c
@@ -26,78 +26,81 @@
 
 #if HAVE_INLINE_ASM
 #if HAVE_6REGS
-static void line_noise_avg_mmx(uint8_t *dst, const uint8_t *src,
-  int len, const int8_t * const *shift)
+static void line_noise_avg_sse2(uint8_t *dst, const uint8_t *src,
+int len, const int8_t * const *shift)
 {
-x86_reg mmx_len = len & (~7);
+x86_reg xmm_len = len & (~15);
 
 __asm_

[FFmpeg-cvslog] [ffmpeg] branch master updated. 74a3c1ddb6 avfilter/x86/vf_pullup: Port pullup functions to SSE2, SSSE3

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  74a3c1ddb6f7aee90575697975b480d78dd78f4f (commit)
   via  dcb28ed860166c9715afb7c71c70889e6b9b8c8d (commit)
  from  f4a87d8ca4118b5130ff6ef332a5f20feb4bb9a7 (commit)


- Log -
commit 74a3c1ddb6f7aee90575697975b480d78dd78f4f
Author: Andreas Rheinhardt 
AuthorDate: Sun Oct 12 19:28:35 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Wed Oct 15 19:43:37 2025 +0200

avfilter/x86/vf_pullup: Port pullup functions to SSE2, SSSE3

The diff and var functions benefit from psadbw, comb from wider
registers which allows to avoid reloading values, reducing the number
of loads from 48 to 10. Performance increased by 117% (the loop
in compute_metric() has been timed); codesize decreased by 144B.

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavfilter/vf_pullup.c b/libavfilter/vf_pullup.c
index 1e4289aab1..d963840fe9 100644
--- a/libavfilter/vf_pullup.c
+++ b/libavfilter/vf_pullup.c
@@ -19,7 +19,6 @@
  */
 
 #include "libavutil/avassert.h"
-#include "libavutil/emms.h"
 #include "libavutil/imgutils.h"
 #include "libavutil/mem.h"
 #include "libavutil/opt.h"
@@ -597,7 +596,6 @@ static void pullup_submit_field(PullupContext *s, 
PullupBuffer *b, int parity)
 compute_metric(s, f->diffs, f, parity, f->prev->prev, parity, s->diff);
 compute_metric(s, f->combs, parity ? f->prev : f, 0, parity ? f : f->prev, 
1, s->comb);
 compute_metric(s, f->vars, f, parity, f, -1, s->var);
-emms_c();
 
 /* Advance the circular list */
 if (!s->first)
diff --git a/libavfilter/x86/vf_pullup.asm b/libavfilter/x86/vf_pullup.asm
index 26c2a27d37..6875a846a2 100644
--- a/libavfilter/x86/vf_pullup.asm
+++ b/libavfilter/x86/vf_pullup.asm
@@ -22,157 +22,89 @@
 
 SECTION .text
 
-INIT_MMX mmx
-cglobal pullup_filter_diff, 3, 5, 8, first, second, size
+INIT_XMM sse2
+cglobal pullup_filter_diff, 3, 4, 3, first, second, size
 movr3, 4
-pxor   m4, m4
-pxor   m7, m7
+pxor   m2, m2
 
 .loop:
 movq   m0, [firstq]
-movq   m2, [firstq]
 addfirstq, sizeq
 movq   m1, [secondq]
 addsecondq, sizeq
-psubusbm2, m1
-psubusbm1, m0
-movq   m0, m2
-movq   m3, m1
-punpcklbw  m0, m7
-punpcklbw  m1, m7
-punpckhbw  m2, m7
-punpckhbw  m3, m7
-paddw  m4, m0
-paddw  m4, m1
-paddw  m4, m2
-paddw  m4, m3
+psadbw m0, m1
+paddw  m2, m0
 
 decr3
 jnz .loop
 
-movq   m3, m4
-punpcklwd  m4, m7
-punpckhwd  m3, m7
-paddd  m3, m4
-movd  eax, m3
-psrlq  m3, 32
-movd  r4d, m3
-add   eax, r4d
+movd  eax, m2
 RET
 
-INIT_MMX mmx
-cglobal pullup_filter_comb, 3, 5, 8, first, second, size
-movr3, 4
-pxor   m6, m6
-pxor   m7, m7
-subsecondq, sizeq
-
-.loop:
+INIT_XMM ssse3
+cglobal pullup_filter_comb, 3, 5, 7, first, second, size
 movq   m0, [firstq]
+sub   secondq, sizeq
 movq   m1, [secondq]
-punpcklbw  m0, m7
-movq   m2, [secondq+sizeq]
-punpcklbw  m1, m7
-punpcklbw  m2, m7
-paddw  m0, m0
-paddw  m1, m2
-movq   m2, m0
-psubuswm0, m1
-psubuswm1, m2
-paddw  m6, m0
-paddw  m6, m1
+pxor   m6, m6
+punpcklbw  m0, m6
+punpcklbw  m1, m6
+addfirstq, sizeq
+add   secondq, sizeq
+pxor   m5, m5
+movr3, 4
 
-movq   m0, [firstq]
-movq   m1, [secondq]
-punpckhbw  m0, m7
-movq   m2, [secondq+sizeq]
-punpckhbw  m1, m7
-punpckhbw  m2, m7
-paddw  m0, m0
-paddw  m1, m2
-movq   m2, m0
-psubuswm0, m1
-psubuswm1, m2
-paddw  m6, m0
-paddw  m6, m1
+.loop:
+movq   m2, [firstq]
+movq   m3, [secondq]
+addfirstq, sizeq
+add   secondq, sizeq
+punpcklbw  m2, m6
+punpcklbw  m3, m6
+mova   m4, m0
 
-movq   m0, [secondq+sizeq]
-movq   m1, [firstq]
-punpcklbw  m0, m7
-movq   m2, [firstq+sizeq]
-punpcklbw  m1, m7
-punpcklbw  m2, m7
 paddw  m0, m0
-paddw  m1, m2
-movq   m2, m0
-psubuswm0, m1
-psubuswm1, m2
-paddw  m6, m0
-paddw  m6, m1
+paddw  m1, m3
+psubw  m0, m1
+pabsw  m0, m0
+paddw  m5, m0
 
-movq   m0, [secondq+sizeq]
-movq   m1, [firstq]
-punpckhbw  m0, m7
-movq   m2, [firstq+sizeq]
-punpckhbw  m1, m7
-punpckhbw  m2, m7
-paddw  m0, m0
-paddw  m1, m2
-movq   m2, m0
-psubuswm0, m1
-psubuswm1, m2
-paddw  m6, m0
-paddw  m6, m1
+mova   m1, m3
+paddw  m4, m2
+paddw  m3, m3
+psubw  m3, m4
+pabsw  m3, m3
+paddw  

[FFmpeg-cvslog] [ffmpeg] branch master updated. f4a87d8ca4 avcodec/x86/mpegvideoencdsp_init: Use xmm registers in SSSE3 functions

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  f4a87d8ca4118b5130ff6ef332a5f20feb4bb9a7 (commit)
   via  cffd029e98cef5d102bdd32af1bd860b6821df4a (commit)
   via  ce499ebf96a6725aa1e00300e951b5036e0356e4 (commit)
  from  566e9032b1dee8ed4b8bf5faae0b1f9aa873197f (commit)


- Log -
commit f4a87d8ca4118b5130ff6ef332a5f20feb4bb9a7
Author: Andreas Rheinhardt 
AuthorDate: Sun Oct 12 08:04:11 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Wed Oct 15 08:55:13 2025 +0200

avcodec/x86/mpegvideoencdsp_init: Use xmm registers in SSSE3 functions

Improves performance and no longer breaks the ABI (by forgetting
to call emms).

Old benchmarks:
add_8x8basis_c: 43.6 ( 1.00x)
add_8x8basis_ssse3: 12.3 ( 3.55x)

New benchmarks:
add_8x8basis_c: 43.0 ( 1.00x)
add_8x8basis_ssse3:  6.3 ( 6.79x)

Notice that the output of try_8x8basis_ssse3 changes a bit:
Before this commit, it computes certain values and adds the values
for i,i+1,i+4 and i+5 before right shifting them; now it adds
the values for i,i+1,i+8,i+9. The second pair in these lists
could be avoided (by shifting xmm0 and xmm1 before adding both together
instead of only shifting xmm0 after adding them), but the former
i,i+1 is inherent in using pmaddwd. This is the reason that this
function is not bitexact.

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c
index dbf4d25136..9f5da254bf 100644
--- a/libavcodec/mpegvideo_enc.c
+++ b/libavcodec/mpegvideo_enc.c
@@ -2296,7 +2296,7 @@ static av_always_inline void 
encode_mb_internal(MPVEncContext *const s,
  * and neither of these encoders currently supports 444. */
 #define INTERLACED_DCT(s) ((chroma_format == CHROMA_420 || chroma_format == 
CHROMA_422) && \
(s)->c.avctx->flags & AV_CODEC_FLAG_INTERLACED_DCT)
-int16_t weight[12][64];
+DECLARE_ALIGNED(16, int16_t, weight)[12][64];
 int16_t orig[12][64];
 const int mb_x = s->c.mb_x;
 const int mb_y = s->c.mb_y;
@@ -4293,7 +4293,7 @@ static int dct_quantize_trellis_c(MPVEncContext *const s,
 return last_non_zero;
 }
 
-static int16_t basis[64][64];
+static DECLARE_ALIGNED(16, int16_t, basis)[64][64];
 
 static void build_basis(uint8_t *perm){
 int i, j, x, y;
@@ -4317,7 +4317,7 @@ static void build_basis(uint8_t *perm){
 static int dct_quantize_refine(MPVEncContext *const s, //FIXME breaks denoise?
 int16_t *block, int16_t *weight, int16_t *orig,
 int n, int qscale){
-int16_t rem[64];
+DECLARE_ALIGNED(16, int16_t, rem)[64];
 LOCAL_ALIGNED_16(int16_t, d1, [64]);
 const uint8_t *scantable;
 const uint8_t *perm_scantable;
diff --git a/libavcodec/x86/mpegvideoencdsp_init.c 
b/libavcodec/x86/mpegvideoencdsp_init.c
index dc8fcd8833..3cd16fefbf 100644
--- a/libavcodec/x86/mpegvideoencdsp_init.c
+++ b/libavcodec/x86/mpegvideoencdsp_init.c
@@ -35,13 +35,6 @@ int ff_pix_norm1_sse2(const uint8_t *pix, ptrdiff_t 
line_size);
 #if HAVE_SSSE3_INLINE
 #define SCALE_OFFSET -1
 
-/*
- * pmulhrsw: dst[0 - 15] = (src[0 - 15] * dst[0 - 15] + 0x4000)[15 - 30]
- */
-#define PMULHRW(x, y, s, o) \
-"pmulhrsw " #s ", " #x "\n\t"   \
-"pmulhrsw " #s ", " #y "\n\t"
-
 #define MAX_ABS 512
 
 static int try_8x8basis_ssse3(const int16_t rem[64], const int16_t weight[64], 
const int16_t basis[64], int scale)
@@ -52,36 +45,39 @@ static int try_8x8basis_ssse3(const int16_t rem[64], const 
int16_t weight[64], c
 scale <<= 16 + SCALE_OFFSET - BASIS_SHIFT + RECON_SHIFT;
 
 __asm__ volatile(
-"pxor %%mm7, %%mm7  \n\t"
-"movd  %4, %%mm5\n\t"
-"punpcklwd %%mm5, %%mm5 \n\t"
-"punpcklwd %%mm5, %%mm5 \n\t"
-".p2align 4 \n\t"
-"1: \n\t"
-"movq  (%1, %0), %%mm0  \n\t"
-"movq  8(%1, %0), %%mm1 \n\t"
-PMULHRW(%%mm0, %%mm1, %%mm5, %%mm6)
-"paddw (%2, %0), %%mm0  \n\t"
-"paddw 8(%2, %0), %%mm1 \n\t"
-"psraw $6, %%mm0\n\t"
-"psraw $6, %%mm1\n\t"
-"pmullw (%3, %0), %%mm0 \n\t"
-"pmullw 8(%3, %0), %%mm1\n\t"
-"pmaddwd %%mm0, %%mm0   \n\t"
-"pmaddwd %%mm1, %%mm1   \n\t"
-"paddd %%mm1, %%mm0 \n\t"
-"psrld $4, %%mm0\n\t"
-"paddd %%mm0, %%mm7 \n\t"
-"add $16, %0\n\t"
-"cmp $128, %0   \n\t" //FIXME optimize & bench
-" jb 1b

[FFmpeg-cvslog] [ffmpeg] branch master updated. 4377affc28 avcodec/hevc/refs: don't unconditionally discard non-IRAP frames if no IRAP frame was seen before

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  4377affc28d92f759d1de15ac68ce07b1aa48810 (commit)
  from  378d5bb08a460a3c34a3ea89cd442424e1d035df (commit)


- Log -
commit 4377affc28d92f759d1de15ac68ce07b1aa48810
Author: James Almer 
AuthorDate: Tue Oct 7 15:39:34 2025 -0300
Commit: Zhao Zhili 
CommitDate: Thu Oct 9 02:52:46 2025 +

avcodec/hevc/refs: don't unconditionally discard non-IRAP frames if no IRAP 
frame was seen before

Should fix issue #20661

Signed-off-by: James Almer 

diff --git a/libavcodec/hevc/refs.c b/libavcodec/hevc/refs.c
index ab2e075af0..15f37bfcd8 100644
--- a/libavcodec/hevc/refs.c
+++ b/libavcodec/hevc/refs.c
@@ -235,6 +235,7 @@ int ff_hevc_set_new_ref(HEVCContext *s, HEVCLayerContext 
*l, int poc)
 s->layers[0].cur_frame - s->layers[0].DPB : -1;
 
 no_output = !IS_IRAP(s) && (s->poc < s->recovery_poc) &&
+HEVC_IS_RECOVERING(s) &&
 !(s->avctx->flags & AV_CODEC_FLAG_OUTPUT_CORRUPT) &&
 !(s->avctx->flags2 & AV_CODEC_FLAG2_SHOW_ALL);
 if (s->sh.pic_output_flag && !no_output)

---

Summary of changes:
 libavcodec/hevc/refs.c | 1 +
 1 file changed, 1 insertion(+)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 566e9032b1 swscale/output: Fix unsigned cast position in yuv2*

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  566e9032b1dee8ed4b8bf5faae0b1f9aa873197f (commit)
   via  0c6b7f9483a38657c9be824572b4c0c45d4d9fef (commit)
  from  6b961f5963d8e362137702d38a744b45fba8ba3a (commit)


- Log -
commit 566e9032b1dee8ed4b8bf5faae0b1f9aa873197f
Author: Michael Niedermayer 
AuthorDate: Mon Oct 13 14:46:16 2025 +0200
Commit: Michael Niedermayer 
CommitDate: Tue Oct 14 20:55:54 2025 +0200

swscale/output: Fix unsigned cast position in  yuv2*

Fixes: signed overflow

Signed-off-by: Michael Niedermayer 

diff --git a/libswscale/output.c b/libswscale/output.c
index cb6630bd73..4b3aab3109 100644
--- a/libswscale/output.c
+++ b/libswscale/output.c
@@ -503,8 +503,8 @@ static void yuv2nv12cX_c(enum AVPixelFormat dstFormat, 
const uint8_t *chrDither,
 int v = chrDither[(i + 3) & 7] << 12;
 int j;
 for (j=0; j>19);
@@ -516,8 +516,8 @@ static void yuv2nv12cX_c(enum AVPixelFormat dstFormat, 
const uint8_t *chrDither,
 int v = chrDither[(i + 3) & 7] << 12;
 int j;
 for (j=0; j>19);
@@ -577,8 +577,8 @@ static void yuv2p01xcX_c(int big_endian, const uint8_t 
*chrDither,
 int v = 1 << (shift - 1);
 
 for (j = 0; j < chrFilterSize; j++) {
-u += (unsigned)(chrUSrc[j][i] * chrFilter[j]);
-v += (unsigned)(chrVSrc[j][i] * chrFilter[j]);
+u += chrUSrc[j][i] * (unsigned)chrFilter[j];
+v += chrVSrc[j][i] * (unsigned)chrFilter[j];
 }
 
 output_pixel(&dest[2*i]  , u);
@@ -678,8 +678,8 @@ yuv2mono_X_c_template(SwsInternal *c, const int16_t 
*lumFilter,
 int Y2 = 1 << 18;
 
 for (j = 0; j < lumFilterSize; j++) {
-Y1 += (unsigned)(lumSrc[j][i]   * lumFilter[j]);
-Y2 += (unsigned)(lumSrc[j][i+1] * lumFilter[j]);
+Y1 += lumSrc[j][i]   * (unsigned)lumFilter[j];
+Y2 += lumSrc[j][i+1] * (unsigned)lumFilter[j];
 }
 Y1 >>= 19;
 Y2 >>= 19;
@@ -896,12 +896,12 @@ yuv2422_X_c_template(SwsInternal *c, const int16_t 
*lumFilter,
 int V  = 1 << 18;
 
 for (j = 0; j < lumFilterSize; j++) {
-Y1 += (unsigned)(lumSrc[j][i * 2] * lumFilter[j]);
-Y2 += (unsigned)(lumSrc[j][i * 2 + 1] * lumFilter[j]);
+Y1 += lumSrc[j][i * 2] * (unsigned)lumFilter[j];
+Y2 += lumSrc[j][i * 2 + 1] * (unsigned)lumFilter[j];
 }
 for (j = 0; j < chrFilterSize; j++) {
-U += (unsigned)(chrUSrc[j][i] * chrFilter[j]);
-V += (unsigned)(chrVSrc[j][i] * chrFilter[j]);
+U += chrUSrc[j][i] * (unsigned)chrFilter[j];
+V += chrVSrc[j][i] * (unsigned)chrFilter[j];
 }
 Y1 >>= 19;
 Y2 >>= 19;
@@ -1802,12 +1802,12 @@ yuv2rgb_X_c_template(SwsInternal *c, const int16_t 
*lumFilter,
 const void *r, *g, *b;
 
 for (j = 0; j < lumFilterSize; j++) {
-Y1 += (unsigned)(lumSrc[j][i * 2] * lumFilter[j]);
-Y2 += (unsigned)(lumSrc[j][i * 2 + 1] * lumFilter[j]);
+Y1 += lumSrc[j][i * 2] * (unsigned)lumFilter[j];
+Y2 += lumSrc[j][i * 2 + 1] * (unsigned)lumFilter[j];
 }
 for (j = 0; j < chrFilterSize; j++) {
-U += (unsigned)(chrUSrc[j][i] * chrFilter[j]);
-V += (unsigned)(chrVSrc[j][i] * chrFilter[j]);
+U += chrUSrc[j][i] * (unsigned)chrFilter[j];
+V += chrVSrc[j][i] * (unsigned)chrFilter[j];
 }
 Y1 >>= 19;
 Y2 >>= 19;
@@ -1817,8 +1817,8 @@ yuv2rgb_X_c_template(SwsInternal *c, const int16_t 
*lumFilter,
 A1 = 1 << 18;
 A2 = 1 << 18;
 for (j = 0; j < lumFilterSize; j++) {
-A1 += (unsigned)(alpSrc[j][i * 2] * lumFilter[j]);
-A2 += (unsigned)(alpSrc[j][i * 2 + 1] * lumFilter[j]);
+A1 += alpSrc[j][i * 2] * (unsigned)lumFilter[j];
+A2 += alpSrc[j][i * 2 + 1] * (unsigned)lumFilter[j];
 }
 A1 >>= 19;
 A2 >>= 19;
@@ -2179,11 +2179,11 @@ yuv2rgb_full_X_c_template(SwsInternal *c, const int16_t 
*lumFilter,
 int V = (1<<9)-(128 << 19);
 
 for (j = 0; j < lumFilterSize; j++) {
-Y += (unsigned)(lumSrc[j][i] * lumFilter[j]);
+Y += lumSrc[j][i] * (unsigned)lumFilter[j];
 }
 for (j = 0; j < chrFilterSize; j++) {
-U += (unsigned)(chrUSrc[j][i] * chrFilter[j]);
-V += (unsigned)(chrVSrc[j][i] * chrFilter[j]);
+U += chrUSrc[j][i] * (unsigned)chrFilter[j];
+V += chrVSrc[j][i] * (unsigned)chrFilter[j];
 }
 Y >>= 10;
 U >>= 10;
@@ -2191,7 +2191,7 @@ yuv2rgb_full_X_c_template(SwsInternal *c, const int16_t 
*lumFilter,
 if (hasAlpha) {
 A = 1 << 18;
 for (j = 0; j

[FFmpeg-cvslog] [ffmpeg] branch master updated. c7815a4b70 avfilter/vf_chromakey: specify alphamode of chromakey filter

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  c7815a4b707b7ae685e5809179094a275885759e (commit)
   via  ba9c63578440209b9e20d3b3cf09cbb6cb8f86a5 (commit)
   via  027497891b7f453147446e774b748703aee53ae9 (commit)
   via  bb3a4de5a7be2f71099371c59abc670210f47641 (commit)
   via  4e27a4ba03d2aa9358e8780843bffe678844520d (commit)
   via  d5f0c55f3f824b7a1a65d818d8fa755eb0db031a (commit)
   via  adf51312eee5be4d4b80cf96b79d783f0b3dd4c7 (commit)
   via  a91cf4f38f133e6bc4049b2460573e1c70a03175 (commit)
   via  2749f5f91edc66d1c6dd7ce5e28a714ade0f8169 (commit)
  from  dcfef80bd93cb4b30b97229a994d682d988dc5d9 (commit)


- Log -
commit c7815a4b707b7ae685e5809179094a275885759e
Author: Zhao Zhili 
AuthorDate: Fri Sep 26 21:33:57 2025 +0800
Commit: Zhao Zhili 
CommitDate: Tue Oct 7 16:00:27 2025 +

avfilter/vf_chromakey: specify alphamode of chromakey filter

Fix assert failure with:
ffmpeg -i input.mp4 \
-vf chromakey=similarity=0.1,format=yuva420p,alphaextract \
-f null -

Assertion frame->alpha_mode == link->alpha_mode failed at 
src/libavfilter/avfilter.c:1085

diff --git a/libavfilter/vf_chromakey.c b/libavfilter/vf_chromakey.c
index f6f6314615..e5a7ac15b5 100644
--- a/libavfilter/vf_chromakey.c
+++ b/libavfilter/vf_chromakey.c
@@ -262,6 +262,8 @@ static int filter_frame(AVFilterLink *link, AVFrame *frame)
 FFMIN(frame->height, 
ff_filter_get_nb_threads(avctx
 return res;
 
+if (!strcmp(avctx->filter->name, "chromakey"))
+frame->alpha_mode = avctx->outputs[0]->alpha_mode;
 return ff_filter_frame(avctx->outputs[0], frame);
 }
 
@@ -291,6 +293,7 @@ static av_cold int config_output(AVFilterLink *outlink)
 }
 
 if (!strcmp(avctx->filter->name, "chromakey")) {
+outlink->alpha_mode = AVALPHA_MODE_STRAIGHT;
 ctx->do_slice = ctx->depth <= 8 ? do_chromakey_slice : 
do_chromakey16_slice;
 } else {
 ctx->do_slice = ctx->depth <= 8 ? do_chromahold_slice: 
do_chromahold16_slice;

commit ba9c63578440209b9e20d3b3cf09cbb6cb8f86a5
Author: Zhao Zhili 
AuthorDate: Fri Sep 26 21:06:24 2025 +0800
Commit: Zhao Zhili 
CommitDate: Tue Oct 7 16:00:27 2025 +

avfilter/vf_chromakey_cuda: specify alpha_mode of output

Fix assert failure with:

ffmpeg -init_hw_device cuda=gpu -filter_hw_device gpu \
-i input.mp4 -an \
-vf 
hwupload,format=cuda,chromakey_cuda=color=black,hwdownload,format=yuva420p,alphaextract
 \
-f null -

Assertion frame->alpha_mode == link->alpha_mode failed at 
src/libavfilter/avfilter.c:1085

diff --git a/libavfilter/vf_chromakey_cuda.c b/libavfilter/vf_chromakey_cuda.c
index 6595e5317b..4ffc5cd77e 100644
--- a/libavfilter/vf_chromakey_cuda.c
+++ b/libavfilter/vf_chromakey_cuda.c
@@ -259,6 +259,7 @@ static av_cold int cudachromakey_config_props(AVFilterLink 
*outlink)
 s->cu_stream = s->hwctx->stream;
 
 outlink->sample_aspect_ratio = inlink->sample_aspect_ratio;
+outlink->alpha_mode = AVALPHA_MODE_STRAIGHT;
 
 ret = cudachromakey_load_functions(ctx);
 if (ret < 0)
@@ -389,6 +390,7 @@ static int cudachromakey_filter_frame(AVFilterLink *link, 
AVFrame *in)
 ret = av_frame_copy_props(out, in);
 if (ret < 0)
 goto fail;
+out->alpha_mode = outlink->alpha_mode;
 
 ret = CHECK_CU(cu->cuCtxPopCurrent(&context));
 if (ret < 0)

commit 027497891b7f453147446e774b748703aee53ae9
Author: Zhao Zhili 
AuthorDate: Fri Sep 26 20:08:36 2025 +0800
Commit: Zhao Zhili 
CommitDate: Tue Oct 7 16:00:27 2025 +

avfilter/vf_chromakey_cuda: simplify frame management

diff --git a/libavfilter/vf_chromakey_cuda.c b/libavfilter/vf_chromakey_cuda.c
index 43f50c5a9a..6595e5317b 100644
--- a/libavfilter/vf_chromakey_cuda.c
+++ b/libavfilter/vf_chromakey_cuda.c
@@ -32,6 +32,7 @@
 #include "avfilter.h"
 #include "filters.h"
 #include "cuda/load_helper.h"
+#include "video.h"
 
 static const enum AVPixelFormat supported_formats[] = {
 AV_PIX_FMT_YUV420P,
@@ -61,10 +62,6 @@ typedef struct ChromakeyCUDAContext {
 float similarity;
 float blend;
 
-AVBufferRef *frames_ctx;
-AVFrame *frame;
-AVFrame *tmp_frame;
-
 CUcontext cu_ctx;
 CUmodule cu_module;
 CUfunction cu_func;
@@ -72,21 +69,6 @@ typedef struct ChromakeyCUDAContext {
 CUstream cu_stream;
 } ChromakeyCUDAContext;
 
-static av_cold int cudachromakey_init(AVFilterContext *ctx)
-{
-ChromakeyCUDAContext *s = ctx->priv;
-
-s->frame = av_frame_alloc();
-if (!s->frame)
-return AVERROR(ENOMEM);
-
-s->tmp_frame = av_frame_alloc();
-if (!s->tmp_frame)
-return AVERROR(ENOMEM);
-
-return 0;
-}
-
 static av_cold void cudachromakey_uninit(AVFilterContext *ctx)
 {
 ChromakeyCUDAContext *s = ctx->priv;
@@ -101,14 +83,12 @@ static av_cold void 

[FFmpeg-cvslog] [ffmpeg] branch master updated. e5f82ab868 Revert "lavc/libsvtav1: set packet durations"

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  e5f82ab8686b3c6193a3f718f53dbef9436b4318 (commit)
  from  17d5759bd99ab304c497ec149d493bc6ba1c6b52 (commit)


- Log -
commit e5f82ab8686b3c6193a3f718f53dbef9436b4318
Author: rcombs 
AuthorDate: Tue Sep 23 20:21:44 2025 -0700
Commit: rcombs 
CommitDate: Tue Sep 23 20:22:33 2025 -0700

Revert "lavc/libsvtav1: set packet durations"

This reverts commit 5c9b2027bc48ae5d39b0d82696895f0834788242.

This doesn't actually work the way it'd appeared to in testing;
the output was based on frame *encode latency*.

diff --git a/libavcodec/libsvtav1.c b/libavcodec/libsvtav1.c
index 8ac5fd2d04..c6a0ff90bc 100644
--- a/libavcodec/libsvtav1.c
+++ b/libavcodec/libsvtav1.c
@@ -520,7 +520,6 @@ static int eb_send_frame(AVCodecContext *avctx, const 
AVFrame *frame)
 headerPtr->flags = 0;
 headerPtr->p_app_private = NULL;
 headerPtr->pts   = frame->pts;
-headerPtr->n_tick_count  = frame->duration;
 
 switch (frame->pict_type) {
 case AV_PICTURE_TYPE_I:
@@ -637,7 +636,6 @@ static int eb_receive_packet(AVCodecContext *avctx, 
AVPacket *pkt)
 pkt->size = headerPtr->n_filled_len;
 pkt->pts  = headerPtr->pts;
 pkt->dts  = headerPtr->dts;
-pkt->duration = headerPtr->n_tick_count;
 
 switch (headerPtr->pic_type) {
 case EB_AV1_KEY_PICTURE:

---

Summary of changes:
 libavcodec/libsvtav1.c | 2 --
 1 file changed, 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch release/8.0 updated. 558994b051 avformat/dump: fix log level passed to av_log when printing stream group side data

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, release/8.0 has been updated
   via  558994b051424534fc598d7569fe2b896f103110 (commit)
  from  dd00a614e16a15db0b230dfe45790e913e593695 (commit)


- Log -
commit 558994b051424534fc598d7569fe2b896f103110
Author: James Almer 
AuthorDate: Mon Oct 13 23:39:52 2025 -0300
Commit: James Almer 
CommitDate: Wed Oct 15 20:31:21 2025 -0300

avformat/dump: fix log level passed to av_log when printing stream group 
side data

Signed-off-by: James Almer 
(cherry picked from commit 2e1d702cfc5c530c213361e6a1b77dca847a30e7)

diff --git a/libavformat/dump.c b/libavformat/dump.c
index 02f69f9a3a..a5cdf0b45b 100644
--- a/libavformat/dump.c
+++ b/libavformat/dump.c
@@ -367,11 +367,11 @@ static void dump_content_light_metadata(void *ctx, const 
AVPacketSideData *sd,
metadata->MaxCLL, metadata->MaxFALL);
 }
 
-static void dump_ambient_viewing_environment_metadata(void *ctx, const 
AVPacketSideData *sd)
+static void dump_ambient_viewing_environment_metadata(void *ctx, const 
AVPacketSideData *sd, int log_level)
 {
 const AVAmbientViewingEnvironment *ambient =
 (const AVAmbientViewingEnvironment *)sd->data;
-av_log(ctx, AV_LOG_INFO, "Ambient Viewing Environment, "
+av_log(ctx, log_level, "Ambient Viewing Environment, "
"ambient_illuminance=%f, ambient_light_x=%f, ambient_light_y=%f",
av_q2d(ambient->ambient_illuminance),
av_q2d(ambient->ambient_light_x),
@@ -445,12 +445,12 @@ static void dump_s12m_timecode(void *ctx, AVRational 
avg_frame_rate, const AVPac
 }
 }
 
-static void dump_cropping(void *ctx, const AVPacketSideData *sd)
+static void dump_cropping(void *ctx, const AVPacketSideData *sd, int log_level)
 {
 uint32_t top, bottom, left, right;
 
 if (sd->size < sizeof(uint32_t) * 4) {
-av_log(ctx, AV_LOG_ERROR, "invalid data\n");
+av_log(ctx, log_level, "invalid data\n");
 return;
 }
 
@@ -459,15 +459,15 @@ static void dump_cropping(void *ctx, const 
AVPacketSideData *sd)
 left   = AV_RL32(sd->data +  8);
 right  = AV_RL32(sd->data + 12);
 
-av_log(ctx, AV_LOG_INFO, "%d/%d/%d/%d", left, right, top, bottom);
+av_log(ctx, log_level, "%d/%d/%d/%d", left, right, top, bottom);
 }
 
-static void dump_tdrdi(void *ctx, const AVPacketSideData *sd)
+static void dump_tdrdi(void *ctx, const AVPacketSideData *sd, int log_level)
 {
 const AV3DReferenceDisplaysInfo *tdrdi =
 (const AV3DReferenceDisplaysInfo *)sd->data;
 
-av_log(ctx, AV_LOG_INFO, "number of reference displays: %u", 
tdrdi->num_ref_displays);
+av_log(ctx, log_level, "number of reference displays: %u", 
tdrdi->num_ref_displays);
 }
 
 static void dump_sidedata(void *ctx, const AVPacketSideData *side_data, int 
nb_side_data,
@@ -543,15 +543,15 @@ static void dump_sidedata(void *ctx, const 
AVPacketSideData *side_data, int nb_s
 dump_s12m_timecode(ctx, avg_frame_rate, sd, log_level);
 break;
 case AV_PKT_DATA_AMBIENT_VIEWING_ENVIRONMENT:
-dump_ambient_viewing_environment_metadata(ctx, sd);
+dump_ambient_viewing_environment_metadata(ctx, sd, log_level);
 break;
 case AV_PKT_DATA_FRAME_CROPPING:
 av_log(ctx, AV_LOG_INFO, "Frame cropping: ");
-dump_cropping(ctx, sd);
+dump_cropping(ctx, sd, log_level);
 break;
 case AV_PKT_DATA_3D_REFERENCE_DISPLAYS:
 av_log(ctx, log_level, "3D Reference Displays Information: ");
-dump_tdrdi(ctx, sd);
+dump_tdrdi(ctx, sd, log_level);
 break;
 default:
 av_log(ctx, log_level, "unknown side data type %d "
@@ -693,7 +693,7 @@ FF_ENABLE_DEPRECATION_WARNINGS
 
 if (st->start_time != AV_NOPTS_VALUE && st->start_time != 0 && 
st->time_base.den && st->time_base.num) {
 const double stream_start = av_q2d(st->time_base) * st->start_time;
-av_log(NULL, AV_LOG_INFO, ", start %.6f", stream_start);
+av_log(NULL, log_level, ", start %.6f", stream_start);
 }
 
 dump_disposition(st->disposition, log_level);

---

Summary of changes:
 libavformat/dump.c | 22 +++---
 1 file changed, 11 insertions(+), 11 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. e63e040f0c avformat/rtsp: fix leading space in RTSP reason

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  e63e040f0cef2d6af2fb57aefa6250fc450fa049 (commit)
   via  2ed47ab72509bbee60288d245a0aebb7eb05e41a (commit)
  from  899e497122f793c3d97f5aac7bee62567f23fe29 (commit)


- Log -
commit e63e040f0cef2d6af2fb57aefa6250fc450fa049
Author: Marvin Scholz 
AuthorDate: Fri Aug 22 21:41:26 2025 +0200
Commit: Marvin Scholz 
CommitDate: Tue Sep 23 21:33:37 2025 +

avformat/rtsp: fix leading space in RTSP reason

When parsing the RTSP message reason, the whole remainder
after parsing the status code was used, which would lead to
a leading space in the parsed reason string.

diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c
index 13507d1858..d601d63a89 100644
--- a/libavformat/rtsp.c
+++ b/libavformat/rtsp.c
@@ -1274,6 +1274,7 @@ start:
 if (!strncmp(buf1, "RTSP/", 5)) {
 get_word(buf1, sizeof(buf1), &p);
 reply->status_code = atoi(buf1);
+p += strspn(p, SPACE_CHARS);
 av_strlcpy(reply->reason, p, sizeof(reply->reason));
 } else {
 av_strlcpy(reply->reason, buf1, sizeof(reply->reason)); // 
method

commit 2ed47ab72509bbee60288d245a0aebb7eb05e41a
Author: Marvin Scholz 
AuthorDate: Fri Aug 22 16:50:34 2025 +0200
Commit: Marvin Scholz 
CommitDate: Tue Sep 23 21:33:37 2025 +

avformat/rtsp: do not log invalid values

When reading fails the first time, ch would be uninitialized and
printed in the log message. Instead check for an error early and
log it properly.

diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c
index 10355b89b8..13507d1858 100644
--- a/libavformat/rtsp.c
+++ b/libavformat/rtsp.c
@@ -1239,9 +1239,12 @@ start:
 q = buf;
 for (;;) {
 ret = ffurl_read_complete(rt->rtsp_hd, &ch, 1);
+if (ret != 1) {
+ret = (ret < 0) ? ret : AVERROR(EIO);
+av_log(s, AV_LOG_WARNING, "Failed reading RTSP data: %s\n", 
av_err2str(ret));
+return ret;
+}
 av_log(s, AV_LOG_TRACE, "ret=%d c=%02x [%c]\n", ret, ch, ch);
-if (ret != 1)
-return ret < 0 ? ret : AVERROR(EIO);
 if (ch == '\n')
 break;
 if (ch == '$' && q == buf) {

---

Summary of changes:
 libavformat/rtsp.c | 8 ++--
 1 file changed, 6 insertions(+), 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 10e9672a8c avcodec/d3d12va_encode: use macros to set QP range and max frame size

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  10e9672a8caca79f0e2f097513d22128787f9ad2 (commit)
  from  36f92206bb90d6f0268749bd6fe6aa57974442db (commit)


- Log -
commit 10e9672a8caca79f0e2f097513d22128787f9ad2
Author: Tong Wu 
AuthorDate: Wed Oct 8 11:41:56 2025 +0800
Commit: Tong Wu 
CommitDate: Sun Oct 12 01:50:57 2025 +

avcodec/d3d12va_encode: use macros to set QP range and max frame size

Signed-off-by: Tong Wu 

diff --git a/libavcodec/d3d12va_encode.c b/libavcodec/d3d12va_encode.c
index f34605ec41..4a8672a359 100644
--- a/libavcodec/d3d12va_encode.c
+++ b/libavcodec/d3d12va_encode.c
@@ -853,6 +853,21 @@ static int d3d12va_encode_init_rate_control(AVCodecContext 
*avctx)
 int fr_num, fr_den;
 const D3D12VAEncodeRCMode *rc_mode;
 
+#define SET_QP_RANGE(ctl) do { \
+if (avctx->qmin > 0 || avctx->qmax > 0) { \
+ctl->MinQP = avctx->qmin; \
+ctl->MaxQP = avctx->qmax; \
+ctx->rc.Flags |= 
D3D12_VIDEO_ENCODER_RATE_CONTROL_FLAG_ENABLE_QP_RANGE; \
+} \
+} while(0)
+
+#define SET_MAX_FRAME_SIZE(ctl) do { \
+if (ctx->max_frame_size > 0) { \
+ctl->MaxFrameBitSize = ctx->max_frame_size * 8; \
+ctx->rc.Flags |= 
D3D12_VIDEO_ENCODER_RATE_CONTROL_FLAG_ENABLE_MAX_FRAME_SIZE; \
+} \
+} while(0)
+
 // Rate control mode selection:
 // * If the user has set a mode explicitly with the rc_mode option,
 //   use it and fail if it is not available.
@@ -1053,16 +1068,8 @@ rc_mode_found:
 cbr_ctl->InitialVBVFullness = hrd_initial_buffer_fullness;
 ctx->rc.Flags |= 
D3D12_VIDEO_ENCODER_RATE_CONTROL_FLAG_ENABLE_VBV_SIZES;
 
-if (avctx->qmin > 0 || avctx->qmax > 0) {
-cbr_ctl->MinQP = avctx->qmin;
-cbr_ctl->MaxQP = avctx->qmax;
-ctx->rc.Flags |= 
D3D12_VIDEO_ENCODER_RATE_CONTROL_FLAG_ENABLE_QP_RANGE;
-}
-
-if (ctx->max_frame_size > 0) {
-cbr_ctl->MaxFrameBitSize = ctx->max_frame_size * 8;
-ctx->rc.Flags |= 
D3D12_VIDEO_ENCODER_RATE_CONTROL_FLAG_ENABLE_MAX_FRAME_SIZE;
-}
+SET_QP_RANGE(cbr_ctl);
+SET_MAX_FRAME_SIZE(cbr_ctl);
 
 ctx->rc.ConfigParams.pConfiguration_CBR = cbr_ctl;
 break;
@@ -1081,16 +1088,8 @@ rc_mode_found:
 vbr_ctl->InitialVBVFullness = hrd_initial_buffer_fullness;
 ctx->rc.Flags |= 
D3D12_VIDEO_ENCODER_RATE_CONTROL_FLAG_ENABLE_VBV_SIZES;
 
-if (avctx->qmin > 0 || avctx->qmax > 0) {
-vbr_ctl->MinQP = avctx->qmin;
-vbr_ctl->MaxQP = avctx->qmax;
-ctx->rc.Flags |= 
D3D12_VIDEO_ENCODER_RATE_CONTROL_FLAG_ENABLE_QP_RANGE;
-}
-
-if (ctx->max_frame_size > 0) {
-vbr_ctl->MaxFrameBitSize = ctx->max_frame_size * 8;
-ctx->rc.Flags |= 
D3D12_VIDEO_ENCODER_RATE_CONTROL_FLAG_ENABLE_MAX_FRAME_SIZE;
-}
+SET_QP_RANGE(vbr_ctl);
+SET_MAX_FRAME_SIZE(vbr_ctl);
 
 ctx->rc.ConfigParams.pConfiguration_VBR = vbr_ctl;
 break;
@@ -1107,16 +1106,8 @@ rc_mode_found:
 qvbr_ctl->PeakBitRate   = rc_peak_bitrate;
 qvbr_ctl->ConstantQualityTarget = rc_quality;
 
-if (avctx->qmin > 0 || avctx->qmax > 0) {
-qvbr_ctl->MinQP = avctx->qmin;
-qvbr_ctl->MaxQP = avctx->qmax;
-ctx->rc.Flags |= 
D3D12_VIDEO_ENCODER_RATE_CONTROL_FLAG_ENABLE_QP_RANGE;
-}
-
-if (ctx->max_frame_size > 0) {
-qvbr_ctl->MaxFrameBitSize = ctx->max_frame_size * 8;
-ctx->rc.Flags |= 
D3D12_VIDEO_ENCODER_RATE_CONTROL_FLAG_ENABLE_MAX_FRAME_SIZE;
-}
+SET_QP_RANGE(qvbr_ctl);
+SET_MAX_FRAME_SIZE(qvbr_ctl);
 
 ctx->rc.ConfigParams.pConfiguration_QVBR = qvbr_ctl;
 break;

---

Summary of changes:
 libavcodec/d3d12va_encode.c | 51 +++--
 1 file changed, 21 insertions(+), 30 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch release/8.0 updated. dd00a614e1 avcodec/hevc/sei: don't attempt to use stale values in HEVCSEITDRDI

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, release/8.0 has been updated
   via  dd00a614e16a15db0b230dfe45790e913e593695 (commit)
   via  046a8293e1665e7d794b3595cb746e5206299ab3 (commit)
   via  d961a634fbea691d76a2eb31d4b79fd4a7b36271 (commit)
  from  d8605a6b5549887edcca69c1ba0400fe14e0de3d (commit)


- Log -
commit dd00a614e16a15db0b230dfe45790e913e593695
Author: James Almer 
AuthorDate: Thu Oct 9 00:31:57 2025 -0300
Commit: James Almer 
CommitDate: Thu Oct 9 12:15:41 2025 -0300

avcodec/hevc/sei: don't attempt to use stale values in HEVCSEITDRDI

Invalidate the whole struct on SEI reset.

Signed-off-by: James Almer 
(cherry picked from commit 8e01bff774aeacdeb8cc9fb5a6fe8c958bdfa704)

diff --git a/libavcodec/hevc/hevcdec.c b/libavcodec/hevc/hevcdec.c
index f44bda8a92..8a845f54f3 100644
--- a/libavcodec/hevc/hevcdec.c
+++ b/libavcodec/hevc/hevcdec.c
@@ -4106,7 +4106,7 @@ static int hevc_sei_to_context(AVCodecContext *avctx, 
HEVCSEI *sei)
 {
 int ret;
 
-if (sei->tdrdi.num_ref_displays) {
+if (sei->tdrdi.present) {
 AVBufferRef *buf;
 size_t size;
 AV3DReferenceDisplaysInfo *tdrdi = 
av_tdrdi_alloc(sei->tdrdi.num_ref_displays, &size);
diff --git a/libavcodec/hevc/sei.c b/libavcodec/hevc/sei.c
index e81dfcbff9..5fd4e763b3 100644
--- a/libavcodec/hevc/sei.c
+++ b/libavcodec/hevc/sei.c
@@ -217,6 +217,8 @@ static int 
decode_nal_sei_3d_reference_displays_info(HEVCSEITDRDI *s, GetBitCont
 }
 s->three_dimensional_reference_displays_extension_flag = get_bits1(gb);
 
+s->present = 1;
+
 return 0;
 }
 
diff --git a/libavcodec/hevc/sei.h b/libavcodec/hevc/sei.h
index c4714bb7c5..d6891d60a6 100644
--- a/libavcodec/hevc/sei.h
+++ b/libavcodec/hevc/sei.h
@@ -93,6 +93,7 @@ typedef struct HEVCSEITDRDI {
 uint8_t additional_shift_present_flag[32];
 int16_t num_sample_shift[32];
 uint8_t three_dimensional_reference_displays_extension_flag;
+int present;
 } HEVCSEITDRDI;
 
 typedef struct HEVCSEIRecoveryPoint {
@@ -126,6 +127,7 @@ int ff_hevc_decode_nal_sei(GetBitContext *gb, void *logctx, 
HEVCSEI *s,
  */
 static inline void ff_hevc_reset_sei(HEVCSEI *sei)
 {
+sei->tdrdi.present = 0;
 ff_h2645_sei_reset(&sei->common);
 }
 

commit 046a8293e1665e7d794b3595cb746e5206299ab3
Author: James Almer 
AuthorDate: Thu Oct 9 00:31:10 2025 -0300
Commit: James Almer 
CommitDate: Thu Oct 9 12:15:41 2025 -0300

avcodec/hevc/sei: prevent storing a potentially bogus num_ref_displays 
value in HEVCSEITDRDI

Fixes: 
439711052/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HEVC_fuzzer-4956250308935680
Fixes: out of array access

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: James Almer 
(cherry picked from commit d448d6d1a0a4cdc76499c137742fdd8b30b9e7de)

diff --git a/libavcodec/hevc/sei.c b/libavcodec/hevc/sei.c
index b8e98cde89..e81dfcbff9 100644
--- a/libavcodec/hevc/sei.c
+++ b/libavcodec/hevc/sei.c
@@ -167,6 +167,8 @@ static int decode_nal_sei_timecode(HEVCSEITimeCode *s, 
GetBitContext *gb)
 
 static int decode_nal_sei_3d_reference_displays_info(HEVCSEITDRDI *s, 
GetBitContext *gb)
 {
+unsigned num_ref_displays;
+
 s->prec_ref_display_width = get_ue_golomb(gb);
 if (s->prec_ref_display_width > 31)
 return AVERROR_INVALIDDATA;
@@ -176,10 +178,10 @@ static int 
decode_nal_sei_3d_reference_displays_info(HEVCSEITDRDI *s, GetBitCont
 if (s->prec_ref_viewing_dist > 31)
 return AVERROR_INVALIDDATA;
 }
-s->num_ref_displays = get_ue_golomb(gb);
-if (s->num_ref_displays > 31)
+num_ref_displays = get_ue_golomb(gb);
+if (num_ref_displays > 31)
 return AVERROR_INVALIDDATA;
-s->num_ref_displays += 1;
+s->num_ref_displays = num_ref_displays + 1;
 
 for (int i = 0; i < s->num_ref_displays; i++) {
 int length;

commit d961a634fbea691d76a2eb31d4b79fd4a7b36271
Author: James Almer 
AuthorDate: Tue Oct 7 15:39:34 2025 -0300
Commit: James Almer 
CommitDate: Thu Oct 9 12:15:41 2025 -0300

avcodec/hevc/refs: don't unconditionally discard non-IRAP frames if no IRAP 
frame was seen before

Should fix issue #20661

Signed-off-by: James Almer 
(cherry picked from commit 4377affc28d92f759d1de15ac68ce07b1aa48810)

diff --git a/libavcodec/hevc/refs.c b/libavcodec/hevc/refs.c
index ab2e075af0..15f37bfcd8 100644
--- a/libavcodec/hevc/refs.c
+++ b/libavcodec/hevc/refs.c
@@ -235,6 +235,7 @@ int ff_hevc_set_new_ref(HEVCContext *s, HEVCLayerContext 
*l, int poc)
 s->layers[0].cur_frame - s->layers[0].DPB : -1;
 
 no_output = !IS_IRAP(s) && (s->poc < s->recovery_poc) &&
+HEVC_IS_RECOVERING(s) &&
 !(s->avctx->flags & AV_CODEC_FLAG_OUTPUT_CORRUPT) &&
 !(s->avctx->flags2 & AV_CODEC_FLAG2_SHOW_ALL);
 if (s->s

[FFmpeg-cvslog] [ffmpeg] branch master updated. dcfef80bd9 avcodec/pngenc: Mark unreachable default switch cases as such

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  dcfef80bd93cb4b30b97229a994d682d988dc5d9 (commit)
  from  660983b7f3f699cd982a0688352604cc9ce3c8c6 (commit)


- Log -
commit dcfef80bd93cb4b30b97229a994d682d988dc5d9
Author: Andreas Rheinhardt 
AuthorDate: Thu Oct 2 21:07:48 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Tue Oct 7 17:36:25 2025 +0200

avcodec/pngenc: Mark unreachable default switch cases as such

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/pngenc.c b/libavcodec/pngenc.c
index 5baad9aad5..8e4f42125e 100644
--- a/libavcodec/pngenc.c
+++ b/libavcodec/pngenc.c
@@ -195,6 +195,8 @@ static void png_filter_row(PNGEncContext *c, uint8_t *dst, 
int filter_type,
 dst[i] = src[i] - top[i];
 sub_png_paeth_prediction(dst + i, src + i, top + i, size - i, bpp);
 break;
+default:
+av_unreachable("PNG_FILTER_VALUE_MIXED can't happen here and all 
others are covered");
 }
 }
 
@@ -816,6 +818,9 @@ static int apng_do_inverse_blend(AVFrame *output, const 
AVFrame *input,
 palette[*background] >> 24 == 0)
 break;
 return -1;
+
+default:
+av_unreachable("Pixfmt has been checked before");
 }
 
 memmove(output_data, foreground, bpp);
@@ -1193,7 +1198,7 @@ static av_cold int png_enc_init(AVCodecContext *avctx)
 s->color_type = PNG_COLOR_TYPE_PALETTE;
 break;
 default:
-return -1;
+av_unreachable("Already checked via CODEC_PIXFMTS");
 }
 s->bits_per_pixel = ff_png_get_nb_channels(s->color_type) * s->bit_depth;
 

---

Summary of changes:
 libavcodec/pngenc.c | 7 ++-
 1 file changed, 6 insertions(+), 1 deletion(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. ae03b629db avformat/mov: Merge tts after building index for old-style uncompressed PCM

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  ae03b629db116a8a5b6b40ede912fbb8b1ca0175 (commit)
  from  03c054d43c594211b89d5b2931430dccd7424d58 (commit)


- Log -
commit ae03b629db116a8a5b6b40ede912fbb8b1ca0175
Author: Derek Buitenhuis 
AuthorDate: Mon Sep 22 20:00:54 2025 +0100
Commit: Derek Buitenhuis 
CommitDate: Tue Sep 23 14:39:13 2025 +0100

avformat/mov: Merge tts after building index for old-style uncompressed PCM

This was a regression introduced in 
292c1df7c159c8a1a7afe52613d164ff417e81ce.

Since we don't know the length of the stts data until after building the
index, since we're generating it, we need to merge any ctts data after,
since otherwise tts_count is set to 0, and no packets will be output.

We can't remove the merge entirely, because uncompressed PCM with
a ctts atom is technically valid (e.g. a constant CTS offset).

This fixes old-style uncompressed PCM demuxing.

Fixes #11490.

Signed-off-by: Derek Buitenhuis 

diff --git a/libavformat/mov.c b/libavformat/mov.c
index 216c6a5442..7fe4678234 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -4841,10 +4841,6 @@ static void mov_build_index(MOVContext *mov, AVStream 
*st)
 if (!sc->chunk_count || sc->tts_count)
 return;
 
-ret = mov_merge_tts_data(mov, st, MOV_MERGE_CTTS);
-if (ret < 0)
-return;
-
 // compute total chunk count
 for (i = 0; i < sc->stsc_count; i++) {
 unsigned count, chunk_count;
@@ -4939,6 +4935,10 @@ static void mov_build_index(MOVContext *mov, AVStream 
*st)
 chunk_samples -= samples;
 }
 }
+
+ret = mov_merge_tts_data(mov, st, MOV_MERGE_CTTS);
+if (ret < 0)
+return;
 }
 
 if (!mov->ignore_editlist && mov->advanced_editlist) {

---

Summary of changes:
 libavformat/mov.c | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 5c9b2027bc lavc/libsvtav1: set packet durations

2025-09-23 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  5c9b2027bc48ae5d39b0d82696895f0834788242 (commit)
  from  ae03b629db116a8a5b6b40ede912fbb8b1ca0175 (commit)


- Log -
commit 5c9b2027bc48ae5d39b0d82696895f0834788242
Author: rcombs 
AuthorDate: Tue Sep 23 00:45:58 2025 -0700
Commit: James Almer 
CommitDate: Tue Sep 23 14:32:47 2025 +

lavc/libsvtav1: set packet durations

diff --git a/libavcodec/libsvtav1.c b/libavcodec/libsvtav1.c
index c6a0ff90bc..8ac5fd2d04 100644
--- a/libavcodec/libsvtav1.c
+++ b/libavcodec/libsvtav1.c
@@ -520,6 +520,7 @@ static int eb_send_frame(AVCodecContext *avctx, const 
AVFrame *frame)
 headerPtr->flags = 0;
 headerPtr->p_app_private = NULL;
 headerPtr->pts   = frame->pts;
+headerPtr->n_tick_count  = frame->duration;
 
 switch (frame->pict_type) {
 case AV_PICTURE_TYPE_I:
@@ -636,6 +637,7 @@ static int eb_receive_packet(AVCodecContext *avctx, 
AVPacket *pkt)
 pkt->size = headerPtr->n_filled_len;
 pkt->pts  = headerPtr->pts;
 pkt->dts  = headerPtr->dts;
+pkt->duration = headerPtr->n_tick_count;
 
 switch (headerPtr->pic_type) {
 case EB_AV1_KEY_PICTURE:

---

Summary of changes:
 libavcodec/libsvtav1.c | 2 ++
 1 file changed, 2 insertions(+)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 5cb6d2221a avformat/http: Handle IPv6 Zone ID in hostname

2025-09-24 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  5cb6d2221a6d4c07453b6c301ecfcaed48402680 (commit)
  from  56c14f231159d9a0dfa0a46661886c9baad870a6 (commit)


- Log -
commit 5cb6d2221a6d4c07453b6c301ecfcaed48402680
Author: Marvin Scholz 
AuthorDate: Thu May 22 20:14:49 2025 +0200
Commit: Marvin Scholz 
CommitDate: Wed Sep 24 12:03:13 2025 +

avformat/http: Handle IPv6 Zone ID in hostname

When using a literal IPv6 address as hostname, it can contain a Zone ID
especially in the case of link-local addresses. Sending this to the
server in the Host header is not useful to the server and in some cases
servers refuse such requests.

To prevent any such issues, strip the Zone ID from the address if it's
an IPv6 address. This also removes it for the Cookies lookup.

Based on a patch by: Daniel N Pettersson 

diff --git a/libavformat/http.c b/libavformat/http.c
index 0d4077512b..49d750b512 100644
--- a/libavformat/http.c
+++ b/libavformat/http.c
@@ -24,6 +24,7 @@
 #include "config.h"
 #include "config_components.h"
 
+#include 
 #include 
 #if CONFIG_ZLIB
 #include 
@@ -214,7 +215,7 @@ static int http_open_cnx_internal(URLContext *h, 
AVDictionary **options)
 const char *path, *proxy_path, *lower_proto = "tcp", *local_path;
 char *env_http_proxy, *env_no_proxy;
 char *hashmark;
-char hostname[1024], hoststr[1024], proto[10];
+char hostname[1024], hoststr[1024], proto[10], tmp_host[1024];
 char auth[1024], proxyauth[1024] = "";
 char path1[MAX_URL_SIZE], sanitized_path[MAX_URL_SIZE + 1];
 char buf[1024], urlbuf[MAX_URL_SIZE];
@@ -224,7 +225,14 @@ static int http_open_cnx_internal(URLContext *h, 
AVDictionary **options)
 av_url_split(proto, sizeof(proto), auth, sizeof(auth),
  hostname, sizeof(hostname), &port,
  path1, sizeof(path1), s->location);
-ff_url_join(hoststr, sizeof(hoststr), NULL, NULL, hostname, port, NULL);
+
+av_strlcpy(tmp_host, hostname, sizeof(tmp_host));
+// In case of an IPv6 address, we need to strip the Zone ID,
+// if any. We do it at the first % sign, as percent encoding
+// can be used in the Zone ID itself.
+if (strchr(tmp_host, ':'))
+tmp_host[strcspn(tmp_host, "%")] = '\0';
+ff_url_join(hoststr, sizeof(hoststr), NULL, NULL, tmp_host, port, NULL);
 
 env_http_proxy = getenv_utf8("http_proxy");
 proxy_path = s->http_proxy ? s->http_proxy : env_http_proxy;

---

Summary of changes:
 libavformat/http.c | 12 ++--
 1 file changed, 10 insertions(+), 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 17d5759bd9 avcodec/x86/apv_dsp: Don't export arrays unnecessarily

2025-09-23 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  17d5759bd99ab304c497ec149d493bc6ba1c6b52 (commit)
  from  f18b1e23890c1179d41c07f2c195c56fb90ea072 (commit)


- Log -
commit 17d5759bd99ab304c497ec149d493bc6ba1c6b52
Author: Andreas Rheinhardt 
AuthorDate: Wed Sep 24 00:10:08 2025 +0200
Commit: James Almer 
CommitDate: Wed Sep 24 01:21:32 2025 +

avcodec/x86/apv_dsp: Don't export arrays unnecessarily

The const here is unnecessary, because everything inside
SECTION_RODATA is automatically const and using it exports
these objects from the object file because const is a macro
in x86inc.asm.

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/x86/apv_dsp.asm b/libavcodec/x86/apv_dsp.asm
index 60e0f03e16..e2f30fff13 100644
--- a/libavcodec/x86/apv_dsp.asm
+++ b/libavcodec/x86/apv_dsp.asm
@@ -23,7 +23,7 @@
 SECTION_RODATA 32
 
 ; Full matrix for row transform.
-const tmatrix_row
+tmatrix_row:
 dw  64,  89,  84,  75,  64,  50,  35,  18
 dw  64, -18, -84,  50,  64, -75, -35,  89
 dw  64,  75,  35, -18, -64, -89, -84, -50
@@ -34,10 +34,10 @@ const tmatrix_row
 dw  64, -89,  84, -75,  64, -50,  35, -18
 
 ; Constant pairs for broadcast in column transform.
-const tmatrix_col_even
+tmatrix_col_even:
 dw  64,  64,  64, -64
 dw  84,  35,  35, -84
-const tmatrix_col_odd
+tmatrix_col_odd:
 dw  89,  75,  50,  18
 dw  75, -18, -89, -50
 dw  50, -89,  18,  75

---

Summary of changes:
 libavcodec/x86/apv_dsp.asm | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 56c14f2311 avcodec/libmpeghdec: add MPEG-H 3DA Fraunhofer IIS mpeghdec decoder

2025-09-23 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  56c14f231159d9a0dfa0a46661886c9baad870a6 (commit)
  from  e5f82ab8686b3c6193a3f718f53dbef9436b4318 (commit)


- Log -
commit 56c14f231159d9a0dfa0a46661886c9baad870a6
Author: Stadelmann, Daniel 
AuthorDate: Fri Aug 1 07:15:37 2025 +0200
Commit: Stadelmann, Daniel 
CommitDate: Wed Sep 24 08:25:42 2025 +0200

avcodec/libmpeghdec: add MPEG-H 3DA Fraunhofer IIS mpeghdec decoder

Adds a wrapper around the Fraunhofer IIS MPEG-H 3D Audio mpeghdec [1]
decoder shared library.

[1] https://github.com/Fraunhofer-IIS/mpeghdec

Signed-off-by: Stadelmann, Daniel 

diff --git a/Changelog b/Changelog
index 997ff3b0b6..6fd95c9136 100644
--- a/Changelog
+++ b/Changelog
@@ -6,6 +6,7 @@ version :
 - EXIF Metadata Parsing
 - gfxcapture: Windows.Graphics.Capture based window/monitor capture
 - hxvs demuxer for HXVS/HXVT IP camera format
+- MPEG-H 3D Audio decoding via mpeghdec
 
 
 version 8.0:
diff --git a/configure b/configure
index e5764a17a3..c4e16ff97e 100755
--- a/configure
+++ b/configure
@@ -250,6 +250,7 @@ External library support:
   --enable-liblensfun  enable lensfun lens correction [no]
   --enable-libmodplug  enable ModPlug via libmodplug [no]
   --enable-libmp3lame  enable MP3 encoding via libmp3lame [no]
+  --enable-libmpeghdec enable MPEG-H 3DA decoding via libmpeghdec [no]
   --enable-liboapv enable APV encoding via liboapv [no]
   --enable-libopencore-amrnb enable AMR-NB de/encoding via libopencore-amrnb 
[no]
   --enable-libopencore-amrwb enable AMR-WB decoding via libopencore-amrwb [no]
@@ -1926,6 +1927,7 @@ EXTERNAL_LIBRARY_GPL_LIST="
 EXTERNAL_LIBRARY_NONFREE_LIST="
 decklink
 libfdk_aac
+libmpeghdec
 libtls
 "
 
@@ -3673,6 +3675,7 @@ liblc3_encoder_select="audio_frame_queue"
 libmodplug_demuxer_deps="libmodplug"
 libmp3lame_encoder_deps="libmp3lame"
 libmp3lame_encoder_select="audio_frame_queue mpegaudioheader"
+libmpeghdec_decoder_deps="libmpeghdec"
 liboapv_encoder_deps="liboapv"
 libopencore_amrnb_decoder_deps="libopencore_amrnb"
 libopencore_amrnb_encoder_deps="libopencore_amrnb"
@@ -7184,6 +7187,7 @@ fi
 
 enabled libmodplug&& require_pkg_config libmodplug libmodplug 
libmodplug/modplug.h ModPlug_Load
 enabled libmp3lame&& require "libmp3lame >= 3.98.3" lame/lame.h 
lame_set_VBR_quality -lmp3lame $libm_extralibs
+enabled libmpeghdec   && require_pkg_config libmpeghdec "mpeghdec >= 
3.0.0" mpeghdec/mpeghdecoder.h mpeghdecoder_init
 enabled libmysofa && { check_pkg_config libmysofa libmysofa mysofa.h 
mysofa_neighborhood_init_withstepdefine ||
require libmysofa mysofa.h 
mysofa_neighborhood_init_withstepdefine -lmysofa $zlib_extralibs; }
 enabled libnpp&& { check_lib libnpp npp.h nppGetLibVersion -lnppig 
-lnppicc -lnppc -lnppidei -lnppif ||
diff --git a/doc/decoders.texi b/doc/decoders.texi
index 13eb40f4dd..b7d80ca3d7 100644
--- a/doc/decoders.texi
+++ b/doc/decoders.texi
@@ -356,6 +356,15 @@ value is 0 (disabled).
 
 @end table
 
+@section libmpeghdec
+
+libmpeghdec decoder wrapper.
+
+libmpeghdec allows libmpeghdec to decode the MPEG-H 3D audio codec.
+Requires the presence of the libmpeghdec headers and library during
+configuration. You need to explicitly configure the build with
+@code{--enable-libmpeghdec}.
+
 @section libopencore-amrnb
 
 libopencore-amrnb decoder wrapper.
diff --git a/doc/general_contents.texi b/doc/general_contents.texi
index b9dab580f1..9608ce219a 100644
--- a/doc/general_contents.texi
+++ b/doc/general_contents.texi
@@ -250,6 +250,14 @@ Go to @url{http://sourceforge.net/projects/opencore-amr/} 
and follow the
 instructions for installing the library.
 Then pass @code{--enable-libfdk-aac} to configure to enable it.
 
+@subsection Fraunhofer MPEG-H 3D Audio decoder library
+
+FFmpeg can make use of the Fraunhofer MPEG-H decoder library for MPEG-H 3DA 
decoding.
+
+Go to @url{https://github.com/Fraunhofer-IIS/mpeghdec} and follow the
+instructions for installing the library.
+Then pass @code{--enable-libmpeghdec} to configure to enable it.
+
 @subsection LC3 library
 
 FFmpeg can make use of the Google LC3 library for LC3 decoding & encoding.
@@ -1344,6 +1352,8 @@ following image formats are supported:
 @item MP3 (MPEG audio layer 3)  @tab  E  @tab IX
 @tab encoding supported through external library LAME, ADU MP3 and 
MP3onMP4 also supported
 @item MPEG-4 Audio Lossless Coding (ALS)  @tab @tab  X
+@item MPEG-H 3D Audio@tab @tab  E
+@tab decoding supported through external library libmpeghdec
 @item MobiClip FastAudio @tab @tab  X
 @item Musepack SV7   @tab @tab  X
 @item Musepack SV8   @tab @tab  X
diff --git a/libavcodec/Makefile b/libavcodec/Makefile
index ceac4e1159..e7fde87b22 100644
--- a/libavcodec/Makefile
+++ b/libavcodec/Makefile
@@ -1180,6 +1180,7

[FFmpeg-cvslog] [ffmpeg] branch master updated. 941eae01b1 avutil/attributes: prefer clang attributes even in non-gnu builds

2025-09-26 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  941eae01b1c4ed5d50eb5934e7df8a8a110e1699 (commit)
   via  b7ab357db43525542a6519a9438d9a0ae228d9a5 (commit)
   via  a7f0377a3df6e9a28dc02f21273ef4462049bb35 (commit)
   via  d6cb0d2c2bb8469f17d59dd82c8221b98e169d1a (commit)
  from  b9cc8e32109bba3daec1cfb6a834e45f72266b46 (commit)


- Log -
commit 941eae01b1c4ed5d50eb5934e7df8a8a110e1699
Author: Kacper Michajłow 
AuthorDate: Thu Sep 25 19:24:19 2025 +0200
Commit: Niklas Haas 
CommitDate: Fri Sep 26 16:15:46 2025 +

avutil/attributes: prefer clang attributes even in non-gnu builds

In MSVC mode Clang doesn't define __GNUC__, but we can still attributes.

Signed-off-by: Kacper Michajłow 

diff --git a/libavutil/attributes.h b/libavutil/attributes.h
index 993ec6e1da..772e327fa4 100644
--- a/libavutil/attributes.h
+++ b/libavutil/attributes.h
@@ -49,7 +49,7 @@
 #endif
 
 #ifndef av_always_inline
-#if AV_GCC_VERSION_AT_LEAST(3,1)
+#if AV_GCC_VERSION_AT_LEAST(3,1) || defined(__clang__)
 #define av_always_inline __attribute__((always_inline)) inline
 #elif defined(_MSC_VER)
 #define av_always_inline __forceinline
@@ -68,13 +68,13 @@
 
 #if AV_HAS_STD_ATTRIBUTE(nodiscard)
 #define av_warn_unused_result [[nodiscard]]
-#elif AV_GCC_VERSION_AT_LEAST(3,4)
+#elif AV_GCC_VERSION_AT_LEAST(3,4) || defined(__clang__)
 #define av_warn_unused_result __attribute__((warn_unused_result))
 #else
 #define av_warn_unused_result
 #endif
 
-#if AV_GCC_VERSION_AT_LEAST(3,1)
+#if AV_GCC_VERSION_AT_LEAST(3,1) || defined(__clang__)
 #define av_noinline __attribute__((noinline))
 #elif defined(_MSC_VER)
 #define av_noinline __declspec(noinline)
@@ -108,7 +108,7 @@
 
 #if AV_HAS_STD_ATTRIBUTE(deprecated)
 #define attribute_deprecated [[deprecated]]
-#elif AV_GCC_VERSION_AT_LEAST(3,1)
+#elif AV_GCC_VERSION_AT_LEAST(3,1) || defined(__clang__)
 #define attribute_deprecated __attribute__((deprecated))
 #elif defined(_MSC_VER)
 #define attribute_deprecated __declspec(deprecated)

commit b7ab357db43525542a6519a9438d9a0ae228d9a5
Author: Kacper Michajłow 
AuthorDate: Thu Sep 25 19:22:39 2025 +0200
Commit: Niklas Haas 
CommitDate: Fri Sep 26 16:15:46 2025 +

avutil/attributes: use standard attributes when they are available

Signed-off-by: Kacper Michajłow 

diff --git a/libavutil/attributes.h b/libavutil/attributes.h
index 2c08ea31bd..993ec6e1da 100644
--- a/libavutil/attributes.h
+++ b/libavutil/attributes.h
@@ -66,7 +66,9 @@
 #endif
 #endif
 
-#if AV_GCC_VERSION_AT_LEAST(3,4)
+#if AV_HAS_STD_ATTRIBUTE(nodiscard)
+#define av_warn_unused_result [[nodiscard]]
+#elif AV_GCC_VERSION_AT_LEAST(3,4)
 #define av_warn_unused_result __attribute__((warn_unused_result))
 #else
 #define av_warn_unused_result
@@ -104,7 +106,9 @@
 #define av_flatten
 #endif
 
-#if AV_GCC_VERSION_AT_LEAST(3,1)
+#if AV_HAS_STD_ATTRIBUTE(deprecated)
+#define attribute_deprecated [[deprecated]]
+#elif AV_GCC_VERSION_AT_LEAST(3,1)
 #define attribute_deprecated __attribute__((deprecated))
 #elif defined(_MSC_VER)
 #define attribute_deprecated __declspec(deprecated)
@@ -135,7 +139,9 @@
 #endif
 #endif
 
-#if defined(__GNUC__) || defined(__clang__)
+#if AV_HAS_STD_ATTRIBUTE(maybe_unused)
+#define av_unused [[maybe_unused]]
+#elif defined(__GNUC__) || defined(__clang__)
 #define av_unused __attribute__((unused))
 #else
 #define av_unused
@@ -174,7 +180,9 @@
 #define av_scanf_format(fmtpos, attrpos)
 #endif
 
-#if AV_GCC_VERSION_AT_LEAST(2,5) || defined(__clang__)
+#if AV_HAS_STD_ATTRIBUTE(noreturn)
+#define av_noreturn [[noreturn]]
+#elif AV_GCC_VERSION_AT_LEAST(2,5) || defined(__clang__)
 #define av_noreturn __attribute__((noreturn))
 #else
 #define av_noreturn

commit a7f0377a3df6e9a28dc02f21273ef4462049bb35
Author: Kacper Michajłow 
AuthorDate: Thu Sep 25 19:10:01 2025 +0200
Commit: Niklas Haas 
CommitDate: Fri Sep 26 16:15:46 2025 +

avutil/attributes: add AV_HAS_STD_ATTRIBUTE

For testing language standard attributes, for both C++ and C.

Signed-off-by: Kacper Michajłow 

diff --git a/libavutil/attributes.h b/libavutil/attributes.h
index d15ede1286..2c08ea31bd 100644
--- a/libavutil/attributes.h
+++ b/libavutil/attributes.h
@@ -40,6 +40,14 @@
 #define AV_HAS_BUILTIN(x) 0
 #endif
 
+#if defined(__cplusplus) && defined(__has_cpp_attribute)
+#define AV_HAS_STD_ATTRIBUTE(x) __has_cpp_attribute(x)
+#elif !defined(__cplusplus) && defined(__has_c_attribute)
+#define AV_HAS_STD_ATTRIBUTE(x) __has_c_attribute(x)
+#else
+#define AV_HAS_STD_ATTRIBUTE(x) 0
+#endif
+
 #ifndef av_always_inline
 #if AV_GCC_VERSION_AT_LEAST(3,1)
 #define av_always_inline __attribute__((always_inline)) inline

commit d6cb0d2c2bb8469f17d59dd82c8221b98e169d1a
Author: Kacper Michajłow 
AuthorDate: Thu Sep 25 19:31:17 2025 +0200
Co

[FFmpeg-cvslog] [ffmpeg] branch master updated. fa72f9a292 forgejo/workflows: include size and mtime in cache hash

2025-09-25 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  fa72f9a2921556923fa598317db4fcdc3c85ac24 (commit)
  from  f40766da45642cfe2783c188dacac3f81898ec23 (commit)


- Log -
commit fa72f9a2921556923fa598317db4fcdc3c85ac24
Author: Kacper Michajłow 
AuthorDate: Thu Sep 25 20:35:33 2025 +0200
Commit: Kacper Michajłow 
CommitDate: Thu Sep 25 21:51:03 2025 +0200

forgejo/workflows: include size and mtime in cache hash

In case some file has been updated. Generally fate samples shouldn't be
replaced to preserve compatibility with older revisions, but before
merge it may happen that files is replaced.

Signed-off-by: Kacper Michajłow 

diff --git a/.forgejo/workflows/test.yml b/.forgejo/workflows/test.yml
index 79c5238a8b..0499906575 100644
--- a/.forgejo/workflows/test.yml
+++ b/.forgejo/workflows/test.yml
@@ -39,7 +39,7 @@ jobs:
 id: fate
 run: |
   make fate-rsync SAMPLES=$PWD/fate-suite
-  echo "hash=$(find fate-suite -type f | sort | sha256sum | cut -d' ' 
-f1)" >> $FORGEJO_OUTPUT
+  echo "hash=$(find fate-suite -type f -printf "%P %s %T@\n" | sort | 
sha256sum | cut -d' ' -f1)" >> $FORGEJO_OUTPUT
   - name: Cache Fate-Suite
 uses: actions/cache/save@v4
 if: ${{ format('fate-suite-{0}', steps.fate.outputs.hash) != 
steps.cache.outputs.cache-matched-key }}

---

Summary of changes:
 .forgejo/workflows/test.yml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. f40766da45 configure: suppress C4267 warnings from MSVC

2025-09-25 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  f40766da45642cfe2783c188dacac3f81898ec23 (commit)
  from  2c8835dd72d70ef3e61f85695d8cf4e404779991 (commit)


- Log -
commit f40766da45642cfe2783c188dacac3f81898ec23
Author: Kacper Michajłow 
AuthorDate: Thu Sep 25 18:19:29 2025 +0200
Commit: Kacper Michajłow 
CommitDate: Thu Sep 25 18:02:44 2025 +

configure: suppress C4267 warnings from MSVC

Suppresses implicit integer conversion narrowing warnings:
warning C4267: 'initializing': conversion from 'size_t' to 'int', possible 
loss of data

Those implicit conversions are abundant in ffmpeg's code base.
Additionally equivalent warnings are not enabled for GCC/Clang by
default, so they are mostly left unfixed.

Suppress reports about them to reduce noise in MSVC build log.

Signed-off-by: Kacper Michajłow 

diff --git a/configure b/configure
index c4e16ff97e..a01f0fbba4 100755
--- a/configure
+++ b/configure
@@ -5020,7 +5020,7 @@ msvc_flags(){
 for flag; do
 case $flag in
 -Wall)echo -W3 -wd4018 -wd4146 -wd4244 -wd4305 
\
-   -wd4554 ;;
+   -wd4554 -wd4267 ;;
 -Wextra)  echo -W4 -wd4244 -wd4127 -wd4018 -wd4389 
\
-wd4146 -wd4057 -wd4204 -wd4706 -wd4305 
\
-wd4152 -wd4324 -we4013 -wd4100 -wd4214 
\

---

Summary of changes:
 configure | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 2c8835dd72 avcodec/libjxldec: submit frame after file is complete

2025-09-25 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  2c8835dd72d70ef3e61f85695d8cf4e404779991 (commit)
  from  9970dc32bf85628e53ed0952d87d384080d8976e (commit)


- Log -
commit 2c8835dd72d70ef3e61f85695d8cf4e404779991
Author: Leo Izen 
AuthorDate: Wed Aug 27 11:43:45 2025 -0400
Commit: Leo Izen 
CommitDate: Thu Sep 25 12:40:57 2025 -0400

avcodec/libjxldec: submit frame after file is complete

This commit causes the libjxl decoder wrapper to hold onto the decoded
frame until the trailing metadata after the frame is possibly complete
before it submits the frame. This allows EXIF and other metadata boxes
that occur after the frame is fully rendered to be attached to it as
side data.

Signed-off-by: Leo Izen 

diff --git a/libavcodec/libjxldec.c b/libavcodec/libjxldec.c
index 650cc6e5c0..a43437fb10 100644
--- a/libavcodec/libjxldec.c
+++ b/libavcodec/libjxldec.c
@@ -61,8 +61,11 @@ typedef struct LibJxlDecodeContext {
 int prev_is_last;
 AVRational anim_timebase;
 AVFrame *frame;
+int frame_complete;
+JxlDecoderStatus jret;
 AVBufferRef *exif;
 size_t exif_pos;
+int exif_box;
 } LibJxlDecodeContext;
 
 static int libjxl_init_jxl_decoder(AVCodecContext *avctx)
@@ -71,7 +74,7 @@ static int libjxl_init_jxl_decoder(AVCodecContext *avctx)
 
 ctx->events = JXL_DEC_BASIC_INFO | JXL_DEC_FULL_IMAGE
 | JXL_DEC_COLOR_ENCODING | JXL_DEC_FRAME
-| JXL_DEC_BOX | JXL_DEC_BOX_COMPLETE;
+| JXL_DEC_BOX;
 if (JxlDecoderSubscribeEvents(ctx->decoder, ctx->events) != 
JXL_DEC_SUCCESS) {
 av_log(avctx, AV_LOG_ERROR, "Error subscribing to JXL events\n");
 return AVERROR_EXTERNAL;
@@ -371,10 +374,62 @@ static int libjxl_color_encoding_event(AVCodecContext 
*avctx, AVFrame *frame)
 return 0;
 }
 
+static int libjxl_attach_sidedata(AVCodecContext *avctx)
+{
+LibJxlDecodeContext *ctx = avctx->priv_data;
+int ret = 0;
+
+if (ctx->iccp) {
+ret = ff_frame_new_side_data_from_buf(avctx, ctx->frame, 
AV_FRAME_DATA_ICC_PROFILE, &ctx->iccp);
+if (ret < 0)
+return ret;
+}
+
+if (ctx->exif) {
+AVExifMetadata ifd = { 0 };
+/* size may be larger than exif_pos due to the realloc loop */
+ret = av_exif_parse_buffer(avctx, ctx->exif->data, ctx->exif_pos, 
&ifd, AV_EXIF_T_OFF);
+av_buffer_unref(&ctx->exif);
+if (ret < 0) {
+av_log(avctx, AV_LOG_ERROR, "Unable to parse EXIF buffer: %s\n", 
av_err2str(ret));
+return ret;
+}
+/*
+ * JPEG XL Codestream orientation overrides EXIF orientation in all 
cases.
+ * As a result, we remove the EXIF Orientation tag rather than just 
zeroing it
+ * in order to prevent any ambiguity. libjxl autorotates the image for 
us so we
+ * do not need to worry about that.
+ */
+ret = av_exif_remove_entry(avctx, &ifd, 
av_exif_get_tag_id("Orientation"), 0);
+if (ret < 0)
+av_log(avctx, AV_LOG_WARNING, "Unable to remove orientation from 
EXIF buffer: %s\n", av_err2str(ret));
+ret = ff_decode_exif_attach_ifd(avctx, ctx->frame, &ifd);
+if (ret < 0)
+av_log(avctx, AV_LOG_ERROR, "Unable to attach EXIF ifd: %s\n", 
av_err2str(ret));
+av_exif_free(&ifd);
+}
+
+return ret;
+}
+
+static int libjxl_finalize_frame(AVCodecContext *avctx, AVFrame *dst, AVFrame 
*src)
+{
+LibJxlDecodeContext *ctx = avctx->priv_data;
+if (ctx->exif_box) {
+/* last box was Exif */
+size_t remainder = JxlDecoderReleaseBoxBuffer(ctx->decoder);
+ctx->exif_pos = ctx->exif->size - remainder;
+ctx->exif_box = 0;
+}
+int ret = libjxl_attach_sidedata(avctx);
+av_frame_move_ref(dst, src);
+ctx->frame_complete = 0;
+return ret;
+}
+
 static int libjxl_receive_frame(AVCodecContext *avctx, AVFrame *frame)
 {
 LibJxlDecodeContext *ctx = avctx->priv_data;
-JxlDecoderStatus jret = JXL_DEC_SUCCESS;
 int ret;
 AVPacket *pkt = ctx->avpkt;
 
@@ -391,23 +446,26 @@ static int libjxl_receive_frame(AVCodecContext *avctx, 
AVFrame *frame)
 ctx->frame_duration = 0;
 if (!pkt->size) {
 /* jret set by the last iteration of the loop */
-if (jret == JXL_DEC_NEED_MORE_INPUT) {
+if (ctx->jret == JXL_DEC_NEED_MORE_INPUT && 
!ctx->frame_complete) {
 av_log(avctx, AV_LOG_ERROR, "Unexpected end of JXL 
codestream\n");
 return AVERROR_INVALIDDATA;
-} else {
-return AVERROR_EOF;
+} else if (ctx->frame_complete) {
+libjxl_finalize_frame(avctx, frame, ctx->frame);
+ctx->jret = JXL_DEC_SUCCESS;
+return 0;
 }
+return AVERROR_EOF;
 }

[FFmpeg-cvslog] [ffmpeg] branch master updated. 635cb4543f avcodec/bsf/ahx_to_mp2: Don't output uninitialized data

2025-09-27 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  635cb4543f1bb08b645740406077dad845d5d7d4 (commit)
  from  8a34faa250fad7dc05aa9a554b4aaafd9e7425e7 (commit)


- Log -
commit 635cb4543f1bb08b645740406077dad845d5d7d4
Author: Andreas Rheinhardt 
AuthorDate: Wed Sep 24 04:34:47 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Sat Sep 27 17:57:15 2025 +0200

avcodec/bsf/ahx_to_mp2: Don't output uninitialized data

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/bsf/ahx_to_mp2.c b/libavcodec/bsf/ahx_to_mp2.c
index eae71fe5ee..8e30c5b1db 100644
--- a/libavcodec/bsf/ahx_to_mp2.c
+++ b/libavcodec/bsf/ahx_to_mp2.c
@@ -44,11 +44,13 @@ static int filter(AVBSFContext *ctx, AVPacket *pkt)
 return ret;
 
 if (pkt->size < 1044) {
+int original_size = pkt->size;
 ret = av_grow_packet(pkt, 1044-pkt->size);
 if (ret < 0) {
 av_packet_unref(pkt);
 return ret;
 }
+memset(pkt->data + original_size, 0, 1044 - original_size);
 }
 
 return 0;

---

Summary of changes:
 libavcodec/bsf/ahx_to_mp2.c | 2 ++
 1 file changed, 2 insertions(+)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 188440929d avcodec/libmpeghdec: Check channel layouts generically

2025-09-25 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  188440929d3fdc7ae40b119acbc151054afce53f (commit)
   via  ca7679c82f8aa5fe3c7d00455e79b576bc72e3fe (commit)
   via  7cd0641a9912e5c3cdf718faf26404285dc1ff2a (commit)
   via  0ec21ea8d09d991d3e7f767f0dfadc2e0af75655 (commit)
   via  f46bd4add2ed0129ad71d654c85f2cc84bc1a4d4 (commit)
   via  60b88e75e42941d7142e4ed5e94a6886d5dd6e08 (commit)
   via  a98f75d22c37e20f55f0b4566e4b436cbc515a91 (commit)
   via  839042b0c0fce43c96ca1d09bdb78e40b1a3b1d4 (commit)
   via  b8f341ff058d78df201c04f1725727024e31c16e (commit)
  from  6d8732f397bfb07f2292e15a61904665abe13ce3 (commit)


- Log -
commit 188440929d3fdc7ae40b119acbc151054afce53f
Author: Andreas Rheinhardt 
AuthorDate: Wed Sep 24 18:07:10 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Fri Sep 26 05:38:46 2025 +0200

avcodec/libmpeghdec: Check channel layouts generically

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/libmpeghdec.c b/libavcodec/libmpeghdec.c
index 527627ba16..ecc3a2dc09 100644
--- a/libavcodec/libmpeghdec.c
+++ b/libavcodec/libmpeghdec.c
@@ -68,75 +68,36 @@ static av_cold int mpegh3dadec_close(AVCodecContext *avctx)
 // 
https://github.com/Fraunhofer-IIS/mpeghdec/wiki/MPEG-H-decoder-target-layouts
 static av_cold int channel_layout_to_cicp(const AVChannelLayout *layout)
 {
-const AVChannelLayout layout_7point2point3 =
-(AVChannelLayout) AV_CHANNEL_LAYOUT_MASK(
-12, (AV_CH_LAYOUT_5POINT1POINT2 | AV_CH_SIDE_SURROUND_LEFT |
- AV_CH_SIDE_SURROUND_RIGHT | AV_CH_TOP_BACK_CENTER |
- AV_CH_LOW_FREQUENCY_2));
-const AVChannelLayout layout_5point1point6 =
-(AVChannelLayout) AV_CHANNEL_LAYOUT_MASK(
-12, (AV_CH_LAYOUT_5POINT1POINT4_BACK | AV_CH_TOP_FRONT_CENTER |
- AV_CH_TOP_CENTER));
-const AVChannelLayout layout_7point1point6 =
-(AVChannelLayout) AV_CHANNEL_LAYOUT_MASK(
-14, (AV_CH_LAYOUT_7POINT1POINT4_BACK | AV_CH_TOP_FRONT_CENTER |
- AV_CH_TOP_CENTER));
-
-if (!av_channel_layout_compare(layout,
-   &(AVChannelLayout) AV_CHANNEL_LAYOUT_MONO)) 
{
-return 1;
-} else if (!av_channel_layout_compare(
-   layout, &(AVChannelLayout) AV_CHANNEL_LAYOUT_STEREO)) {
-return 2;
-} else if (!av_channel_layout_compare(
-   layout, &(AVChannelLayout) AV_CHANNEL_LAYOUT_SURROUND)) {
-return 3;
-} else if (!av_channel_layout_compare(
-   layout, &(AVChannelLayout) AV_CHANNEL_LAYOUT_4POINT0)) {
-return 4;
-} else if (!av_channel_layout_compare(
-   layout, &(AVChannelLayout) AV_CHANNEL_LAYOUT_5POINT0)) {
-return 5;
-} else if (!av_channel_layout_compare(
-   layout, &(AVChannelLayout) AV_CHANNEL_LAYOUT_5POINT1)) {
-return 6;
-} else if (!av_channel_layout_compare(
-   layout, &(AVChannelLayout) AV_CHANNEL_LAYOUT_7POINT1_WIDE)) 
{
-return 7;
-} else if (!av_channel_layout_compare(
-   layout, &(AVChannelLayout) AV_CHANNEL_LAYOUT_2_1)) {
-return 9;
-} else if (!av_channel_layout_compare(
-   layout, &(AVChannelLayout) AV_CHANNEL_LAYOUT_2_2)) {
-return 10;
-} else if (!av_channel_layout_compare(
-   layout, &(AVChannelLayout) AV_CHANNEL_LAYOUT_6POINT1)) {
-return 11;
-} else if (!av_channel_layout_compare(
-   layout, &(AVChannelLayout) AV_CHANNEL_LAYOUT_7POINT1)) {
-return 12;
-} else if (!av_channel_layout_compare(
-   layout, &(AVChannelLayout) AV_CHANNEL_LAYOUT_22POINT2)) {
-return 13;
-} else if (!av_channel_layout_compare(
-   layout,
-   &(AVChannelLayout) AV_CHANNEL_LAYOUT_5POINT1POINT2)) {
-return 14;
-} else if (!av_channel_layout_compare(layout, &layout_7point2point3)) {
-return 15;
-} else if (!av_channel_layout_compare(
-   layout,
-   &(AVChannelLayout) AV_CHANNEL_LAYOUT_5POINT1POINT4_BACK)) {
-return 16;
-} else if (!av_channel_layout_compare(layout, &layout_5point1point6)) {
-return 17;
-} else if (!av_channel_layout_compare(layout, &layout_7point1point6)) {
-return 18;
-} else if (!av_channel_layout_compare(
-   layout,
-   &(AVChannelLayout) AV_CHANNEL_LAYOUT_7POINT1POINT4_BACK)) {
-return 19;
+// different from AV_CH_LAYOUT_7POINT2POINT3
+#define CH_LAYOUT_7POINT2POINT3 AV_CH_LAYOUT_5POINT1POINT2 | 
AV_CH_SIDE_SURROUND_LEFT | \
+AV_CH_SIDE_SURROUND_RIGHT | 
AV_CH_TOP_BACK_CENTER | \
+AV_CH_LOW_FREQUENCY_2
+#define CH_LAYOUT_5POINT1POINT6 AV_CH_LAYOUT_5POINT1POINT4_BACK 

[FFmpeg-cvslog] [ffmpeg] branch master updated. baace56169 avfilter/vf_tonemap_opencl: Make array smaller

2025-09-25 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  baace56169a8cea7b44d727bdf656110aace011d (commit)
   via  f0586ffa95127b3370850e3981f48c7057bd2ab8 (commit)
  from  188440929d3fdc7ae40b119acbc151054afce53f (commit)


- Log -
commit baace56169a8cea7b44d727bdf656110aace011d
Author: Andreas Rheinhardt 
AuthorDate: Mon Sep 22 15:00:32 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Fri Sep 26 06:00:43 2025 +0200

avfilter/vf_tonemap_opencl: Make array smaller

Also makes the code more independent of AVCOL_TRC_NB.

Reviewed-by: Niklas Haas 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavfilter/vf_tonemap_opencl.c b/libavfilter/vf_tonemap_opencl.c
index 26fc02923c..2c1b0a007d 100644
--- a/libavfilter/vf_tonemap_opencl.c
+++ b/libavfilter/vf_tonemap_opencl.c
@@ -70,12 +70,12 @@ typedef struct TonemapOpenCLContext {
 cl_memutil_mem;
 } TonemapOpenCLContext;
 
-static const char *const linearize_funcs[AVCOL_TRC_NB] = {
+static const char *const linearize_funcs[] = {
 [AVCOL_TRC_SMPTE2084] = "eotf_st2084",
 [AVCOL_TRC_ARIB_STD_B67] = "inverse_oetf_hlg",
 };
 
-static const char *const delinearize_funcs[AVCOL_TRC_NB] = {
+static const char *const delinearize_funcs[] = {
 [AVCOL_TRC_BT709] = "inverse_eotf_bt1886",
 [AVCOL_TRC_BT2020_10] = "inverse_eotf_bt1886",
 };

commit f0586ffa95127b3370850e3981f48c7057bd2ab8
Author: Andreas Rheinhardt 
AuthorDate: Mon Sep 22 14:40:24 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Fri Sep 26 06:00:14 2025 +0200

avfilter/vf_colorspace: Make array smaller

Also makes it more independent of AVCOL_TRC_NB.

Reviewed-by: Niklas Haas 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavfilter/vf_colorspace.c b/libavfilter/vf_colorspace.c
index f919350d65..52e84abbe1 100644
--- a/libavfilter/vf_colorspace.c
+++ b/libavfilter/vf_colorspace.c
@@ -171,7 +171,7 @@ typedef struct ColorSpaceContext {
 // FIXME I'm pretty sure gamma22/28 also have a linear toe slope, but I can't
 // find any actual tables that document their real values...
 // See http://www.13thmonkey.org/~boris/gammacorrection/ first graph why it 
matters
-static const struct TransferCharacteristics 
transfer_characteristics[AVCOL_TRC_NB] = {
+static const struct TransferCharacteristics transfer_characteristics[] = {
 [AVCOL_TRC_BT709] = { 1.099,  0.018,  0.45, 4.5 },
 [AVCOL_TRC_GAMMA22]   = { 1.0,0.0,1.0 / 2.2, 0.0 },
 [AVCOL_TRC_GAMMA28]   = { 1.0,0.0,1.0 / 2.8, 0.0 },
@@ -189,7 +189,7 @@ static const struct TransferCharacteristics *
 {
 const struct TransferCharacteristics *coeffs;
 
-if (trc >= AVCOL_TRC_NB)
+if ((unsigned)trc >= FF_ARRAY_ELEMS(transfer_characteristics))
 return NULL;
 coeffs = &transfer_characteristics[trc];
 if (!coeffs->alpha)

---

Summary of changes:
 libavfilter/vf_colorspace.c | 4 ++--
 libavfilter/vf_tonemap_opencl.c | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch release/7.1 updated. 8320e6b415 libavutil/arm: Rename the HWCAP defines

2025-09-24 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, release/7.1 has been updated
   via  8320e6b4155d4488e3ed2665a05d2b2f389fa20d (commit)
   via  a337e8f86a9c2c9740da6a9960a5cb855c109c6b (commit)
  from  ab0545969279dc832d431500be11f61e3dadcf91 (commit)


- Log -
commit 8320e6b4155d4488e3ed2665a05d2b2f389fa20d
Author: Brad Smith 
AuthorDate: Mon Sep 22 07:28:21 2025 -0400
Commit: Brad Smith 
CommitDate: Wed Sep 24 19:59:47 2025 -0400

libavutil/arm: Rename the HWCAP defines

Rename the HWCAP defines to use the same naming scheme as AArch64 and PPC.

(cherry picked from commit ced4a6ebc9e7cd92d0ca9b9fb8f9d1013d23cbfa)
Signed-off-by: Brad Smith 

diff --git a/libavutil/arm/cpu.c b/libavutil/arm/cpu.c
index 8ec28143d7..2e2977efc9 100644
--- a/libavutil/arm/cpu.c
+++ b/libavutil/arm/cpu.c
@@ -47,12 +47,12 @@
 #endif
 
 /* Relevant HWCAP values from kernel headers */
-#define HWCAP_VFP   (1 << 6)
-#define HWCAP_EDSP  (1 << 7)
-#define HWCAP_THUMBEE   (1 << 11)
-#define HWCAP_NEON  (1 << 12)
-#define HWCAP_VFPv3 (1 << 13)
-#define HWCAP_TLS   (1 << 15)
+#define HWCAP_ARM_VFP (1 << 6)
+#define HWCAP_ARM_EDSP(1 << 7)
+#define HWCAP_ARM_THUMBEE (1 << 11)
+#define HWCAP_ARM_NEON(1 << 12)
+#define HWCAP_ARM_VFPv3   (1 << 13)
+#define HWCAP_ARM_TLS (1 << 15)
 
 static int get_auxval(uint32_t *hwcap)
 {
@@ -101,19 +101,19 @@ static int get_cpuinfo(uint32_t *hwcap)
 while (fgets(buf, sizeof(buf), f)) {
 if (av_strstart(buf, "Features", NULL)) {
 if (strstr(buf, " edsp "))
-*hwcap |= HWCAP_EDSP;
+*hwcap |= HWCAP_ARM_EDSP;
 if (strstr(buf, " tls "))
-*hwcap |= HWCAP_TLS;
+*hwcap |= HWCAP_ARM_TLS;
 if (strstr(buf, " thumbee "))
-*hwcap |= HWCAP_THUMBEE;
+*hwcap |= HWCAP_ARM_THUMBEE;
 if (strstr(buf, " vfp "))
-*hwcap |= HWCAP_VFP;
+*hwcap |= HWCAP_ARM_VFP;
 if (strstr(buf, " vfpv3 "))
-*hwcap |= HWCAP_VFPv3;
+*hwcap |= HWCAP_ARM_VFPv3;
 if (strstr(buf, " neon ") || strstr(buf, " asimd "))
-*hwcap |= HWCAP_NEON;
+*hwcap |= HWCAP_ARM_NEON;
 if (strstr(buf, " fp ")) // Listed on 64 bit ARMv8 kernels
-*hwcap |= HWCAP_VFP | HWCAP_VFPv3;
+*hwcap |= HWCAP_ARM_VFP | HWCAP_ARM_VFPv3;
 break;
 }
 }
@@ -135,7 +135,7 @@ int ff_get_cpu_flags_arm(void)
 return flags;
 
 #define check_cap(cap, flag) do {   \
-if (hwcap & HWCAP_ ## cap)  \
+if (hwcap & HWCAP_ARM_ ## cap)  \
 flags |= AV_CPU_FLAG_ ## flag;  \
 } while (0)
 

commit a337e8f86a9c2c9740da6a9960a5cb855c109c6b
Author: Brad Smith 
AuthorDate: Sat Sep 20 23:06:08 2025 -0400
Commit: Brad Smith 
CommitDate: Wed Sep 24 19:58:39 2025 -0400

libavutil/arm: Make use of elf_aux_info() on FreeBSD/OpenBSD

- FreBSD/OpenBSD have elf_aux_info() on arm
- Wrap AT_HWCAP as the value is different for BSD vs Linux (16 vs 25)

(cherry picked from commit cdae5c3639f4adcd289e643a203d43d4e01d87f5)
Signed-off-by: Brad Smith 

diff --git a/libavutil/arm/cpu.c b/libavutil/arm/cpu.c
index b84882005a..8ec28143d7 100644
--- a/libavutil/arm/cpu.c
+++ b/libavutil/arm/cpu.c
@@ -31,18 +31,20 @@
  CORE_FLAG(VFPV3)   |   \
  CORE_FLAG(NEON))
 
-#if defined __linux__ || defined __ANDROID__
+#if defined __linux__ || defined __ANDROID__ || HAVE_ELF_AUX_INFO
 
 #include 
 #include 
 #include 
 #include "libavutil/avstring.h"
 
-#if HAVE_GETAUXVAL
+#if HAVE_GETAUXVAL || HAVE_ELF_AUX_INFO
 #include 
 #endif
 
+#ifndef AT_HWCAP
 #define AT_HWCAP16
+#endif
 
 /* Relevant HWCAP values from kernel headers */
 #define HWCAP_VFP   (1 << 6)
@@ -54,7 +56,7 @@
 
 static int get_auxval(uint32_t *hwcap)
 {
-#if HAVE_GETAUXVAL
+#if HAVE_GETAUXVAL || HAVE_ELF_AUX_INFO
 unsigned long ret = ff_getauxval(AT_HWCAP);
 if (ret == 0)
 return -1;
@@ -65,6 +67,7 @@ static int get_auxval(uint32_t *hwcap)
 #endif
 }
 
+#if defined __linux__ || defined __ANDROID__
 static int get_hwcap(uint32_t *hwcap)
 {
 struct { uint32_t a_type; uint32_t a_val; } auxv;
@@ -117,6 +120,7 @@ static int get_cpuinfo(uint32_t *hwcap)
 fclose(f);
 return 0;
 }
+#endif
 
 int ff_get_cpu_flags_arm(void)
 {
@@ -124,8 +128,10 @@ int ff_get_cpu_flags_arm(void)
 uint32_t hwcap;
 
 if (get_auxval(&hwcap) < 0)
+#if defined __linux__ || defined __ANDROID__
 if (get_hwcap(&hwcap) < 0)
 if (get_cpuinfo(&hwcap) < 0)
+#endif
 return flags;
 
 #define check_cap(cap, flag) do {   \

---

Summary of changes:
 libavutil/arm/cpu.c | 

[FFmpeg-cvslog] [ffmpeg] branch master updated. cb5dbb30ca avcodec/tiff_common: Remove unused ff_tadd_*_metadata() funcs

2025-09-24 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  cb5dbb30caeb9b44897251892350f0e8297b9437 (commit)
  from  371931250a2b8d9cf2a726d4992f9107af3df782 (commit)


- Log -
commit cb5dbb30caeb9b44897251892350f0e8297b9437
Author: Andreas Rheinhardt 
AuthorDate: Wed Sep 24 05:01:04 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Thu Sep 25 06:47:30 2025 +0200

avcodec/tiff_common: Remove unused ff_tadd_*_metadata() funcs

Unused since ad77345a5d14862f4701e5ad422b03b14934a5b9.

Reviewed-by: Leo Izen 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/tiff_common.c b/libavcodec/tiff_common.c
index ee8061944b..265f843031 100644
--- a/libavcodec/tiff_common.c
+++ b/libavcodec/tiff_common.c
@@ -97,51 +97,6 @@ static int bprint_to_avdict(AVBPrint *bp, const char *name,
 return av_dict_set(metadata, name, ap, AV_DICT_DONT_STRDUP_VAL);
 }
 
-int ff_tadd_rational_metadata(int count, const char *name, const char *sep,
-  GetByteContext *gb, int le, AVDictionary 
**metadata)
-{
-AVBPrint bp;
-int32_t nom, denom;
-int i;
-
-if (count >= INT_MAX / sizeof(int64_t) || count <= 0)
-return AVERROR_INVALIDDATA;
-if (bytestream2_get_bytes_left(gb) < count * sizeof(int64_t))
-return AVERROR_INVALIDDATA;
-
-av_bprint_init(&bp, 10 * count, AV_BPRINT_SIZE_UNLIMITED);
-
-for (i = 0; i < count; i++) {
-nom   = ff_tget_long(gb, le);
-denom = ff_tget_long(gb, le);
-av_bprintf(&bp, "%s%7"PRId32":%-7"PRId32, auto_sep(count, sep, i, 4), 
nom, denom);
-}
-
-return bprint_to_avdict(&bp, name, metadata);
-}
-
-
-int ff_tadd_long_metadata(int count, const char *name, const char *sep,
-  GetByteContext *gb, int le, AVDictionary **metadata)
-{
-AVBPrint bp;
-int i;
-
-if (count >= INT_MAX / sizeof(int32_t) || count <= 0)
-return AVERROR_INVALIDDATA;
-if (bytestream2_get_bytes_left(gb) < count * sizeof(int32_t))
-return AVERROR_INVALIDDATA;
-
-av_bprint_init(&bp, 10 * count, AV_BPRINT_SIZE_UNLIMITED);
-
-for (i = 0; i < count; i++) {
-av_bprintf(&bp, "%s%7i", auto_sep(count, sep, i, 8), ff_tget_long(gb, 
le));
-}
-
-return bprint_to_avdict(&bp, name, metadata);
-}
-
-
 int ff_tadd_doubles_metadata(int count, const char *name, const char *sep,
  GetByteContext *gb, int le, AVDictionary 
**metadata)
 {
@@ -184,28 +139,6 @@ int ff_tadd_shorts_metadata(int count, const char *name, 
const char *sep,
 return bprint_to_avdict(&bp, name, metadata);
 }
 
-
-int ff_tadd_bytes_metadata(int count, const char *name, const char *sep,
-   GetByteContext *gb, int le, int is_signed, 
AVDictionary **metadata)
-{
-AVBPrint bp;
-int i;
-
-if (count >= INT_MAX / sizeof(int8_t) || count < 0)
-return AVERROR_INVALIDDATA;
-if (bytestream2_get_bytes_left(gb) < count * sizeof(int8_t))
-return AVERROR_INVALIDDATA;
-
-av_bprint_init(&bp, 10 * count, AV_BPRINT_SIZE_UNLIMITED);
-
-for (i = 0; i < count; i++) {
-int v = is_signed ? (int8_t)bytestream2_get_byte(gb) :  
bytestream2_get_byte(gb);
-av_bprintf(&bp, "%s%3i", auto_sep(count, sep, i, 16), v);
-}
-
-return bprint_to_avdict(&bp, name, metadata);
-}
-
 int ff_tadd_string_metadata(int count, const char *name,
 GetByteContext *gb, int le, AVDictionary 
**metadata)
 {
diff --git a/libavcodec/tiff_common.h b/libavcodec/tiff_common.h
index 11f2e739a4..67f23bd4fa 100644
--- a/libavcodec/tiff_common.h
+++ b/libavcodec/tiff_common.h
@@ -62,18 +62,6 @@ double   ff_tget_double(GetByteContext *gb, int le);
 /** Reads a byte from the bytestream using given endianness. */
 unsigned ff_tget(GetByteContext *gb, int type, int le);
 
-/** Adds count rationals converted to a string
- *  into the metadata dictionary.
- */
-int ff_tadd_rational_metadata(int count, const char *name, const char *sep,
-  GetByteContext *gb, int le, AVDictionary 
**metadata);
-
-/** Adds count longs converted to a string
- *  into the metadata dictionary.
- */
-int ff_tadd_long_metadata(int count, const char *name, const char *sep,
-  GetByteContext *gb, int le, AVDictionary **metadata);
-
 /** Adds count doubles converted to a string
  *  into the metadata dictionary.
  */
@@ -86,12 +74,6 @@ int ff_tadd_doubles_metadata(int count, const char *name, 
const char *sep,
 int ff_tadd_shorts_metadata(int count, const char *name, const char *sep,
 GetByteContext *gb, int le, int is_signed, 
AVDictionary **metadata);
 
-/** Adds count bytes converted to a string
- *  into the metadata dictionary.
- */
-int ff_tadd_bytes_metadata(int count, const char *name, const char *sep,
-   GetByteContext *gb, int le, int is_signed, 
AVDictiona

[FFmpeg-cvslog] [ffmpeg] branch release/8.0 updated. d8605a6b55 libavutil/arm: Rename the HWCAP defines

2025-09-24 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, release/8.0 has been updated
   via  d8605a6b5549887edcca69c1ba0400fe14e0de3d (commit)
   via  c9b8e5999b5aae485917ecf7ec90b01ccbdd747d (commit)
  from  b9adbf0fcc26e04a0f291c9f8857affb4540a6e3 (commit)


- Log -
commit d8605a6b5549887edcca69c1ba0400fe14e0de3d
Author: Brad Smith 
AuthorDate: Mon Sep 22 07:28:21 2025 -0400
Commit: Brad Smith 
CommitDate: Wed Sep 24 19:55:16 2025 -0400

libavutil/arm: Rename the HWCAP defines

Rename the HWCAP defines to use the same naming scheme as AArch64 and PPC.

(cherry picked from commit ced4a6ebc9e7cd92d0ca9b9fb8f9d1013d23cbfa)
Signed-off-by: Brad Smith 

diff --git a/libavutil/arm/cpu.c b/libavutil/arm/cpu.c
index 8ec28143d7..2e2977efc9 100644
--- a/libavutil/arm/cpu.c
+++ b/libavutil/arm/cpu.c
@@ -47,12 +47,12 @@
 #endif
 
 /* Relevant HWCAP values from kernel headers */
-#define HWCAP_VFP   (1 << 6)
-#define HWCAP_EDSP  (1 << 7)
-#define HWCAP_THUMBEE   (1 << 11)
-#define HWCAP_NEON  (1 << 12)
-#define HWCAP_VFPv3 (1 << 13)
-#define HWCAP_TLS   (1 << 15)
+#define HWCAP_ARM_VFP (1 << 6)
+#define HWCAP_ARM_EDSP(1 << 7)
+#define HWCAP_ARM_THUMBEE (1 << 11)
+#define HWCAP_ARM_NEON(1 << 12)
+#define HWCAP_ARM_VFPv3   (1 << 13)
+#define HWCAP_ARM_TLS (1 << 15)
 
 static int get_auxval(uint32_t *hwcap)
 {
@@ -101,19 +101,19 @@ static int get_cpuinfo(uint32_t *hwcap)
 while (fgets(buf, sizeof(buf), f)) {
 if (av_strstart(buf, "Features", NULL)) {
 if (strstr(buf, " edsp "))
-*hwcap |= HWCAP_EDSP;
+*hwcap |= HWCAP_ARM_EDSP;
 if (strstr(buf, " tls "))
-*hwcap |= HWCAP_TLS;
+*hwcap |= HWCAP_ARM_TLS;
 if (strstr(buf, " thumbee "))
-*hwcap |= HWCAP_THUMBEE;
+*hwcap |= HWCAP_ARM_THUMBEE;
 if (strstr(buf, " vfp "))
-*hwcap |= HWCAP_VFP;
+*hwcap |= HWCAP_ARM_VFP;
 if (strstr(buf, " vfpv3 "))
-*hwcap |= HWCAP_VFPv3;
+*hwcap |= HWCAP_ARM_VFPv3;
 if (strstr(buf, " neon ") || strstr(buf, " asimd "))
-*hwcap |= HWCAP_NEON;
+*hwcap |= HWCAP_ARM_NEON;
 if (strstr(buf, " fp ")) // Listed on 64 bit ARMv8 kernels
-*hwcap |= HWCAP_VFP | HWCAP_VFPv3;
+*hwcap |= HWCAP_ARM_VFP | HWCAP_ARM_VFPv3;
 break;
 }
 }
@@ -135,7 +135,7 @@ int ff_get_cpu_flags_arm(void)
 return flags;
 
 #define check_cap(cap, flag) do {   \
-if (hwcap & HWCAP_ ## cap)  \
+if (hwcap & HWCAP_ARM_ ## cap)  \
 flags |= AV_CPU_FLAG_ ## flag;  \
 } while (0)
 

commit c9b8e5999b5aae485917ecf7ec90b01ccbdd747d
Author: Brad Smith 
AuthorDate: Sat Sep 20 23:06:08 2025 -0400
Commit: Brad Smith 
CommitDate: Wed Sep 24 19:53:04 2025 -0400

libavutil/arm: Make use of elf_aux_info() on FreeBSD/OpenBSD

- FreBSD/OpenBSD have elf_aux_info() on arm
- Wrap AT_HWCAP as the value is different for BSD vs Linux (16 vs 25)

(cherry picked from commit cdae5c3639f4adcd289e643a203d43d4e01d87f5)
Signed-off-by: Brad Smith 

diff --git a/libavutil/arm/cpu.c b/libavutil/arm/cpu.c
index b84882005a..8ec28143d7 100644
--- a/libavutil/arm/cpu.c
+++ b/libavutil/arm/cpu.c
@@ -31,18 +31,20 @@
  CORE_FLAG(VFPV3)   |   \
  CORE_FLAG(NEON))
 
-#if defined __linux__ || defined __ANDROID__
+#if defined __linux__ || defined __ANDROID__ || HAVE_ELF_AUX_INFO
 
 #include 
 #include 
 #include 
 #include "libavutil/avstring.h"
 
-#if HAVE_GETAUXVAL
+#if HAVE_GETAUXVAL || HAVE_ELF_AUX_INFO
 #include 
 #endif
 
+#ifndef AT_HWCAP
 #define AT_HWCAP16
+#endif
 
 /* Relevant HWCAP values from kernel headers */
 #define HWCAP_VFP   (1 << 6)
@@ -54,7 +56,7 @@
 
 static int get_auxval(uint32_t *hwcap)
 {
-#if HAVE_GETAUXVAL
+#if HAVE_GETAUXVAL || HAVE_ELF_AUX_INFO
 unsigned long ret = ff_getauxval(AT_HWCAP);
 if (ret == 0)
 return -1;
@@ -65,6 +67,7 @@ static int get_auxval(uint32_t *hwcap)
 #endif
 }
 
+#if defined __linux__ || defined __ANDROID__
 static int get_hwcap(uint32_t *hwcap)
 {
 struct { uint32_t a_type; uint32_t a_val; } auxv;
@@ -117,6 +120,7 @@ static int get_cpuinfo(uint32_t *hwcap)
 fclose(f);
 return 0;
 }
+#endif
 
 int ff_get_cpu_flags_arm(void)
 {
@@ -124,8 +128,10 @@ int ff_get_cpu_flags_arm(void)
 uint32_t hwcap;
 
 if (get_auxval(&hwcap) < 0)
+#if defined __linux__ || defined __ANDROID__
 if (get_hwcap(&hwcap) < 0)
 if (get_cpuinfo(&hwcap) < 0)
+#endif
 return flags;
 
 #define check_cap(cap, flag) do {   \

---

Summary of changes:
 libavutil/arm/cpu.c | 

[FFmpeg-cvslog] [ffmpeg] branch master updated. 8a34faa250 swscale/ppc/swscale_ppc_template: Fix av_unused placement

2025-09-26 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  8a34faa250fad7dc05aa9a554b4aaafd9e7425e7 (commit)
  from  0f1f345c3724ad3608ce5675f2a863ce56b23837 (commit)


- Log -
commit 8a34faa250fad7dc05aa9a554b4aaafd9e7425e7
Author: Andreas Rheinhardt 
AuthorDate: Fri Sep 26 22:16:40 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Fri Sep 26 22:38:13 2025 +0200

swscale/ppc/swscale_ppc_template: Fix av_unused placement

Forgotten in d6cb0d2c2bb8469f17d59dd82c8221b98e169d1a.

Reviewed-by: Sean McGovern 
Reviewed-by: Niklas Haas 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libswscale/ppc/swscale_ppc_template.c 
b/libswscale/ppc/swscale_ppc_template.c
index 7e502d5069..1e0c095285 100644
--- a/libswscale/ppc/swscale_ppc_template.c
+++ b/libswscale/ppc/swscale_ppc_template.c
@@ -125,8 +125,8 @@ static void FUNC(hScale_real)(SwsInternal *c, int16_t *dst, 
int dstW,
 case 8:
 for (register int i = 0; i < dstW; i++) {
 register int srcPos = filterPos[i];
-vector unsigned char src_vF, av_unused src_v0, av_unused src_v1;
-vector unsigned char av_unused permS;
+vector unsigned char src_vF;
+av_unused vector unsigned char src_v0, src_v1, permS;
 vector signed short src_v, filter_v;
 vector signed int val_v, val_s;
 FIRST_LOAD(src_v0, srcPos, src, permS);

---

Summary of changes:
 libswscale/ppc/swscale_ppc_template.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 0f1f345c37 avcodec/x86/qpeldsp_init: Fix compilation without external assembly

2025-09-26 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  0f1f345c3724ad3608ce5675f2a863ce56b23837 (commit)
  from  941eae01b1c4ed5d50eb5934e7df8a8a110e1699 (commit)


- Log -
commit 0f1f345c3724ad3608ce5675f2a863ce56b23837
Author: Andreas Rheinhardt 
AuthorDate: Fri Sep 26 16:17:45 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Fri Sep 26 18:30:53 2025 +0200

avcodec/x86/qpeldsp_init: Fix compilation without external assembly

Broken in 2cf9e733c6a00423a0967f23341d9f09e3c8.

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/x86/qpeldsp_init.c b/libavcodec/x86/qpeldsp_init.c
index 097cda0106..2448adde88 100644
--- a/libavcodec/x86/qpeldsp_init.c
+++ b/libavcodec/x86/qpeldsp_init.c
@@ -537,9 +537,11 @@ av_cold void ff_qpeldsp_init_x86(QpelDSPContext *c)
 SET_QPEL_FUNCS(put_no_rnd_qpel, 1,  8, mmxext, );
 #endif /* HAVE_MMXEXT_EXTERNAL */
 }
+#if HAVE_SSE2_EXTERNAL
 if (EXTERNAL_SSE2(cpu_flags)) {
 c->put_no_rnd_qpel_pixels_tab[0][0] =
 c->put_qpel_pixels_tab[0][0] = put_qpel16_mc00_sse2;
 c->avg_qpel_pixels_tab[0][0] = avg_qpel16_mc00_sse2;
 }
+#endif
 }

---

Summary of changes:
 libavcodec/x86/qpeldsp_init.c | 2 ++
 1 file changed, 2 insertions(+)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. ec0a04de0d avformat/whip: remind user increase -buffer_size

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  ec0a04de0d46b6104a4d92570b2412df5fafb483 (commit)
   via  b3793d9941516ea8c3511ca2b7db339148e3f122 (commit)
  from  469aad38977e47574f019c8d69715dc7be74f92d (commit)


- Log -
commit ec0a04de0d46b6104a4d92570b2412df5fafb483
Author: Jack Lau 
AuthorDate: Wed Sep 17 10:50:18 2025 +0800
Commit: stevenliu 
CommitDate: Thu Oct 9 09:55:18 2025 +

avformat/whip: remind user increase -buffer_size

The udp buffer size might be too small to easily
be full temporarily and return WSAEWOULDBLOCK.
The udp code will handle the windows error code
and convert it to AVERROR(EAGAIN).

This issue just can be reproduced on windows.

If sleep a interval and retry to send pkt when hit
EAGAIN, it will increase latency, and appropriate
interval is hard to define.

So this patch just remind user increase the buffer
size via -buffer_size to avoid this issue.

Signed-off-by: Jack Lau 

diff --git a/libavformat/whip.c b/libavformat/whip.c
index 6dd786db58..50ca218cbd 100644
--- a/libavformat/whip.c
+++ b/libavformat/whip.c
@@ -1945,8 +1945,10 @@ write_packet:
 if (ret == AVERROR(EINVAL)) {
 av_log(whip, AV_LOG_WARNING, "Ignore failed to write packet=%dB, 
ret=%d\n", pkt->size, ret);
 ret = 0;
+} else if (ret == AVERROR(EAGAIN)) {
+av_log(whip, AV_LOG_ERROR, "UDP send blocked, please increase the 
buffer via -buffer_size\n");
 } else
-av_log(whip, AV_LOG_ERROR, "Failed to write packet, size=%d\n", 
pkt->size);
+av_log(whip, AV_LOG_ERROR, "Failed to write packet, size=%d, 
ret=%d\n", pkt->size, ret);
 goto end;
 }
 

commit b3793d9941516ea8c3511ca2b7db339148e3f122
Author: Jack Lau 
AuthorDate: Wed Sep 17 10:25:41 2025 +0800
Commit: stevenliu 
CommitDate: Thu Oct 9 09:55:18 2025 +

avformat/whip: pass through buffer_size option to udp

Signed-off-by: Jack Lau 

diff --git a/doc/muxers.texi b/doc/muxers.texi
index 8c45b7d47a..18c99e57b6 100644
--- a/doc/muxers.texi
+++ b/doc/muxers.texi
@@ -3955,6 +3955,10 @@ Default value is 5000.
 Set the maximum size, in bytes, of RTP packets that send out.
 Default value is 1500.
 
+@item buffer_size @var{integer}
+Set the buffer size, in bytes, of underlying protocol.
+Default value is -1(auto). The UDP auto selects a reasonable value.
+
 @item authorization @var{string}
 The optional Bearer token for WHIP Authorization.
 
diff --git a/libavformat/whip.c b/libavformat/whip.c
index dff2502afd..6dd786db58 100644
--- a/libavformat/whip.c
+++ b/libavformat/whip.c
@@ -325,6 +325,7 @@ typedef struct WHIPContext {
  * Note that pion requires a smaller value, for example, 1200.
  */
 int pkt_size;
+int buffer_size;/* Underlying protocol send/receive buffer size */
 /**
  * The optional Bearer token for WHIP Authorization.
  * See 
https://www.ietf.org/archive/id/draft-ietf-wish-whip-08.html#name-authentication-and-authoriz
@@ -1221,8 +1222,9 @@ static int udp_connect(AVFormatContext *s)
 
 av_dict_set_int(&opts, "connect", 1, 0);
 av_dict_set_int(&opts, "fifo_size", 0, 0);
-/* Set the max packet size to the buffer size. */
+/* Pass through the pkt_size and buffer_size to underling protocol */
 av_dict_set_int(&opts, "pkt_size", whip->pkt_size, 0);
+av_dict_set_int(&opts, "buffer_size", whip->buffer_size, 0);
 
 ret = ffurl_open_whitelist(&whip->udp, url, AVIO_FLAG_WRITE, 
&s->interrupt_callback,
 &opts, s->protocol_whitelist, s->protocol_blacklist, NULL);
@@ -2023,6 +2025,7 @@ static int whip_check_bitstream(AVFormatContext *s, 
AVStream *st, const AVPacket
 static const AVOption options[] = {
 { "handshake_timeout",  "Timeout in milliseconds for ICE and DTLS 
handshake.",  OFFSET(handshake_timeout),  AV_OPT_TYPE_INT,{ .i64 = 5000 
},-1, INT_MAX, ENC },
 { "pkt_size",   "The maximum size, in bytes, of RTP packets that 
send out", OFFSET(pkt_size),   AV_OPT_TYPE_INT,{ .i64 = 1200 },
-1, INT_MAX, ENC },
+{ "buffer_size","The buffer size, in bytes, of underlying 
protocol",OFFSET(buffer_size),AV_OPT_TYPE_INT,{ .i64 = -1 
},  -1, INT_MAX, ENC },
 { "authorization",  "The optional Bearer token for WHIP 
Authorization", OFFSET(authorization),  AV_OPT_TYPE_STRING, { .str 
= NULL }, 0,   0, ENC },
 { "cert_file",  "The optional certificate file path for DTLS", 
 OFFSET(cert_file),  AV_OPT_TYPE_STRING, { .str = NULL }, 
0,   0, ENC },
 { "key_file",   "The optional private key file path for DTLS", 
 OFFSET(key_file),  AV_OPT_TYPE_STRING, { .str = NULL }, 0, 
  0, ENC },

---

Summary of change

[FFmpeg-cvslog] [ffmpeg] branch master updated. 378d5bb08a avcodec/x86/fpel: Add blocksize x blocksize avg/put functions

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  378d5bb08a460a3c34a3ea89cd442424e1d035df (commit)
   via  ad498f975980e18213a46e81fe146ef16da8ae9d (commit)
   via  650098955eb775f91e309941acf40ba8ffa253be (commit)
   via  74a88c0c110fb4285b335629cf166a44d6dab9ea (commit)
   via  54598238e42e4e4521d9676ccba93594c511aa17 (commit)
   via  cc2e2f12cafe142779458d5a43f71def5c9ea4d8 (commit)
   via  ec2fe94b3f0ebe90a9c9eeb8d40d8d8d1c42034c (commit)
  from  7896cc67c13037abba8941e39a74c56d26b775a7 (commit)


- Log -
commit 378d5bb08a460a3c34a3ea89cd442424e1d035df
Author: Andreas Rheinhardt 
AuthorDate: Sun Oct 5 05:33:21 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Wed Oct 8 20:40:53 2025 +0200

avcodec/x86/fpel: Add blocksize x blocksize avg/put functions

This commit deduplicates the wrappers around the fpel functions
for copying whole blocks (i.e. height equaling width). It does
this in a manner which avoids having push/pop function arguments
when the calling convention forces one to pass them on the stack
(as in 32bit systems).

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/x86/cavsdsp.c b/libavcodec/x86/cavsdsp.c
index 593faa85b8..d14b472d54 100644
--- a/libavcodec/x86/cavsdsp.c
+++ b/libavcodec/x86/cavsdsp.c
@@ -46,36 +46,10 @@ static void cavs_idct8_add_sse2(uint8_t *dst, int16_t 
*block, ptrdiff_t stride)
 
 #endif /* HAVE_SSE2_EXTERNAL */
 
-#if HAVE_MMX_EXTERNAL
-static void put_cavs_qpel8_mc00_mmx(uint8_t *dst, const uint8_t *src,
-ptrdiff_t stride)
-{
-ff_put_pixels8_mmx(dst, src, stride, 8);
-}
-
-static void avg_cavs_qpel8_mc00_mmxext(uint8_t *dst, const uint8_t *src,
-   ptrdiff_t stride)
-{
-ff_avg_pixels8_mmxext(dst, src, stride, 8);
-}
-
-static void put_cavs_qpel16_mc00_sse2(uint8_t *dst, const uint8_t *src,
-  ptrdiff_t stride)
-{
-ff_put_pixels16_sse2(dst, src, stride, 16);
-}
-
-static void avg_cavs_qpel16_mc00_sse2(uint8_t *dst, const uint8_t *src,
-  ptrdiff_t stride)
-{
-ff_avg_pixels16_sse2(dst, src, stride, 16);
-}
-#endif
-
 static av_cold void cavsdsp_init_mmx(CAVSDSPContext *c)
 {
 #if HAVE_MMX_EXTERNAL
-c->put_cavs_qpel_pixels_tab[1][0] = put_cavs_qpel8_mc00_mmx;
+c->put_cavs_qpel_pixels_tab[1][0] = ff_put_pixels8x8_mmx;
 #endif /* HAVE_MMX_EXTERNAL */
 }
 
@@ -129,12 +103,12 @@ av_cold void ff_cavsdsp_init_x86(CAVSDSPContext *c)
 
 #if HAVE_MMX_EXTERNAL
 if (EXTERNAL_MMXEXT(cpu_flags)) {
-c->avg_cavs_qpel_pixels_tab[1][0] = avg_cavs_qpel8_mc00_mmxext;
+c->avg_cavs_qpel_pixels_tab[1][0] = ff_avg_pixels8x8_mmxext;
 }
 #endif
 #if HAVE_SSE2_EXTERNAL
 if (EXTERNAL_SSE2(cpu_flags)) {
-c->put_cavs_qpel_pixels_tab[0][ 0] = put_cavs_qpel16_mc00_sse2;
+c->put_cavs_qpel_pixels_tab[0][ 0] = ff_put_pixels16x16_sse2;
 c->put_cavs_qpel_pixels_tab[0][ 2] = put_cavs_qpel16_mc20_sse2;
 c->put_cavs_qpel_pixels_tab[0][ 4] = put_cavs_qpel16_mc01_sse2;
 c->put_cavs_qpel_pixels_tab[0][ 8] = put_cavs_qpel16_mc02_sse2;
@@ -144,7 +118,7 @@ av_cold void ff_cavsdsp_init_x86(CAVSDSPContext *c)
 c->put_cavs_qpel_pixels_tab[1][ 8] = ff_put_cavs_qpel8_mc02_sse2;
 c->put_cavs_qpel_pixels_tab[1][12] = ff_put_cavs_qpel8_mc03_sse2;
 
-c->avg_cavs_qpel_pixels_tab[0][ 0] = avg_cavs_qpel16_mc00_sse2;
+c->avg_cavs_qpel_pixels_tab[0][ 0] = ff_avg_pixels16x16_sse2;
 c->avg_cavs_qpel_pixels_tab[0][ 2] = avg_cavs_qpel16_mc20_sse2;
 c->avg_cavs_qpel_pixels_tab[0][ 4] = avg_cavs_qpel16_mc01_sse2;
 c->avg_cavs_qpel_pixels_tab[0][ 8] = avg_cavs_qpel16_mc02_sse2;
diff --git a/libavcodec/x86/fpel.asm b/libavcodec/x86/fpel.asm
index 8ca684efa9..68a05310f2 100644
--- a/libavcodec/x86/fpel.asm
+++ b/libavcodec/x86/fpel.asm
@@ -35,7 +35,12 @@ SECTION .text
 %define LOAD movu
 %define SAVE mova
 %endif
+cglobal %1_pixels%2x%2, 3,5,4
+mov r3d, %2
+jmp %1_pixels%2_after_prologue
+
 cglobal %1_pixels%2, 4,5,4
+%1_pixels%2_after_prologue:
 lea  r4, [r2*3]
 .loop:
 LOAD m0, [r1]
diff --git a/libavcodec/x86/fpel.h b/libavcodec/x86/fpel.h
index dc69e1cd83..598a7a6f63 100644
--- a/libavcodec/x86/fpel.h
+++ b/libavcodec/x86/fpel.h
@@ -24,12 +24,20 @@
 
 void ff_avg_pixels8_mmxext(uint8_t *block, const uint8_t *pixels,
ptrdiff_t line_size, int h);
+void ff_avg_pixels8x8_mmxext(uint8_t *block, const uint8_t *pixels,
+ ptrdiff_t line_size);
 void ff_avg_pixels16_sse2(uint8_t *block, const uint8_t *pixels,
   ptrdiff_t line_size, int h);
+void ff_avg_pixels16x16_sse2(uint8_t *block, const uint8_t *pixels,
+ ptrdiff_t line_size);
 void ff_put_pixels8_mmx(ui

[FFmpeg-cvslog] [ffmpeg] branch master updated. d19b7c283c avcodec/d3d12va_encode: D3D12 H264 encoding support

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  d19b7c283cf31c5ab510bfb8a8de1f0b80243428 (commit)
  from  ed007ad427a659667fd3b20e6b7bfebc2844c832 (commit)


- Log -
commit d19b7c283cf31c5ab510bfb8a8de1f0b80243428
Author: Araz Iusubov 
AuthorDate: Wed Oct 15 13:23:03 2025 +0200
Commit: Tong Wu 
CommitDate: Sat Oct 18 12:20:11 2025 +

avcodec/d3d12va_encode: D3D12 H264 encoding support

This patch introduces hardware-accelerated H.264 encoding
using Direct3D 12 Video API (D3D12VA).

diff --git a/Changelog b/Changelog
index 6fd95c9136..87e80c4b8b 100644
--- a/Changelog
+++ b/Changelog
@@ -7,6 +7,7 @@ version :
 - gfxcapture: Windows.Graphics.Capture based window/monitor capture
 - hxvs demuxer for HXVS/HXVT IP camera format
 - MPEG-H 3D Audio decoding via mpeghdec
+- D3D12 H.264 encoder
 
 
 version 8.0:
diff --git a/configure b/configure
index 7828381b5d..39e69d217d 100755
--- a/configure
+++ b/configure
@@ -3464,6 +3464,7 @@ h264_amf_encoder_deps="amf"
 h264_amf_decoder_deps="amf"
 h264_cuvid_decoder_deps="cuvid"
 h264_cuvid_decoder_select="h264_mp4toannexb_bsf"
+h264_d3d12va_encoder_select="cbs_h264 d3d12va_encode"
 h264_mediacodec_decoder_deps="mediacodec"
 h264_mediacodec_decoder_select="h264_mp4toannexb_bsf h264_parser"
 h264_mediacodec_encoder_deps="mediacodec"
diff --git a/libavcodec/Makefile b/libavcodec/Makefile
index 791fd5d5a4..6c007dda8c 100644
--- a/libavcodec/Makefile
+++ b/libavcodec/Makefile
@@ -432,6 +432,8 @@ OBJS-$(CONFIG_H264_DECODER)+= h264dec.o 
h264_cabac.o h264_cavlc.o \
 OBJS-$(CONFIG_H264_AMF_ENCODER)+= amfenc_h264.o
 OBJS-$(CONFIG_H264_AMF_DECODER)+= amfdec.o
 OBJS-$(CONFIG_H264_CUVID_DECODER)  += cuviddec.o
+OBJS-$(CONFIG_H264_D3D12VA_ENCODER)+= d3d12va_encode_h264.o h264_levels.o \
+  h2645data.o hw_base_encode_h264.o
 OBJS-$(CONFIG_H264_MEDIACODEC_DECODER) += mediacodecdec.o
 OBJS-$(CONFIG_H264_MEDIACODEC_ENCODER) += mediacodecenc.o
 OBJS-$(CONFIG_H264_MF_ENCODER) += mfenc.o mf_utils.o
diff --git a/libavcodec/allcodecs.c b/libavcodec/allcodecs.c
index d4b360f289..251ffae390 100644
--- a/libavcodec/allcodecs.c
+++ b/libavcodec/allcodecs.c
@@ -870,6 +870,7 @@ extern const FFCodec ff_libopenh264_decoder;
 extern const FFCodec ff_h264_amf_encoder;
 extern const FFCodec ff_h264_amf_decoder;
 extern const FFCodec ff_h264_cuvid_decoder;
+extern const FFCodec ff_h264_d3d12va_encoder;
 extern const FFCodec ff_h264_mf_encoder;
 extern const FFCodec ff_h264_nvenc_encoder;
 extern const FFCodec ff_h264_oh_decoder;
diff --git a/libavcodec/d3d12va_encode_h264.c b/libavcodec/d3d12va_encode_h264.c
new file mode 100644
index 00..560187b750
--- /dev/null
+++ b/libavcodec/d3d12va_encode_h264.c
@@ -0,0 +1,633 @@
+/*
+ * Direct3D 12 HW acceleration video encoder
+ *
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+#include "libavutil/opt.h"
+#include "libavutil/common.h"
+#include "libavutil/mem.h"
+#include "libavutil/pixdesc.h"
+#include "libavutil/hwcontext_d3d12va_internal.h"
+
+#include "avcodec.h"
+#include "cbs.h"
+#include "cbs_h264.h"
+#include "hw_base_encode_h264.h"
+#include "h2645data.h"
+#include "h264_levels.h"
+#include "codec_internal.h"
+#include "d3d12va_encode.h"
+
+typedef struct D3D12VAEncodeH264Picture {
+int pic_order_cnt;
+int64_t last_idr_frame;
+} D3D12VAEncodeH264Picture;
+
+typedef struct D3D12VAEncodeH264Context {
+D3D12VAEncodeContext common;
+
+// User options.
+int qp;
+int profile;
+int level;
+int idr_pic_id;
+
+// Writer structures.
+FFHWBaseEncodeH264 units;
+FFHWBaseEncodeH264Opts unit_opts;
+
+CodedBitstreamContext *cbc;
+CodedBitstreamFragment current_access_unit;
+} D3D12VAEncodeH264Context;
+
+typedef struct D3D12VAEncodeH264Level {
+int level;
+D3D12_VIDEO_ENCODER_LEVELS_H264 d3d12_level;
+} D3D12VAEncodeH264Level;
+
+static const D3D12VAEncodeH264Level h264_levels[] = {
+{ 10, D3D12_VIDEO_ENCODER_LEVELS_H264_1},
+{ 11, D3D12_VIDEO_ENCODER_LEVELS_H264_11   },
+{ 12, D3D12_VIDEO_ENCODER_LEVELS_H264_12   },
+{ 13, D3D12_VIDEO_ENCODER_LEVELS_H264_13   },
+{ 20, D3D12_VIDEO_ENCOD

[FFmpeg-cvslog] [ffmpeg] branch master updated. 51d3c4b4b6 tools/target_dec_fuzzer: Adjust threshold for PIXLET

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  51d3c4b4b62691736172120c5d728e6c400d69c9 (commit)
   via  388e6fb3be63f88bc62ebda35ca0fc96e99ceed5 (commit)
   via  56ef66d350b9184cd96cd370bf0a8444962cd0e8 (commit)
   via  b132c1755a5d62223d63d4296fbfa1789808 (commit)
   via  8988734d0905fbfedaf439179cc27fc01c5d7792 (commit)
   via  51f0f2d2cf90facc45130c81e50f9f19df98b732 (commit)
   via  d43f19064e50380fa050f7c8d89253484f765dc3 (commit)
   via  4666c1eed37385484c8e34998b3fe2e5c86d4e08 (commit)
  from  d19b7c283cf31c5ab510bfb8a8de1f0b80243428 (commit)


- Log -
commit 51d3c4b4b62691736172120c5d728e6c400d69c9
Author: Michael Niedermayer 
AuthorDate: Thu Jul 3 21:05:14 2025 +0200
Commit: Michael Niedermayer 
CommitDate: Sun Oct 19 02:07:03 2025 +0200

tools/target_dec_fuzzer: Adjust threshold for PIXLET

Fixes: Timeout
Fixes: 
425754611/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_PIXLET_fuzzer-4778526102585344

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 

diff --git a/tools/target_dec_fuzzer.c b/tools/target_dec_fuzzer.c
index e7db9d261c..a40dc01248 100644
--- a/tools/target_dec_fuzzer.c
+++ b/tools/target_dec_fuzzer.c
@@ -286,6 +286,7 @@ int LLVMFuzzerTestOneInput(const uint8_t *data, size_t 
size) {
 case AV_CODEC_ID_MXPEG:   maxpixels  /= 128;   break;
 case AV_CODEC_ID_NUV: maxpixels  /= 128;   break;
 case AV_CODEC_ID_OPUS:maxsamples /= 16384; break;
+case AV_CODEC_ID_PIXLET:  maxpixels  /= 1024;  break;
 case AV_CODEC_ID_PNG: maxpixels  /= 128;   break;
 case AV_CODEC_ID_APNG:maxpixels  /= 128;   break;
 case AV_CODEC_ID_QTRLE:   maxpixels  /= 16;break;

commit 388e6fb3be63f88bc62ebda35ca0fc96e99ceed5
Author: Michael Niedermayer 
AuthorDate: Thu Jul 3 20:27:15 2025 +0200
Commit: Michael Niedermayer 
CommitDate: Sun Oct 19 01:37:26 2025 +0200

avcodec/ffv1enc: Consider variation in slice sizes

When splitting a 5 lines image in 2 slices one will be 3 lines and thus 
need more space

Fixes: Assertion sc->slice_coding_mode == 0 failed at 
libavcodec/ffv1enc.c:1668
Fixes: 
422811239/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FFV1_fuzzer-4933405139861504

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 

diff --git a/libavcodec/ffv1enc.c b/libavcodec/ffv1enc.c
index 97b38e4d16..8e5ebe773c 100644
--- a/libavcodec/ffv1enc.c
+++ b/libavcodec/ffv1enc.c
@@ -1684,9 +1684,11 @@ size_t ff_ffv1_encode_buffer_size(AVCodecContext *avctx)
 {
 FFV1Context *f = avctx->priv_data;
 
-size_t maxsize = avctx->width*avctx->height * (1 + f->transparency);
+int w = avctx->width  + f->num_h_slices;
+int h = avctx->height + f->num_v_slices;
+size_t maxsize = w*h * (1 + f->transparency);
 if (f->chroma_planes)
-maxsize += AV_CEIL_RSHIFT(avctx->width, f->chroma_h_shift) * 
AV_CEIL_RSHIFT(f->height, f->chroma_v_shift) * 2;
+maxsize += AV_CEIL_RSHIFT(w, f->chroma_h_shift) * AV_CEIL_RSHIFT(h, 
f->chroma_v_shift) * 2;
 maxsize += f->slice_count * 800; //for slice header
 if (f->version > 3) {
 maxsize *= f->bits_per_raw_sample + 1;

commit 56ef66d350b9184cd96cd370bf0a8444962cd0e8
Author: Michael Niedermayer 
AuthorDate: Thu Jul 3 18:52:08 2025 +0200
Commit: Michael Niedermayer 
CommitDate: Sun Oct 19 01:37:17 2025 +0200

tools/target_dec_fuzzer: Adjust threshold for CRI

Fixes: Timeout
Fixes: 
421997576/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_CRI_fuzzer-5335057265131520

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 

diff --git a/tools/target_dec_fuzzer.c b/tools/target_dec_fuzzer.c
index 4b83e3fe83..e7db9d261c 100644
--- a/tools/target_dec_fuzzer.c
+++ b/tools/target_dec_fuzzer.c
@@ -230,6 +230,7 @@ int LLVMFuzzerTestOneInput(const uint8_t *data, size_t 
size) {
 case AV_CODEC_ID_CFHD:maxpixels  /= 16384; break;
 case AV_CODEC_ID_CINEPAK: maxpixels  /= 128;   break;
 case AV_CODEC_ID_COOK:maxsamples /= 1<<20; break;
+case AV_CODEC_ID_CRI: maxpixels  /= 1024;  break;
 case AV_CODEC_ID_CSCD:maxpixels  /= 1024;  break;
 case AV_CODEC_ID_DFA: maxpixels  /= 1024;  break;
 case AV_CODEC_ID_DIRAC:   maxpixels  /= 8192;  break;

commit b132c1755a5d62223d63d4296fbfa1789808
Author: Michael Niedermayer 
AuthorDate: Thu Jul 3 18:38:15 2025 +0200
Commit: Michael Niedermayer 
CommitDate: Sun Oct 19 01:37:14 2025 +0200

tools/target_dec_fuzzer: Adjust threshold for qdraw

Fixes: Timeout
Fixes: 
421954735/clusterfuzz-

[FFmpeg-cvslog] [ffmpeg] branch master updated. e442128944 movenc: Make sure to flush the delayed moov atom for hybrid fragmented

2025-10-21 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  e442128944cf1034b33346180021c1f747d5bd99 (commit)
   via  27f556188557786f0ead2147b1eea3c36795cfdd (commit)
  from  dc39a576ad8c489bf229c4acdf5c347b1dd264b2 (commit)


- Log -
commit e442128944cf1034b33346180021c1f747d5bd99
Author: Martin Storsjö 
AuthorDate: Tue Oct 14 13:49:04 2025 +0300
Commit: Martin Storsjö 
CommitDate: Tue Oct 21 08:38:32 2025 +

movenc: Make sure to flush the delayed moov atom for hybrid fragmented

If using the delay_moov flag in combination with hybrid_fragment
(which is a potentially problematic combination otherwise - the
ftyp box does end up hidden in the end), then we need to flush
twice to get both the moov box and the first fragment, if the
file is finished before the first fragment is completed.

diff --git a/libavformat/movenc.c b/libavformat/movenc.c
index bdbe1a4150..218a285821 100644
--- a/libavformat/movenc.c
+++ b/libavformat/movenc.c
@@ -8610,7 +8610,7 @@ static int mov_write_trailer(AVFormatContext *s)
 if (!(mov->flags & FF_MOV_FLAG_FRAGMENT) ||
 mov->flags & FF_MOV_FLAG_HYBRID_FRAGMENTED) {
 if (mov->flags & FF_MOV_FLAG_HYBRID_FRAGMENTED) {
-mov_flush_fragment(s, 1);
+mov_auto_flush_fragment(s, 1);
 mov->mdat_size = avio_tell(pb) - mov->mdat_pos - 8;
 for (i = 0; i < mov->nb_tracks; i++) {
 MOVTrack *track = &mov->tracks[i];

commit 27f556188557786f0ead2147b1eea3c36795cfdd
Author: Martin Storsjö 
AuthorDate: Tue Oct 14 13:47:03 2025 +0300
Commit: Martin Storsjö 
CommitDate: Tue Oct 21 08:38:32 2025 +

movenc: Fix sample clustering for hybrid_fragmented+delay_moov

If samples were available when the moov was written, chunking
for those samples has been done already, which has to be reset
here.

This is the case when not using empty_moov, when the moov box
describes the first fragment - this case was accounted for already.
But if using the delay_moov flag, then those samples also were
available when writing the moov, so chunking for them has already
been done in this case as well.

Therefore, always reset chunking here (it should be harmless to
always do it), and update the comment to clarify the cases
involved here.

diff --git a/libavformat/movenc.c b/libavformat/movenc.c
index cd66a39518..bdbe1a4150 100644
--- a/libavformat/movenc.c
+++ b/libavformat/movenc.c
@@ -6390,8 +6390,10 @@ static int mov_finish_fragment(MOVMuxContext *mov, 
MOVTrack *track,
 if (mov->flags & FF_MOV_FLAG_HYBRID_FRAGMENTED) {
 for (i = 0; i < track->entry; i++)
 track->cluster[i].pos += ref_pos + track->data_offset;
-if (track->cluster_written == 0 && !(mov->flags & 
FF_MOV_FLAG_EMPTY_MOOV)) {
-// First flush. If this was a case of not using empty moov, reset 
chunking.
+if (track->cluster_written == 0) {
+// First flush. Chunking for this fragment may already have been
+// done, either if we didn't use empty_moov, or if we did use
+// delay_moov. In either case, reset chunking here.
 for (i = 0; i < track->entry; i++) {
 track->cluster[i].chunkNum = 0;
 track->cluster[i].samples_in_chunk = track->cluster[i].entries;

---

Summary of changes:
 libavformat/movenc.c | 8 +---
 1 file changed, 5 insertions(+), 3 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 05b8608c76 avcodec/x86/mpegvideoencdsp_init: Fix left shift of negative number

2025-10-21 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  05b8608c76e76b7d8b4ce5e86e0940244fbb737e (commit)
  from  e442128944cf1034b33346180021c1f747d5bd99 (commit)


- Log -
commit 05b8608c76e76b7d8b4ce5e86e0940244fbb737e
Author: Andreas Rheinhardt 
AuthorDate: Tue Oct 21 12:11:55 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Tue Oct 21 12:11:55 2025 +0200

avcodec/x86/mpegvideoencdsp_init: Fix left shift of negative number

Uncovered by UBSan when running the mpegvideoencdsp checkasm
test.

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/x86/mpegvideoencdsp_init.c 
b/libavcodec/x86/mpegvideoencdsp_init.c
index 3cd16fefbf..bf5b722016 100644
--- a/libavcodec/x86/mpegvideoencdsp_init.c
+++ b/libavcodec/x86/mpegvideoencdsp_init.c
@@ -42,7 +42,7 @@ static int try_8x8basis_ssse3(const int16_t rem[64], const 
int16_t weight[64], c
 x86_reg i=0;
 
 av_assert2(FFABS(scale) < MAX_ABS);
-scale <<= 16 + SCALE_OFFSET - BASIS_SHIFT + RECON_SHIFT;
+scale *= 1 << (16 + SCALE_OFFSET - BASIS_SHIFT + RECON_SHIFT);
 
 __asm__ volatile(
 "pxor%%xmm2, %%xmm2 \n\t"
@@ -87,7 +87,7 @@ static void add_8x8basis_ssse3(int16_t rem[64], const int16_t 
basis[64], int sca
 x86_reg i=0;
 
 if (FFABS(scale) < 1024) {
-scale <<= 16 + SCALE_OFFSET - BASIS_SHIFT + RECON_SHIFT;
+scale *= 1 << (16 + SCALE_OFFSET - BASIS_SHIFT + RECON_SHIFT);
 __asm__ volatile(
 "movd%3, %%xmm2 \n\t"
 "punpcklwd   %%xmm2, %%xmm2 \n\t"

---

Summary of changes:
 libavcodec/x86/mpegvideoencdsp_init.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. cb4052beae libavformat/oggparseopus.c: Parse comments from secondary chained streams header packet.

2025-10-01 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  cb4052beae1e347e0c357a5b7ab860328aa01dd4 (commit)
   via  45d7d5d3e2aa260785432736bcc394e4f3eb2c82 (commit)
   via  7dbf7d2a4571c6f88c7ac441ec259609951c519e (commit)
   via  cebbb6ae8a096d93dc6f09e3cbd1bde551a5291a (commit)
   via  de8d57e4c576e7ef31c199caf12cbbe755634933 (commit)
  from  5511641365b83afa6449ae0b89d01b78556d941d (commit)


- Log -
commit cb4052beae1e347e0c357a5b7ab860328aa01dd4
Author: Romain Beauxis 
AuthorDate: Mon Feb 10 11:48:03 2025 -0600
Commit: Yalda 
CommitDate: Wed Oct 1 14:20:55 2025 +

libavformat/oggparseopus.c: Parse comments from secondary chained streams 
header packet.

diff --git a/libavformat/oggparseopus.c b/libavformat/oggparseopus.c
index 65b93b4053..ae4ff22c53 100644
--- a/libavformat/oggparseopus.c
+++ b/libavformat/oggparseopus.c
@@ -154,6 +154,11 @@ static int opus_packet(AVFormatContext *avf, int idx)
 }
 
 if (os->psize > 8 && !memcmp(packet, "OpusTags", 8)) {
+ret = ff_vorbis_update_metadata(avf, st, os->buf + os->pstart + 8,
+os->psize - 8);
+if (ret < 0)
+return ret;
+
 priv->need_comments = 0;
 return 1;
 }
diff --git a/tests/ref/fate/ogg-opus-chained-meta.txt 
b/tests/ref/fate/ogg-opus-chained-meta.txt
index addc41c1eb..aad9b83700 100644
--- a/tests/ref/fate/ogg-opus-chained-meta.txt
+++ b/tests/ref/fate/ogg-opus-chained-meta.txt
@@ -13,7 +13,8 @@ Stream ID: 0, frame PTS: 3528, metadata: N/A
 Stream ID: 0, packet PTS: 4488, packet DTS: 4488
 Stream ID: 0, frame PTS: 4488, metadata: N/A
 Stream ID: 0, packet PTS: -312, packet DTS: -312
-Stream ID: 0, frame PTS: -312, metadata: N/A
+Stream ID: 0, new metadata: encoder=Lavc61.19.100 libopus:title=Second Stream
+Stream ID: 0, frame PTS: -312, metadata: encoder=Lavc61.19.100 
libopus:title=Second Stream
 Stream ID: 0, packet PTS: 648, packet DTS: 648
 Stream ID: 0, frame PTS: 648, metadata: N/A
 Stream ID: 0, packet PTS: 1608, packet DTS: 1608

commit 45d7d5d3e2aa260785432736bcc394e4f3eb2c82
Author: Romain Beauxis 
AuthorDate: Tue Feb 4 07:03:49 2025 -0500
Commit: Yalda 
CommitDate: Wed Oct 1 14:20:55 2025 +

libavformat/oggparseflac.c: Parse ogg/flac comments in new ogg packets, add 
them to ogg stream
new_metadata.

diff --git a/libavformat/oggparseflac.c b/libavformat/oggparseflac.c
index d66b85b09e..e81e4021a1 100644
--- a/libavformat/oggparseflac.c
+++ b/libavformat/oggparseflac.c
@@ -85,6 +85,8 @@ flac_packet (AVFormatContext * s, int idx)
 {
 struct ogg *ogg = s->priv_data;
 struct ogg_stream *os = ogg->streams + idx;
+AVStream *st = s->streams[idx];
+int ret;
 
 if (os->psize > OGG_FLAC_MAGIC_SIZE &&
 !memcmp(
@@ -95,6 +97,11 @@ flac_packet (AVFormatContext * s, int idx)
 
 if (os->psize > 0 &&
 ((os->buf[os->pstart] & 0x7F) == FLAC_METADATA_TYPE_VORBIS_COMMENT)) {
+ret = ff_vorbis_update_metadata(s, st, os->buf + os->pstart + 4,
+os->psize - 4);
+if (ret < 0)
+return ret;
+
 return 1;
 }
 
diff --git a/tests/ref/fate/ogg-flac-chained-meta.txt 
b/tests/ref/fate/ogg-flac-chained-meta.txt
index 28e22aa29e..5abf37dcee 100644
--- a/tests/ref/fate/ogg-flac-chained-meta.txt
+++ b/tests/ref/fate/ogg-flac-chained-meta.txt
@@ -5,6 +5,7 @@ Stream ID: 0, frame PTS: 0, metadata: N/A
 Stream ID: 0, packet PTS: 4608, packet DTS: 4608
 Stream ID: 0, frame PTS: 4608, metadata: N/A
 Stream ID: 0, packet PTS: 0, packet DTS: 0
-Stream ID: 0, frame PTS: 0, metadata: N/A
+Stream ID: 0, new metadata: encoder=Lavc61.19.100 flac:title=Second Stream
+Stream ID: 0, frame PTS: 0, metadata: encoder=Lavc61.19.100 flac:title=Second 
Stream
 Stream ID: 0, packet PTS: 4608, packet DTS: 4608
 Stream ID: 0, frame PTS: 4608, metadata: N/A

commit 7dbf7d2a4571c6f88c7ac441ec259609951c519e
Author: Romain Beauxis 
AuthorDate: Fri Feb 14 09:39:45 2025 -0600
Commit: Yalda 
CommitDate: Wed Oct 1 14:20:55 2025 +

libavformat/oggdec.c: Use AV_PKT_DATA_STRINGS_METADATA to pass metadata 
updates.

diff --git a/libavformat/oggdec.c b/libavformat/oggdec.c
index 9dc2c62035..9f3a92a5ea 100644
--- a/libavformat/oggdec.c
+++ b/libavformat/oggdec.c
@@ -880,7 +880,7 @@ retry:
 }
 
 if (os->new_metadata) {
-ret = av_packet_add_side_data(pkt, AV_PKT_DATA_METADATA_UPDATE,
+ret = av_packet_add_side_data(pkt, AV_PKT_DATA_STRINGS_METADATA,
   os->new_metadata, os->new_metadata_size);
 if (ret < 0)
 return ret;
diff --git a/libavformat/oggdec.h b/libavformat/oggdec.h
index 6776782ddf..b051b651e3 100644
--- a/libavformat/oggdec.h
+++ b/libavformat/oggdec.h
@@ -164,7 +164,7 @@ int ff_vorbis_stream_comment(AVFormatContext *as, AVStream 
*st,
  * Parse Vorbis comments, add metadata to an AVStream
 

[FFmpeg-cvslog] [ffmpeg] branch master updated. 61b6877637 avcodec/mjpegdec: Explain buf_size/width/height check

2025-10-02 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  61b6877637041a1f817ad9811c839b0feae2b8af (commit)
  from  1a02412170144f07711428ddc2d1051c4284ee0a (commit)


- Log -
commit 61b6877637041a1f817ad9811c839b0feae2b8af
Author: Michael Niedermayer 
AuthorDate: Thu Sep 11 20:12:55 2025 +0200
Commit: michaelni 
CommitDate: Thu Oct 2 12:52:43 2025 +

avcodec/mjpegdec: Explain buf_size/width/height check

Suggested-by: Ramiro

Signed-off-by: Michael Niedermayer 

diff --git a/libavcodec/mjpegdec.c b/libavcodec/mjpegdec.c
index b829ab682b..69bc003490 100644
--- a/libavcodec/mjpegdec.c
+++ b/libavcodec/mjpegdec.c
@@ -340,6 +340,8 @@ int ff_mjpeg_decode_sof(MJpegDecodeContext *s)
 av_log(s->avctx, AV_LOG_DEBUG, "sof0: picture: %dx%d\n", width, height);
 if (av_image_check_size(width, height, 0, s->avctx) < 0)
 return AVERROR_INVALIDDATA;
+
+// A valid frame requires at least 1 bit for DC + 1 bit for AC for each 
8x8 block.
 if (s->buf_size && (width + 7) / 8 * ((height + 7) / 8) > s->buf_size * 
4LL)
 return AVERROR_INVALIDDATA;
 

---

Summary of changes:
 libavcodec/mjpegdec.c | 2 ++
 1 file changed, 2 insertions(+)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 0fdb5829e3 avformat/rtsp: set AVFMTCTX_UNSEEKABLE flag

2025-10-02 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  0fdb5829e38dabea9cbe4073a35b6c6315e7508e (commit)
  from  dd977adcfe4d74b4240f1122a7c900966a0d0bc3 (commit)


- Log -
commit 0fdb5829e38dabea9cbe4073a35b6c6315e7508e
Author: Kaarle Ritvanen 
AuthorDate: Tue Apr 29 14:35:00 2025 +0300
Commit: michaelni 
CommitDate: Sun Sep 28 13:37:43 2025 +

avformat/rtsp: set AVFMTCTX_UNSEEKABLE flag

for live RTP streams. Some external applications, such as Qt Multimedia,
depend on this flag being set correctly.

Signed-off-by: Kaarle Ritvanen 

diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c
index d601d63a89..e8f44e571a 100644
--- a/libavformat/rtsp.c
+++ b/libavformat/rtsp.c
@@ -663,8 +663,8 @@ static void sdp_parse_line(AVFormatContext *s, 
SDPParseState *s1,
 rtsp_parse_range_npt(p, &start, &end);
 s->start_time = start;
 /* AV_NOPTS_VALUE means live broadcast (and can't seek) */
-s->duration   = (end == AV_NOPTS_VALUE) ?
-AV_NOPTS_VALUE : end - start;
+if (end != AV_NOPTS_VALUE)
+s->duration = end - start;
 } else if (av_strstart(p, "lang:", &p)) {
 if (s->nb_streams > 0) {
 get_word(buf1, sizeof(buf1), &p);
@@ -754,6 +754,8 @@ int ff_sdp_parse(AVFormatContext *s, const char *content)
 char buf[SDP_MAX_SIZE], *q;
 SDPParseState sdp_parse_state = { { 0 } }, *s1 = &sdp_parse_state;
 
+s->duration = AV_NOPTS_VALUE;
+
 p = content;
 for (;;) {
 p += strspn(p, SPACE_CHARS);
@@ -787,6 +789,9 @@ int ff_sdp_parse(AVFormatContext *s, const char *content)
 av_freep(&s1->default_exclude_source_addrs[i]);
 av_freep(&s1->default_exclude_source_addrs);
 
+if (s->duration == AV_NOPTS_VALUE)
+s->ctx_flags |= AVFMTCTX_UNSEEKABLE;
+
 return 0;
 }
 #endif /* CONFIG_RTPDEC */

---

Summary of changes:
 libavformat/rtsp.c | 9 +++--
 1 file changed, 7 insertions(+), 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. df4587789f avcodec/amfenc: avoid unnecessary output delay in low delay mode

2025-10-03 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  df4587789f1f4337ed778752010d7176a9e90241 (commit)
  from  f1d5114103a8164869a279326043645e7bacdc86 (commit)


- Log -
commit df4587789f1f4337ed778752010d7176a9e90241
Author: Cameron Gutman 
AuthorDate: Mon Sep 8 23:41:43 2025 -0500
Commit: Dmitrii Ovchinnikov 
CommitDate: Fri Oct 3 11:05:03 2025 +

avcodec/amfenc: avoid unnecessary output delay in low delay mode

The code optimizes throughput by letting the encoder work on frame N
until frame N+1 is ready for submission, but this hurts low-delay uses
by delaying output by one frame. Don't delay output beyond what is
necessary when AV_CODEC_FLAG_LOW_DELAY is used.

Signed-off-by: Cameron Gutman 

diff --git a/libavcodec/amfenc.c b/libavcodec/amfenc.c
index b16b642e4c..f363192000 100644
--- a/libavcodec/amfenc.c
+++ b/libavcodec/amfenc.c
@@ -497,7 +497,7 @@ static int amf_submit_frame(AVCodecContext *avctx, AVFrame  
  *frame, AMFSurface
 AMF_RESULT  res;
 int ret;
 int hw_surface = 0;
-int max_b_frames = ctx->max_b_frames < 0 ? 0 : 
ctx->max_b_frames;
+int output_delay = FFMAX(ctx->max_b_frames, 0) + 
((avctx->flags & AV_CODEC_FLAG_LOW_DELAY) ? 0 : 1);
 
 // prepare surface from frame
 switch (frame->format) {
@@ -634,8 +634,8 @@ static int amf_submit_frame(AVCodecContext *avctx, AVFrame  
  *frame, AMFSurface
 ret = av_fifo_write(ctx->timestamp_list, &frame->pts, 1);
 if (ret < 0)
 return ret;
-if(ctx->submitted_frame <= ctx->encoded_frame + max_b_frames + 1)
-return AVERROR(EAGAIN); // if frame just submiited - don't poll or 
wait
+if(ctx->submitted_frame <= ctx->encoded_frame + output_delay)
+return AVERROR(EAGAIN); // too soon to poll or wait
 }
 return 0;
 }
@@ -681,7 +681,7 @@ int ff_amf_receive_packet(AVCodecContext *avctx, AVPacket 
*avpkt)
 AVFrame*frame = av_frame_alloc();
 int block_and_wait;
 int64_t pts = 0;
-int max_b_frames = ctx->max_b_frames < 0 ? 0 : ctx->max_b_frames;
+int output_delay = FFMAX(ctx->max_b_frames, 0) + ((avctx->flags & 
AV_CODEC_FLAG_LOW_DELAY) ? 0 : 1);
 
 if (!ctx->encoder){
 av_frame_free(&frame);
@@ -700,7 +700,7 @@ int ff_amf_receive_packet(AVCodecContext *avctx, AVPacket 
*avpkt)
 if(ret != AVERROR_EOF){
 av_frame_free(&frame);
 if(ret == AVERROR(EAGAIN)){
-if(ctx->submitted_frame <= ctx->encoded_frame + max_b_frames + 
1) // too soon to poll
+if(ctx->submitted_frame <= ctx->encoded_frame + output_delay) 
// too soon to poll
 return ret;
 }
 }

---

Summary of changes:
 libavcodec/amfenc.c | 10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. ce9d181444 avcodec/mjpegdec: Remove unnecessary reloads

2025-10-13 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  ce9d1814449d6ff6323dd1030fb4c8d1093c6744 (commit)
  from  dad06a445f9aa3c19c01d9d4f0e98e00fefcd05b (commit)


- Log -
commit ce9d1814449d6ff6323dd1030fb4c8d1093c6744
Author: Andreas Rheinhardt 
AuthorDate: Wed Oct 8 03:12:19 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Sat Oct 11 08:20:42 2025 +0200

avcodec/mjpegdec: Remove unnecessary reloads

Hint: The parts of this patch in decode_block_progressive()
and decode_block_refinement() rely on the fact that GET_VLC
returns -1 on error, so that it enters the codepaths for
actually coded block coefficients.

Reviewed-by: Ramiro Polla 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/mjpegdec.c b/libavcodec/mjpegdec.c
index 69bc003490..5fd77073da 100644
--- a/libavcodec/mjpegdec.c
+++ b/libavcodec/mjpegdec.c
@@ -854,9 +854,9 @@ static int decode_block(MJpegDecodeContext *s, int16_t 
*block, int component,
 i += ((unsigned)code) >> 4;
 code &= 0xf;
 if (code) {
-if (code > MIN_CACHE_BITS - 16)
-UPDATE_CACHE(re, &s->gb);
-
+// GET_VLC updates the cache if parsing reaches the second stage.
+// So we have at least MIN_CACHE_BITS - 9 > 15 bits left here
+// and don't need to refill the cache.
 {
 int cache = GET_CACHE(re, &s->gb);
 int sign  = (~cache) >> 31;
@@ -918,8 +918,6 @@ static int decode_block_progressive(MJpegDecodeContext *s, 
int16_t *block,
 code &= 0xF;
 if (code) {
 i += run;
-if (code > MIN_CACHE_BITS - 16)
-UPDATE_CACHE(re, &s->gb);
 
 {
 int cache = GET_CACHE(re, &s->gb);
@@ -950,7 +948,8 @@ static int decode_block_progressive(MJpegDecodeContext *s, 
int16_t *block,
 } else {
 val = (1 << run);
 if (run) {
-UPDATE_CACHE(re, &s->gb);
+// Given that GET_VLC reloads internally, we always
+// have at least 16 bits in the cache here.
 val += NEG_USR32(GET_CACHE(re, &s->gb), run);
 LAST_SKIP_BITS(re, &s->gb, run);
 }
@@ -1012,7 +1011,6 @@ static int decode_block_refinement(MJpegDecodeContext *s, 
int16_t *block,
 
 if (code & 0xF) {
 run = ((unsigned) code) >> 4;
-UPDATE_CACHE(re, &s->gb);
 val = SHOW_UBITS(re, &s->gb, 1);
 LAST_SKIP_BITS(re, &s->gb, 1);
 ZERO_RUN;
@@ -1033,7 +1031,8 @@ static int decode_block_refinement(MJpegDecodeContext *s, 
int16_t *block,
 val = run;
 run = (1 << run);
 if (val) {
-UPDATE_CACHE(re, &s->gb);
+// Given that GET_VLC reloads internally, we always
+// have at least 16 bits in the cache here.
 run += SHOW_UBITS(re, &s->gb, val);
 LAST_SKIP_BITS(re, &s->gb, val);
 }

---

Summary of changes:
 libavcodec/mjpegdec.c | 15 +++
 1 file changed, 7 insertions(+), 8 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 6b961f5963 avformat/mov: fix missing video size when some decoders are disabled

2025-10-14 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  6b961f5963d8e362137702d38a744b45fba8ba3a (commit)
  from  a24e0f536dc1056756ad56775a3d1564a2cb0a3f (commit)


- Log -
commit 6b961f5963d8e362137702d38a744b45fba8ba3a
Author: Zhao Zhili 
AuthorDate: Wed Oct 8 23:31:11 2025 +0800
Commit: Zhao Zhili 
CommitDate: Tue Oct 14 20:05:55 2025 +0800

avformat/mov: fix missing video size when some decoders are disabled

Fix #20667

Signed-off-by: Zhao Zhili 

diff --git a/libavformat/mov.c b/libavformat/mov.c
index 7fe4678234..922e001e5e 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -5243,16 +5243,22 @@ static int mov_read_trak(MOVContext *c, AVIOContext 
*pb, MOVAtom atom)
 #endif
 }
 
+#if CONFIG_H261_DECODER || CONFIG_H263_DECODER || CONFIG_MPEG4_DECODER
 switch (st->codecpar->codec_id) {
+#if CONFIG_H261_DECODER
 case AV_CODEC_ID_H261:
+#endif
+#if CONFIG_H263_DECODER
 case AV_CODEC_ID_H263:
+#endif
+#if CONFIG_MPEG4_DECODER
 case AV_CODEC_ID_MPEG4:
+#endif
 st->codecpar->width = 0; /* let decoder init width/height */
 st->codecpar->height= 0;
 break;
-default:
-break;
 }
+#endif
 
 // If the duration of the mp3 packets is not constant, then they could 
need a parser
 if (st->codecpar->codec_id == AV_CODEC_ID_MP3

---

Summary of changes:
 libavformat/mov.c | 10 --
 1 file changed, 8 insertions(+), 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 20051ed3af avcodec/vulkan_encode_av1: fix level index

2025-10-16 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  20051ed3af4c8c355b8749d7b59593fc9a56bf80 (commit)
  from  62d43ba2e3c5832cd70c2e852e0e416c7c74fb02 (commit)


- Log -
commit 20051ed3af4c8c355b8749d7b59593fc9a56bf80
Author: Michael Yang 
AuthorDate: Thu Oct 9 12:14:36 2025 +1100
Commit: Lynne 
CommitDate: Thu Oct 16 21:59:24 2025 +

avcodec/vulkan_encode_av1: fix level index

diff --git a/libavcodec/vulkan_encode_av1.c b/libavcodec/vulkan_encode_av1.c
index 08ffbfa393..bb47ddd7f1 100644
--- a/libavcodec/vulkan_encode_av1.c
+++ b/libavcodec/vulkan_encode_av1.c
@@ -605,7 +605,7 @@ static int init_profile(AVCodecContext *avctx,
enc->tile_cols, framerate);
 if (level) {
 av_log(avctx, AV_LOG_VERBOSE, "Using level %s.\n", level->name);
-enc->seq_level_idx = ff_vk_av1_level_to_vk(level->level_idx);
+enc->seq_level_idx = level->level_idx;
 } else {
 av_log(avctx, AV_LOG_VERBOSE, "Stream will not conform to "
"any normal level, using level 7.3 by default.\n");

---

Summary of changes:
 libavcodec/vulkan_encode_av1.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. d91b1559e0 avcodec/x86/me_cmp: Replace MMXEXT size 16 funcs by unaligned SSE2 funcs

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  d91b1559e0f61b7ee486c46854013d6c9ddb3e84 (commit)
   via  69a700043d79517b3b1896e2a737d07801150cdf (commit)
   via  20c4608af84f96692fe6e912eea22a2f6ee92297 (commit)
  from  20051ed3af4c8c355b8749d7b59593fc9a56bf80 (commit)


- Log -
commit d91b1559e0f61b7ee486c46854013d6c9ddb3e84
Author: Andreas Rheinhardt 
AuthorDate: Tue Oct 14 10:33:18 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Fri Oct 17 13:05:07 2025 +0200

avcodec/x86/me_cmp: Replace MMXEXT size 16 funcs by unaligned SSE2 funcs

Snow calls some of the me_cmp_funcs with insufficient alignment
for the first pointer (see get_block_rd() in snowenc.c);
therefore SSE2 functions which really need this alignment
don't get set for Snow and 542765ce3eccbca587d54262a512cbdb1407230d
consequently didn't remove MMXEXT functions which are overridden
by these SSE2 functions for normal codecs.

For reference, here is a command line which would segfault
if one simply used the ordinary SSE2 functions for Snow:

./ffmpeg -i mm-short.mpg -an -vcodec snow -t 0.2 -pix_fmt yuv444p \
-vstrict -2 -qscale 2 -flags +qpel -motion_est iter 444iter.avi

This commit adds unaligned SSE2 versions of these functions
and removes the MMXEXT ones. This in particular implies that
sad 16x16 now never uses MMX which allows to remove an emms_c
from ac3enc.c.

Benchmarks (u means unaligned version):
sad_0_c: 8.2 ( 1.00x)
sad_0_mmxext:   10.8 ( 0.76x)
sad_0_sse2:  6.2 ( 1.33x)
sad_0_sse2u: 6.7 ( 1.23x)

vsad_0_c:   44.7 ( 1.00x)
vsad_0_mmxext (approx): 12.2 ( 3.68x)
vsad_0_sse2 (approx):7.8 ( 5.75x)

vsad_4_c:   88.4 ( 1.00x)
vsad_4_mmxext:   7.1 (12.46x)
vsad_4_sse2: 4.2 (21.15x)
vsad_4_sse2u:5.5 (15.96x)

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/ac3enc.c b/libavcodec/ac3enc.c
index a316d4e4d7..5a1a3ab63a 100644
--- a/libavcodec/ac3enc.c
+++ b/libavcodec/ac3enc.c
@@ -32,7 +32,6 @@
 #include "libavutil/avassert.h"
 #include "libavutil/channel_layout.h"
 #include "libavutil/crc.h"
-#include "libavutil/emms.h"
 #include "libavutil/internal.h"
 #include "libavutil/mem.h"
 #include "libavutil/mem_internal.h"
@@ -945,8 +944,6 @@ static void ac3_process_exponents(AC3EncodeContext *s)
 compute_exp_strategy(s);
 
 encode_exponents(s);
-
-emms_c();
 }
 
 
diff --git a/libavcodec/x86/me_cmp.asm b/libavcodec/x86/me_cmp.asm
index 8f2d0a6ddf..7825c8ef71 100644
--- a/libavcodec/x86/me_cmp.asm
+++ b/libavcodec/x86/me_cmp.asm
@@ -467,22 +467,25 @@ HF_NOISE 16
 
;---
 ;int ff_sad_(MPVEncContext *v, const uint8_t *pix1, const uint8_t *pix2, 
ptrdiff_t stride, int h);
 
;---
-;%1 = 8/16
-%macro SAD 1
-cglobal sad%1, 5, 5, 3, v, pix1, pix2, stride, h
+;%1 = 8/16, %2 = a/u (whether pix1 is aligned or not)
+%macro SAD 1-2
+%ifidn %2, u
+cglobal sad%1u, 5, 5, 5, v, pix1, pix2, stride, h
+%else
+cglobal sad%1,  5, 5, 3, v, pix1, pix2, stride, h
+%endif
 movu  m2, [pix2q]
 movu  m1, [pix2q+strideq]
+%ifidn %2, u
+movu  m0, [pix1q]
+movu  m3, [pix1q+strideq]
+psadbwm2, m0
+psadbwm1, m3
+%else
 psadbwm2, [pix1q]
 psadbwm1, [pix1q+strideq]
-paddw m2, m1
-%if %1 != mmsize
-movu  m0, [pix2q+8]
-movu  m1, [pix2q+strideq+8]
-psadbwm0, [pix1q+8]
-psadbwm1, [pix1q+strideq+8]
-paddw m2, m0
-paddw m2, m1
 %endif
+paddw m2, m1
 sub   hd, 2
 
 align 16
@@ -491,18 +494,17 @@ align 16
 leapix2q, [pix2q+strideq*2]
 movu  m0, [pix2q]
 movu  m1, [pix2q+strideq]
+%ifidn %2, u
+movu  m3, [pix1q]
+movu  m4, [pix1q+strideq]
+psadbwm0, m3
+psadbwm1, m4
+%else
 psadbwm0, [pix1q]
 psadbwm1, [pix1q+strideq]
+%endif
 paddw m2, m0
 paddw m2, m1
-%if %1 != mmsize
-movu  m0, [pix2q+8]
-movu  m1, [pix2q+strideq+8]
-psadbwm0, [pix1q+8]
-psadbwm1, [pix1q+strideq+8]
-paddw m2, m0
-paddw m2, m1
-%endif
 sub   hd, 2
 jg .loop
 %if mmsize == 16
@@ -515,9 +517,9 @@ align 16
 
 INIT_MMX mmxext
 SAD 8
-SAD 16
 INIT_XMM sse2
 SAD 16
+SAD 16, u
 
 
;-

[FFmpeg-cvslog] [ffmpeg-web] branch master updated. 9a0b0a6 web/security: Add CVE# that ubuntu has listed yesterday

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  9a0b0a64ae42668225bc007472c9993b3c4b6cdc (commit)
  from  98c5740f14cfe8c2b7fdfe81d691e2aa0b13a4c0 (commit)


- Log -
commit 9a0b0a64ae42668225bc007472c9993b3c4b6cdc
Author: Michael Niedermayer 
AuthorDate: Fri Oct 17 16:24:40 2025 +0200
Commit: Michael Niedermayer 
CommitDate: Fri Oct 17 16:24:40 2025 +0200

web/security: Add CVE# that ubuntu has listed yesterday

These are CVE#s from USN-7823-1,

Information mappping these to commits is from debian and NIST

diff --git a/src/security b/src/security
index ea64661..0d5f8dd 100644
--- a/src/security
+++ b/src/security
@@ -73,6 +73,7 @@ Fixes following vulnerabilities:
 
 CVE-2024-7055 3faadbe2a27e74ff5bb5f7904ec27bb1f5287dc8
 CVE-2024-35368, 4513300989502090c4fd6560544dce399a8cd53c (specific to builds 
with --enable-rkmpp)
+CVE-2024-36619, 28c7094b25b689185155a6833caf2747b94774a4
 
 
 
@@ -114,8 +115,13 @@ CVE-2023-50008, 5f87a68cf70dafeab2fb89b42e41a4c29053b89b, 
ticket/10701
 CVE-2024-28661, 66b50445cb36cf6adb49c2397362509aedb42c71
 CVE-2024-31578, 3bb00c0a420c3ce83c6fafee30270d69622ccad7
 CVE-2024-31582, 99debe5f823f45a482e1dc08de35879aa9c74bd2
+CVE-2024-35365, ced5c5fdb8634d39ca9472a2026b2d2fea16c4e5
+CVE-2024-35366, 0bed22d597b78999151e3bde0768b7fe763fc2a6
 CVE-2024-35367, 09e6840cf7a3ee07a73c3ae88a020bf27ca1a667 (specific to builds 
for ppc with altivec)
+CVE-2024-36613, 50d8e4f27398fd5778485a827d7a2817921f8540
+CVE-2024-36616, 86f73277bf014e2ce36dd2594f1e0fb8b3bd6661
 CVE-2024-36617, d973fcbcc2f944752ff10e6a76b0b2d9329937a7
+CVE-2024-36618, 7a089ed8e049e3bfcb22de1250b86f2106060857
 
 
 
@@ -226,6 +232,9 @@ CVE-2024-7272, a937b3c58babae893fb46b286a4792cd24a01d3d / 
9903ba28c28ab18dc7b7b6
 Fixes following vulnerabilities:
 
 
+CVE-2024-35366, 4db0eb4653efad967ddcf71f564fd2f1169bafcb / 
0bed22d597b78999151e3bde0768b7fe763fc2a6
+CVE-2024-36613, 1f6fcc64179377114b4ecc3b9f63bd5774a64edf / 
50d8e4f27398fd5778485a827d7a2817921f8540
+CVE-2024-36616, a8beef67993aa267de87599007143d9f0ba67c23 / 
86f73277bf014e2ce36dd2594f1e0fb8b3bd6661
 CVE-2024-36617, f0e780370cc1c437d64f10d326b1d656ef490b5f / 
d973fcbcc2f944752ff10e6a76b0b2d9329937a7
 
 
@@ -431,7 +440,10 @@ Fixes following vulnerabilities:
 CVE-2023-47342, 0077a817a1dd83790f674c3b5078b2dba106d228 / 
e4d5ac8d7d2a08658b3db7dd821246fe6b35381f
 CVE-2022-48434, 031c9601d06759a748adc077f73e3005b5571be1 / 
d4b7b3c03ee2baf0166ce49dff17ec9beff684db
 CVE-2022-3341,  d811434b5d731c0fad2eb5fbf3fc3e53df98ae67 / 
9cf652cef49d74afe3d454f27d49eb1a1394951e
+CVE-2024-36613, 42f495fbe1b32c316103f52732ce6726bc032227 / 
50d8e4f27398fd5778485a827d7a2817921f8540
+CVE-2024-36616, 251b3c3892e79bd9dd93a973d16c28667fde131e / 
86f73277bf014e2ce36dd2594f1e0fb8b3bd6661
 CVE-2024-36617, 9557810a81624f222d603e0fdf3778054f8d8cc4 / 
d973fcbcc2f944752ff10e6a76b0b2d9329937a7
+CVE-2024-35366, 21b8fbf060e5fef52c9d6380398487486eeca2ce / 
0bed22d597b78999151e3bde0768b7fe763fc2a6
 
 
 4.3.6

---

Summary of changes:
 src/security | 12 
 1 file changed, 12 insertions(+)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. d96f8d32ad avcodec/x86/h264_qpel: Don't instantiate unused functions

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  d96f8d32adfd4ea08c276cd2b6f10e7a3caf06fc (commit)
  from  6f1ab828d3da168d28c65c03b80ad89a61c19d06 (commit)


- Log -
commit d96f8d32adfd4ea08c276cd2b6f10e7a3caf06fc
Author: Andreas Rheinhardt 
AuthorDate: Fri Oct 10 16:21:25 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Fri Oct 10 16:27:57 2025 +0200

avcodec/x86/h264_qpel: Don't instantiate unused functions

The v_lowpass wrappers (which are instantiated by this macro)
are only used in the put (and not the avg) form for SSSE3
(the avg form is only used for mc02, which doesn't exist
for SSSE3). Clang warns about the unused functions.

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/x86/h264_qpel.c b/libavcodec/x86/h264_qpel.c
index c8f6726508..5d1445a8bb 100644
--- a/libavcodec/x86/h264_qpel.c
+++ b/libavcodec/x86/h264_qpel.c
@@ -293,7 +293,6 @@ QPEL_H264_HV_XMM(avg_, sse2)
 QPEL_H264_H_XMM(put_, ssse3)
 QPEL_H264_H_XMM(avg_, ssse3)
 QPEL_H264_V_XMM(put_, ssse3, sse2)
-QPEL_H264_V_XMM(avg_, ssse3, sse2)
 QPEL_H264_HV_XMM(put_, ssse3)
 QPEL_H264_HV_XMM(avg_, ssse3)
 

---

Summary of changes:
 libavcodec/x86/h264_qpel.c | 1 -
 1 file changed, 1 deletion(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. a45d30a675 avutil/hwcontext_vulkan: always enable baseline usage flags

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  a45d30a67579f00926525ffd23c7a6b5470d77a0 (commit)
  from  b1f2eea1cd72f6ba01d2a3303462b9717a0d043a (commit)


- Log -
commit a45d30a67579f00926525ffd23c7a6b5470d77a0
Author: Niklas Haas 
AuthorDate: Wed Aug 20 16:56:22 2025 +0200
Commit: Lynne 
CommitDate: Thu Oct 16 17:40:25 2025 +

avutil/hwcontext_vulkan: always enable baseline usage flags

The documentation states that this field is for enabling "extra" usage
flags. This conflicts with the implementation, and the rest of the comment,
though.

In resolving this ambiguity, I think it's better to lean towards the first
sentence and treat this field purely as specifying *extra* usage flags to
enable. Otherwise, this may break vulkan encoding or subsequent hwdownload
if the upstream filter did not specifically advertise this.

Change the default behavior and update the documentation slightly to more
clearly document the semantics.

diff --git a/libavutil/hwcontext_vulkan.c b/libavutil/hwcontext_vulkan.c
index 286e13c509..ae4b07c698 100644
--- a/libavutil/hwcontext_vulkan.c
+++ b/libavutil/hwcontext_vulkan.c
@@ -2901,21 +2901,19 @@ static int vulkan_frames_init(AVHWFramesContext *hwfc)
 supported_usage &= ~VK_IMAGE_USAGE_HOST_TRANSFER_BIT_EXT;
 
 /* Image usage flags */
-if (!hwctx->usage) {
-hwctx->usage = supported_usage & (VK_IMAGE_USAGE_TRANSFER_DST_BIT |
-  VK_IMAGE_USAGE_TRANSFER_SRC_BIT |
-  VK_IMAGE_USAGE_STORAGE_BIT  |
-  VK_IMAGE_USAGE_SAMPLED_BIT);
-
-if ((p->vkctx.extensions & FF_VK_EXT_HOST_IMAGE_COPY) && 
!p->disable_host_transfer)
-hwctx->usage |= supported_usage & 
VK_IMAGE_USAGE_HOST_TRANSFER_BIT_EXT;
-
-/* Enables encoding of images, if supported by format and extensions */
-if ((supported_usage & VK_IMAGE_USAGE_VIDEO_ENCODE_SRC_BIT_KHR) &&
-(p->vkctx.extensions & (FF_VK_EXT_VIDEO_ENCODE_QUEUE |
-   FF_VK_EXT_VIDEO_MAINTENANCE_1)))
-hwctx->usage |= VK_IMAGE_USAGE_VIDEO_ENCODE_SRC_BIT_KHR;
-}
+hwctx->usage |= supported_usage & (VK_IMAGE_USAGE_TRANSFER_DST_BIT |
+   VK_IMAGE_USAGE_TRANSFER_SRC_BIT |
+   VK_IMAGE_USAGE_STORAGE_BIT  |
+   VK_IMAGE_USAGE_SAMPLED_BIT);
+
+if ((p->vkctx.extensions & FF_VK_EXT_HOST_IMAGE_COPY) && 
!p->disable_host_transfer)
+hwctx->usage |= supported_usage & VK_IMAGE_USAGE_HOST_TRANSFER_BIT_EXT;
+
+/* Enables encoding of images, if supported by format and extensions */
+if ((supported_usage & VK_IMAGE_USAGE_VIDEO_ENCODE_SRC_BIT_KHR) &&
+(p->vkctx.extensions & (FF_VK_EXT_VIDEO_ENCODE_QUEUE |
+FF_VK_EXT_VIDEO_MAINTENANCE_1)))
+hwctx->usage |= VK_IMAGE_USAGE_VIDEO_ENCODE_SRC_BIT_KHR;
 
 /* Image creation flags.
  * Only fill them in automatically if the image is not going to be used as
diff --git a/libavutil/hwcontext_vulkan.h b/libavutil/hwcontext_vulkan.h
index 15cf515668..0bb536ab3f 100644
--- a/libavutil/hwcontext_vulkan.h
+++ b/libavutil/hwcontext_vulkan.h
@@ -218,7 +218,8 @@ typedef struct AVVulkanFramesContext {
 
 /**
  * Defines extra usage of output frames. If non-zero, all flags MUST be
- * supported by the VkFormat. Otherwise, will use supported flags amongst:
+ * supported by the VkFormat. Regardless, frames will always have the
+ * following usage flags enabled, if supported by the format:
  * - VK_IMAGE_USAGE_SAMPLED_BIT
  * - VK_IMAGE_USAGE_STORAGE_BIT
  * - VK_IMAGE_USAGE_TRANSFER_SRC_BIT

---

Summary of changes:
 libavutil/hwcontext_vulkan.c | 28 +---
 libavutil/hwcontext_vulkan.h |  3 ++-
 2 files changed, 15 insertions(+), 16 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 6231fa7fb7 avcodec/av1dec: don't emit a warning when parsing isobmff style extradata

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  6231fa7fb7c196d374420feb19854f661c5e9b85 (commit)
  from  78a16e42bdb7faa6d5180b7ecf34c8f8ad0dc2c5 (commit)


- Log -
commit 6231fa7fb7c196d374420feb19854f661c5e9b85
Author: James Almer 
AuthorDate: Sun Oct 5 22:23:51 2025 -0300
Commit: James Almer 
CommitDate: Sun Oct 5 22:23:51 2025 -0300

avcodec/av1dec: don't emit a warning when parsing isobmff style extradata

No OBUs may be present and it's a valid scenario, so only warn when parsing 
raw
extradata.

Signed-off-by: James Almer 

diff --git a/libavcodec/av1dec.c b/libavcodec/av1dec.c
index 37349f4add..d4ceb5ef09 100644
--- a/libavcodec/av1dec.c
+++ b/libavcodec/av1dec.c
@@ -893,7 +893,8 @@ static av_cold int av1_decode_init(AVCodecContext *avctx)
 
 seq = ((CodedBitstreamAV1Context 
*)(s->cbc->priv_data))->sequence_header;
 if (!seq) {
-av_log(avctx, AV_LOG_WARNING, "No sequence header available.\n");
+if (!(avctx->extradata[0] & 0x80))
+av_log(avctx, AV_LOG_WARNING, "No sequence header available in 
extradata.\n");
 goto end;
 }
 

---

Summary of changes:
 libavcodec/av1dec.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. ab7d1c64c9 avcodec/x86/h263_loopfilter: Port loop filter to SSE2

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  ab7d1c64c9aa9186acb1d988d020e59f2d3defce (commit)
   via  a8a16c15c8dbf2231d439fa46587d0a15c1778ce (commit)
  from  df4587789f1f4337ed778752010d7176a9e90241 (commit)


- Log -
commit ab7d1c64c9aa9186acb1d988d020e59f2d3defce
Author: Andreas Rheinhardt 
AuthorDate: Wed Oct 1 10:46:39 2025 +0200
Commit: James Almer 
CommitDate: Fri Oct 3 17:05:46 2025 +

avcodec/x86/h263_loopfilter: Port loop filter to SSE2

Old benchmarks:
h263dsp.h_loop_filter_c:41.2 ( 1.00x)
h263dsp.h_loop_filter_mmx:  39.5 ( 1.04x)
h263dsp.v_loop_filter_c:43.5 ( 1.00x)
h263dsp.v_loop_filter_mmx:  16.9 ( 2.57x)

New benchmarks:
h263dsp.h_loop_filter_c:41.6 ( 1.00x)
h263dsp.h_loop_filter_sse2: 28.2 ( 1.48x)
h263dsp.v_loop_filter_c:42.4 ( 1.00x)
h263dsp.v_loop_filter_sse2: 15.1 ( 2.81x)

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/x86/constants.c b/libavcodec/x86/constants.c
index c5f3c6428e..1e2f5990e4 100644
--- a/libavcodec/x86/constants.c
+++ b/libavcodec/x86/constants.c
@@ -75,7 +75,7 @@ DECLARE_ALIGNED(32, const ymm_reg,  ff_pb_80)   = { 
0x8080808080808080ULL, 0x808
 0x8080808080808080ULL, 
0x8080808080808080ULL };
 DECLARE_ALIGNED(32, const ymm_reg,  ff_pb_FE)   = { 0xFEFEFEFEFEFEFEFEULL, 
0xFEFEFEFEFEFEFEFEULL,
 0xFEFEFEFEFEFEFEFEULL, 
0xFEFEFEFEFEFEFEFEULL };
-DECLARE_ALIGNED(8,  const uint64_t, ff_pb_FC)   =   0xFCFCFCFCFCFCFCFCULL;
+DECLARE_ALIGNED(16, const xmm_reg,  ff_pb_FC)   = { 0xFCFCFCFCFCFCFCFCULL, 
0xFCFCFCFCFCFCFCFCULL };
 
 DECLARE_ALIGNED(16, const xmm_reg,  ff_ps_neg)  = { 0x80008000ULL, 
0x80008000ULL };
 
diff --git a/libavcodec/x86/constants.h b/libavcodec/x86/constants.h
index 4a55adb5b3..7d0bd975b9 100644
--- a/libavcodec/x86/constants.h
+++ b/libavcodec/x86/constants.h
@@ -56,8 +56,8 @@ extern const ymm_reg  ff_pb_1;
 extern const ymm_reg  ff_pb_2;
 extern const ymm_reg  ff_pb_3;
 extern const ymm_reg  ff_pb_80;
+extern const xmm_reg  ff_pb_FC;
 extern const ymm_reg  ff_pb_FE;
-extern const uint64_t ff_pb_FC;
 
 extern const xmm_reg  ff_ps_neg;
 
diff --git a/libavcodec/x86/h263_loopfilter.asm 
b/libavcodec/x86/h263_loopfilter.asm
index 77c8cf154d..ebe76f01af 100644
--- a/libavcodec/x86/h263_loopfilter.asm
+++ b/libavcodec/x86/h263_loopfilter.asm
@@ -1,5 +1,5 @@
 ;**
-;* MMX-optimized H.263 loop filter
+;* SSE2-optimized H.263 loop filter
 ;* Copyright (c) 2003-2013 Michael Niedermayer
 ;* Copyright (c) 2013 Daniel Kang
 ;*
@@ -22,7 +22,6 @@
 
 %include "libavutil/x86/x86util.asm"
 
-SECTION_RODATA
 cextern pb_FC
 cextern h263_loop_filter_strength
 
@@ -30,60 +29,45 @@ SECTION .text
 
 %macro H263_LOOP_FILTER 5
 pxor m7, m7
-mova m0, [%1]
-mova m1, [%1]
-mova m2, [%4]
-mova m3, [%4]
+movq m0, [%1]
+movq m6, [%4]
+mova m5, m0
 punpcklbwm0, m7
-punpckhbwm1, m7
-punpcklbwm2, m7
-punpckhbwm3, m7
-psubwm0, m2
-psubwm1, m3
-mova m2, [%2]
-mova m3, [%2]
-mova m4, [%3]
-mova m5, [%3]
+punpcklbwm6, m7
+psubwm0, m6
+movq m2, [%2]
+movq m1, [%3]
+mova m3, m2
+mova m4, m1
 punpcklbwm2, m7
-punpckhbwm3, m7
-punpcklbwm4, m7
-punpckhbwm5, m7
-psubwm4, m2
-psubwm5, m3
-psllwm4, 2
-psllwm5, 2
-paddwm4, m0
-paddwm5, m1
+punpcklbwm1, m7
+psubwm1, m2
+psllwm1, 2
+paddwm1, m0
 pxor m6, m6
-pcmpgtw  m6, m4
-pcmpgtw  m7, m5
-pxor m4, m6
-pxor m5, m7
-psubwm4, m6
-psubwm5, m7
-psrlwm4, 3
-psrlwm5, 3
-packuswb m4, m5
+pcmpgtw  m6, m1
+pxor m1, m6
+psubwm1, m6
+psrlwm1, 3
+packuswb m1, m7
 packsswb m6, m7
-pxor m7, m7
 movd m2, %5
 punpcklbwm2, m2
 punpcklbwm2, m2
 punpcklbwm2, m2
-psubusb  m2, m4
-mova m3, m2
-psubusb  m3, m4
-psubbm2, m3
-mova m3, [%2]
-mova m4, [%3]
+psubusb  m2, m1
+mova m7, m2
+psubusb  m7, m1
+psubbm2, m7
 pxor m3, m6
 pxor m4, m6
 p

[FFmpeg-cvslog] [ffmpeg] branch master updated. e05f8acabf avfilter/blend_modes: Don't build duplicate functions

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  e05f8acabff468c1382277c1f31fa8e9d90c3202 (commit)
   via  ea346a23de428930fcd9cc0666150f35e04cb902 (commit)
  from  8fad52bd57d5bcedce8dc4ae3166c1a50f895690 (commit)


- Log -
commit e05f8acabff468c1382277c1f31fa8e9d90c3202
Author: Andreas Rheinhardt 
AuthorDate: Wed Oct 1 08:27:14 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Sat Oct 4 17:49:08 2025 +0200

avfilter/blend_modes: Don't build duplicate functions

Some of the blend mode functions only depend on the underlying type
and therefore need only one version for 9, 10, 12, 14, 16 bits.
This saved 35104B with GCC and 26880B with Clang.

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavfilter/blend_modes.c b/libavfilter/blend_modes.c
index 35e365996c..981c15a025 100644
--- a/libavfilter/blend_modes.c
+++ b/libavfilter/blend_modes.c
@@ -34,16 +34,21 @@
 #define MAX 255
 #define HALF 128
 #define CLIP(x) (av_clip_uint8(x))
+#define BUILD_TYPE_SPECIFIC_FUNCS
 #elif DEPTH == 32
 #define PIXEL float
 #define MAX 1.f
 #define HALF 0.5f
 #define CLIP(x) (x)
+#define BUILD_TYPE_SPECIFIC_FUNCS
 #else
 #define PIXEL uint16_t
 #define MAX ((1 << DEPTH) - 1)
 #define HALF (1 << (DEPTH - 1))
 #define CLIP(x) ((int)av_clip_uintp2(x, DEPTH))
+#if DEPTH == 16
+#define BUILD_TYPE_SPECIFIC_FUNCS
+#endif
 #endif
 
 #undef MULTIPLY
@@ -109,13 +114,10 @@ static void fn0(NAME)(const uint8_t *_top, ptrdiff_t 
top_linesize, \
 
 fn(addition,   FFMIN(MAX, A + B))
 fn(grainmerge, CLIP(A + B - HALF))
-fn(average,(A + B) / 2)
-fn(subtract,   FFMAX(0, A - B))
 fn(multiply,   MULTIPLY(1, A, B))
 fn(multiply128,CLIP((A - HALF) * B / MDIV + HALF))
 fn(negation,   MAX - FFABS(MAX - A - B))
 fn(extremity,  FFABS(MAX - A - B))
-fn(difference, FFABS(A - B))
 fn(grainextract, CLIP(HALF + A - B))
 fn(screen, SCREEN(1, A, B))
 fn(overlay,(A < HALF) ? MULTIPLY(2, A, B) : SCREEN(2, A, B))
@@ -123,8 +125,6 @@ fn(hardlight,  (B < HALF) ? MULTIPLY(2, B, A) : SCREEN(2, 
B, A))
 fn(hardmix,(A < (MAX - B)) ? 0: MAX)
 fn(heat,   (A == 0) ? 0 : MAX - FFMIN(((MAX - B) * (MAX - B)) / A, MAX))
 fn(freeze, (B == 0) ? 0 : MAX - FFMIN(((MAX - A) * (MAX - A)) / B, MAX))
-fn(darken, FFMIN(A, B))
-fn(lighten,FFMAX(A, B))
 fn(divide, CLIP(B == 0 ? MAX : MAX * A / B))
 fn(dodge,  DODGE(A, B))
 fn(burn,   BURN(A, B))
@@ -134,15 +134,24 @@ fn(pinlight,   (B < HALF) ? FFMIN(A, 2 * B) : FFMAX(A, 2 
* (B - HALF)))
 fn(phoenix,FFMIN(A, B) - FFMAX(A, B) + MAX)
 fn(reflect,(B == MAX) ? B : FFMIN(MAX, (A * A / (MAX - B
 fn(glow,   (A == MAX) ? A : FFMIN(MAX, (B * B / (MAX - A
-fn(and,INT2FLOAT(FLOAT2INT(A) & FLOAT2INT(B)))
-fn(or, INT2FLOAT(FLOAT2INT(A) | FLOAT2INT(B)))
-fn(xor,INT2FLOAT(FLOAT2INT(A) ^ FLOAT2INT(B)))
 fn(vividlight, (A < HALF) ? BURN(2 * A, B) : DODGE(2 * (A - HALF), B))
 fn(linearlight,CLIP((B < HALF) ? B + 2 * A - MAX : B + 2 * (A - HALF)))
 fn(softdifference,CLIP((A > B) ? (B == MAX) ? 0 : (A - B) * MAX / (MAX - B) : 
(B == 0) ? 0 : (B - A) * MAX / B))
-fn(geometric,  GEOMETRIC(A, B))
-fn(harmonic,   A == 0 && B == 0 ? 0 : 2LL * A * B / (A + B))
 fn(bleach, (MAX - B) + (MAX - A) - MAX)
 fn(stain,  2 * MAX - A - B)
 fn(interpolate,LRINTF(MAX * (2 - cosf(A * M_PI / MAX) - cosf(B * M_PI / MAX)) 
* 0.25f))
 fn(hardoverlay,A == MAX ? MAX : FFMIN(MAX, MAX * B / (2 * MAX - 2 * A) * (A > 
HALF) + 2 * A * B / MAX * (A <= HALF)))
+
+#ifdef BUILD_TYPE_SPECIFIC_FUNCS
+fn(average,(A + B) / 2)
+fn(subtract,   FFMAX(0, A - B))
+fn(difference, FFABS(A - B))
+fn(darken, FFMIN(A, B))
+fn(lighten,FFMAX(A, B))
+fn(and,INT2FLOAT(FLOAT2INT(A) & FLOAT2INT(B)))
+fn(or, INT2FLOAT(FLOAT2INT(A) | FLOAT2INT(B)))
+fn(xor,INT2FLOAT(FLOAT2INT(A) ^ FLOAT2INT(B)))
+fn(geometric,  GEOMETRIC(A, B))
+fn(harmonic,   A == 0 && B == 0 ? 0 : 2LL * A * B / (A + B))
+#undef BUILD_TYPE_SPECIFIC_FUNCS
+#endif
diff --git a/libavfilter/vf_blend_init.h b/libavfilter/vf_blend_init.h
index 7f66796e3e..297ca0514f 100644
--- a/libavfilter/vf_blend_init.h
+++ b/libavfilter/vf_blend_init.h
@@ -107,11 +107,11 @@ static av_cold void 
init_blend_func_##depth##_##nbits##bit(FilterParams *param)
 switch (param->mode) { 
   \
 case BLEND_ADDITION: param->blend = blend_addition_##depth##bit; 
break;   \
 case BLEND_GRAINMERGE:   param->blend = blend_grainmerge_##depth##bit;   
break;   \
-case BLEND_AND:  param->blend = blend_and_##depth##bit;  
break;   \
-case BLEND_AVERAGE:  param->blend = blend_average_##depth##bit;  
break;   \
+case BLEND_AND:  param->blend = blend_and_##nbits##bit;  
break;   \
+case BLEND_AVERAGE:  param->blend = blend_average_##nbits##bit;  
break;   \
 case BLEND_BURN: param->blend = blend_bu

[FFmpeg-cvslog] [ffmpeg] branch master updated. 660983b7f3 avformat/mccenc: use Lavf version string instead of FFmpeg

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  660983b7f3f699cd982a0688352604cc9ce3c8c6 (commit)
  from  6231fa7fb7c196d374420feb19854f661c5e9b85 (commit)


- Log -
commit 660983b7f3f699cd982a0688352604cc9ce3c8c6
Author: James Almer 
AuthorDate: Mon Oct 6 10:32:15 2025 -0300
Commit: James Almer 
CommitDate: Mon Oct 6 11:51:50 2025 -0300

avformat/mccenc: use Lavf version string instead of FFmpeg

The muxed subtitle is created by libavformat, and as such that's what 
should be
reported. This is in line with the string we write for every other muxer.
After this change, the muxer will no longer be recompiled every time a 
commit
is made.

Signed-off-by: James Almer 

diff --git a/libavformat/mccenc.c b/libavformat/mccenc.c
index c64d53805d..1c291f75b2 100644
--- a/libavformat/mccenc.c
+++ b/libavformat/mccenc.c
@@ -23,6 +23,7 @@
 #include "avformat.h"
 #include "internal.h"
 #include "mux.h"
+#include "version.h"
 
 #include "libavcodec/codec_id.h"
 #include "libavcodec/smpte_436m.h"
@@ -30,7 +31,6 @@
 #include "libavutil/avassert.h"
 #include "libavutil/avstring.h"
 #include "libavutil/error.h"
-#include "libavutil/ffversion.h"
 #include "libavutil/log.h"
 #include "libavutil/macros.h"
 #include "libavutil/opt.h"
@@ -125,9 +125,9 @@ static int mcc_write_header(AVFormatContext *avf)
 const char *creation_program = mcc->creation_program;
 if (!creation_program) {
 if (avf->flags & AVFMT_FLAG_BITEXACT)
-creation_program = "FFmpeg";
+creation_program = "Lavf";
 else
-creation_program = "FFmpeg version " FFMPEG_VERSION;
+creation_program = LIBAVFORMAT_IDENT;
 } else if (strchr(creation_program, '\n')) {
 av_log(avf, AV_LOG_FATAL, "creation_program must not contain multiple 
lines of text\n");
 return AVERROR(EINVAL);
diff --git a/tests/fate/subtitles.mak b/tests/fate/subtitles.mak
index 8423e8311a..c8f94c2b5e 100644
--- a/tests/fate/subtitles.mak
+++ b/tests/fate/subtitles.mak
@@ -133,7 +133,7 @@ fate-sub-rcwt: REF = d86f179094a5752d68aa97d82cf887b0
 FATE_SUBTITLES-$(call ALLYES, AVDEVICE LAVFI_INDEV MOVIE_FILTER MPEGTS_DEMUXER 
MCC_MUXER EIA608_TO_SMPTE436M_BSF) += fate-sub-mcc
 fate-sub-mcc: CMD = md5 -f lavfi -i 
"movie=$(TARGET_SAMPLES)/sub/scte20.ts[out0+subcc]" -map 0:s -c copy 
-override_time_code_rate ntsc -creation_time "1970-01-02T00:00:00" -bitexact -f 
mcc
 fate-sub-mcc: CMP = oneline
-fate-sub-mcc: REF = 779ca7759324441febd6aa6039f29308
+fate-sub-mcc: REF = 73982c4db86f3a809c1e8262d3701fc2
 
 FATE_SUBTITLES-$(call DEMMUX, MCC, MCC, SMPTE436M_TO_EIA608_BSF 
EIA608_TO_SMPTE436M_BSF) += fate-sub-mcc-remux-eia608-bsf
 fate-sub-mcc-remux-eia608-bsf: CMD = fmtstdout mcc -f mcc -i 
$(SRC_PATH)/tests/ref/fate/sub-mcc-remux -map 0:s -c copy -bsf 
"eia608_to_smpte436m=cdp_frame_rate=6/1001:initial_cdp_sequence_cntr=65535:line_number=11"
 -override_time_code_rate ntsc -creation_time "1970-01-02T00:00:00"
diff --git a/tests/ref/fate/sub-mcc-remux b/tests/ref/fate/sub-mcc-remux
index a58c040711..57f8ea81d2 100644
--- a/tests/ref/fate/sub-mcc-remux
+++ b/tests/ref/fate/sub-mcc-remux
@@ -37,7 +37,7 @@ File Format=MacCaption_MCC V2.0
 
///
 
 UUID=0087C4F6-A6B4-5469-8C8E-BBF44950401D
-Creation Program=FFmpeg
+Creation Program=Lavf
 Creation Date=Friday, January 2, 1970
 Creation Time=00:00:00
 Time Code Rate=30DF
diff --git a/tests/ref/fate/sub-mcc-remux-eia608 
b/tests/ref/fate/sub-mcc-remux-eia608
index f31562d524..00f2fd4244 100644
--- a/tests/ref/fate/sub-mcc-remux-eia608
+++ b/tests/ref/fate/sub-mcc-remux-eia608
@@ -37,7 +37,7 @@ File Format=MacCaption_MCC V2.0
 
///
 
 UUID=0087C4F6-A6B4-5469-8C8E-BBF44950401D
-Creation Program=FFmpeg
+Creation Program=Lavf
 Creation Date=Friday, January 2, 1970
 Creation Time=00:00:00
 Time Code Rate=30DF
diff --git a/tests/ref/fate/sub-mcc-remux-eia608-bsf 
b/tests/ref/fate/sub-mcc-remux-eia608-bsf
index c0e125db5e..6b14302226 100644
--- a/tests/ref/fate/sub-mcc-remux-eia608-bsf
+++ b/tests/ref/fate/sub-mcc-remux-eia608-bsf
@@ -37,7 +37,7 @@ File Format=MacCaption_MCC V2.0
 
///
 
 UUID=0087C4F6-A6B4-5469-8C8E-BBF44950401D
-Creation Program=FFmpeg
+Creation Program=Lavf
 Creation Date=Friday, January 2, 1970
 Creation Time=00:00:00
 Time Code Rate=30DF
diff --git a/tests/ref/fate/sub-mcc-remux-eia608-recode 
b/tests/ref/fate/sub-mcc-remux-eia608-recode
index f31562d524..00f2fd4244 100644
--- a/tests/ref/fate/sub-mcc-remux-eia608-recode
+++ b/tests/ref/fate/sub-mcc-remux-eia608-recode
@@ -37,7 +37,7 @@ File Format=MacCaption_MCC V2.0
 
///
 
 UUID=0087C4F6-A6B4

[FFmpeg-cvslog] [ffmpeg] branch master updated. 74115b017c doc: indicate libmpeghdec is non-free

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  74115b017c3038b717162bb56346afb4ad937be3 (commit)
  from  fd1fd5850de4f3beb240422b67889bb776b26c77 (commit)


- Log -
commit 74115b017c3038b717162bb56346afb4ad937be3
Author: Gyan Doshi 
AuthorDate: Tue Sep 30 14:34:18 2025 +0530
Commit: Gyan Doshi 
CommitDate: Tue Sep 30 11:55:02 2025 +

doc: indicate libmpeghdec is non-free

diff --git a/doc/decoders.texi b/doc/decoders.texi
index 9248e2283a..1db297f42f 100644
--- a/doc/decoders.texi
+++ b/doc/decoders.texi
@@ -353,7 +353,7 @@ libmpeghdec decoder wrapper.
 libmpeghdec allows libmpeghdec to decode the MPEG-H 3D audio codec.
 Requires the presence of the libmpeghdec headers and library during
 configuration. You need to explicitly configure the build with
-@code{--enable-libmpeghdec}.
+@code{--enable-libmpeghdec --enable-nonfree}.
 
 @section libopencore-amrnb
 
diff --git a/doc/general_contents.texi b/doc/general_contents.texi
index 9608ce219a..98e35c0e8e 100644
--- a/doc/general_contents.texi
+++ b/doc/general_contents.texi
@@ -256,7 +256,7 @@ FFmpeg can make use of the Fraunhofer MPEG-H decoder 
library for MPEG-H 3DA deco
 
 Go to @url{https://github.com/Fraunhofer-IIS/mpeghdec} and follow the
 instructions for installing the library.
-Then pass @code{--enable-libmpeghdec} to configure to enable it.
+Then pass @code{--enable-libmpeghdec --enable-nonfree} to configure to enable 
it.
 
 @subsection LC3 library
 

---

Summary of changes:
 doc/decoders.texi | 2 +-
 doc/general_contents.texi | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 9034ca30ef avformat/flacdec: fix self assign warning

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  9034ca30effd6ba00977bbcbe61e7e4852e4ef2e (commit)
  from  afad332d77278232662e6d8c95c2fc80cb44c8dd (commit)


- Log -
commit 9034ca30effd6ba00977bbcbe61e7e4852e4ef2e
Author: Zhao Zhili 
AuthorDate: Mon Sep 22 00:42:02 2025 +0800
Commit: Zhao Zhili 
CommitDate: Thu Oct 9 03:41:29 2025 +

avformat/flacdec: fix self assign warning

diff --git a/libavformat/flacdec.c b/libavformat/flacdec.c
index c2ba937b15..e80b49307d 100644
--- a/libavformat/flacdec.c
+++ b/libavformat/flacdec.c
@@ -102,9 +102,9 @@ static int flac_read_header(AVFormatContext *s)
 return AVERROR(ENOMEM);
 }
 ret = ffio_read_size(s->pb, buffer, metadata_size);
-if (ret < 0) {
-RETURN_ERROR(ret);
-}
+if (ret < 0)
+goto fail;
+
 break;
 /* skip metadata block for unsupported types */
 default:

---

Summary of changes:
 libavformat/flacdec.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. dad06a445f avcodec/Makefile: Remove h263 decoder->mpeg4videodec.o dependency

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  dad06a445f9aa3c19c01d9d4f0e98e00fefcd05b (commit)
   via  10d3479da083bb86fdb149ba317a754279e884a0 (commit)
  from  d96f8d32adfd4ea08c276cd2b6f10e7a3caf06fc (commit)


- Log -
commit dad06a445f9aa3c19c01d9d4f0e98e00fefcd05b
Author: Andreas Rheinhardt 
AuthorDate: Wed Oct 8 04:56:04 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Sat Oct 11 07:51:01 2025 +0200

avcodec/Makefile: Remove h263 decoder->mpeg4videodec.o dependency

Also prefer using #if CONFIG_MPEG4_DECODER checks in order not
to rely on DCE.

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/Makefile b/libavcodec/Makefile
index d55e899c14..791fd5d5a4 100644
--- a/libavcodec/Makefile
+++ b/libavcodec/Makefile
@@ -158,7 +158,7 @@ OBJS-$(CONFIG_MPEGVIDEOENC)+= mpegvideo_enc.o 
mpeg12data.o  \
   motion_est.o ratecontrol.o
 OBJS-$(CONFIG_MPEGVIDEOENCDSP) += mpegvideoencdsp.o
 OBJS-$(CONFIG_MSMPEG4DEC)  += msmpeg4dec.o msmpeg4.o msmpeg4data.o 
\
-  msmpeg4_vc1_data.o
+  msmpeg4_vc1_data.o mpeg4videodec.o
 OBJS-$(CONFIG_MSMPEG4ENC)  += msmpeg4enc.o msmpeg4.o msmpeg4data.o 
\
   msmpeg4_vc1_data.o
 OBJS-$(CONFIG_MSS34DSP)+= mss34dsp.o jpegquanttables.o
@@ -576,7 +576,8 @@ OBJS-$(CONFIG_MPEG2_CUVID_DECODER) += cuviddec.o
 OBJS-$(CONFIG_MPEG2_MEDIACODEC_DECODER) += mediacodecdec.o
 OBJS-$(CONFIG_MPEG2_VAAPI_ENCODER) += vaapi_encode_mpeg2.o
 OBJS-$(CONFIG_MPEG2_V4L2M2M_DECODER)   += v4l2_m2m_dec.o
-OBJS-$(CONFIG_MPEG4_DECODER)   += mpeg4videodsp.o xvididct.o
+OBJS-$(CONFIG_MPEG4_DECODER)   += mpeg4videodec.o mpeg4videodsp.o \
+  xvididct.o
 OBJS-$(CONFIG_MPEG4_ENCODER)   += mpeg4videoenc.o
 OBJS-$(CONFIG_MPEG4_CUVID_DECODER) += cuviddec.o
 OBJS-$(CONFIG_MPEG4_MEDIACODEC_DECODER) += mediacodecdec.o
diff --git a/libavcodec/h263dec.c b/libavcodec/h263dec.c
index bacd258d53..697fe7e572 100644
--- a/libavcodec/h263dec.c
+++ b/libavcodec/h263dec.c
@@ -201,10 +201,12 @@ static int decode_slice(H263DecContext *const h)
 
 ff_set_qscale(&h->c, h->c.qscale);
 
+#if CONFIG_MPEG4_DECODER
 if (h->c.studio_profile) {
 if ((ret = ff_mpeg4_decode_studio_slice_header(h)) < 0)
 return ret;
 }
+#endif
 
 if (h->c.avctx->hwaccel) {
 const uint8_t *start = h->gb.buffer + get_bits_count(&h->gb) / 8;
@@ -500,13 +502,15 @@ int ff_h263_decode_frame(AVCodecContext *avctx, AVFrame 
*pict,
 
 avctx->has_b_frames = !h->c.low_delay;
 
-if (CONFIG_MPEG4_DECODER && avctx->codec_id == AV_CODEC_ID_MPEG4) {
+#if CONFIG_MPEG4_DECODER
+if (avctx->codec_id == AV_CODEC_ID_MPEG4) {
 if (h->c.pict_type != AV_PICTURE_TYPE_B && h->c.mb_num/2 > 
get_bits_left(&h->gb))
 return AVERROR_INVALIDDATA;
 ff_mpeg4_workaround_bugs(avctx);
 if (h->c.studio_profile != (h->c.idsp.idct == NULL))
 ff_mpv_idct_init(s);
 }
+#endif
 
 /* After H.263 & MPEG-4 header decode we have the height, width,
  * and other parameters. So then we could init the picture. */
@@ -615,8 +619,10 @@ frame_end:
 
 ff_mpv_frame_end(s);
 
-if (CONFIG_MPEG4_DECODER && avctx->codec_id == AV_CODEC_ID_MPEG4)
+#if CONFIG_MPEG4_DECODER
+if (avctx->codec_id == AV_CODEC_ID_MPEG4)
 ff_mpeg4_frame_end(avctx, avpkt);
+#endif
 
 av_assert1(h->c.pict_type == h->c.cur_pic.ptr->f->pict_type);
 if (h->c.pict_type == AV_PICTURE_TYPE_B || h->c.low_delay) {
diff --git a/libavcodec/ituh263dec.c b/libavcodec/ituh263dec.c
index 7a78b95c50..dc8847b53b 100644
--- a/libavcodec/ituh263dec.c
+++ b/libavcodec/ituh263dec.c
@@ -240,9 +240,11 @@ int ff_h263_resync(H263DecContext *const h)
 
 if (show_bits(&h->gb, 16) ==0) {
 pos = get_bits_count(&h->gb);
-if(CONFIG_MPEG4_DECODER && h->c.codec_id==AV_CODEC_ID_MPEG4)
+#if CONFIG_MPEG4_DECODER
+if (h->c.codec_id == AV_CODEC_ID_MPEG4)
 ret = ff_mpeg4_decode_video_packet_header(h);
 else
+#endif
 ret = h263_decode_gob_header(h);
 if(ret>=0)
 return pos;
@@ -257,9 +259,11 @@ int ff_h263_resync(H263DecContext *const h)
 GetBitContext bak = h->gb;
 
 pos = get_bits_count(&h->gb);
-if(CONFIG_MPEG4_DECODER && h->c.codec_id==AV_CODEC_ID_MPEG4)
+#if CONFIG_MPEG4_DECODER
+if (h->c.codec_id == AV_CODEC_ID_MPEG4)
 ret = ff_mpeg4_decode_video_packet_header(h);
 else
+#endif
 ret = h263_decode_gob_header(h);
 if(ret>=0)
 return pos;

commit 10d3479da083bb86fdb149ba317a754279e884a0
Author: Andreas Rheinhardt 
AuthorDate: Wed Oct 8 03:45:20

[FFmpeg-cvslog] [ffmpeg] branch master updated. 00225e9ebc avcodec/x86/h264_qpel: Simplify macros

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  00225e9ebc943fdec451f826e342c821489a81f3 (commit)
   via  3049694e9f51d883c54c2c5500c8fd9d388536f9 (commit)
   via  3ed590c7b9fb0663903a2927f713bec8ad0232b6 (commit)
   via  617c042093129758a53b01e6fc400356d8f4e566 (commit)
   via  29f439077a1b7a0a93832fdaefddcc0b7577c5e7 (commit)
   via  4539f7e4d4953fbf2086cac0e54575627f7df1e8 (commit)
   via  3e2d9b73c13292a324d8846dc49d807b59224612 (commit)
   via  15a4289b79d8c2e2453921544f7983248ef498bd (commit)
  from  c7815a4b707b7ae685e5809179094a275885759e (commit)


- Log -
commit 00225e9ebc943fdec451f826e342c821489a81f3
Author: Andreas Rheinhardt 
AuthorDate: Sat Oct 4 15:45:36 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Tue Oct 7 18:06:40 2025 +0200

avcodec/x86/h264_qpel: Simplify macros

1. Remove the OP parameter from the QPEL_H264* macros. These are
a remnant of inline assembly and were forgotten in
610e00b3594bf0f2a75713f20e9c4edf0d03a818.
2. Pass the instruction set extension for the shift5 function
explicitly in the macro instead of using magic #defines.
3. Likewise, avoid magic #defines for (8|16)_v_lowpass_ssse3.

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/x86/h264_qpel.c b/libavcodec/x86/h264_qpel.c
index 9b22c74286..f7596329e2 100644
--- a/libavcodec/x86/h264_qpel.c
+++ b/libavcodec/x86/h264_qpel.c
@@ -78,7 +78,7 @@ void ff_put_h264_qpel4_hv_lowpass_v_mmxext(const uint8_t 
*src, int16_t *tmp, ptr
 DEF_QPEL(avg)
 DEF_QPEL(put)
 
-#define QPEL_H264(OPNAME, OP, MMX)\
+#define QPEL_H264(OPNAME, MMX)\
 static av_always_inline void OPNAME ## h264_qpel4_hv_lowpass_ ## MMX(uint8_t 
*dst, int16_t *tmp, const uint8_t *src, ptrdiff_t dstStride, ptrdiff_t 
srcStride)\
 {\
 src -= 2*srcStride+2;\
@@ -100,17 +100,17 @@ static av_always_inline void ff_ ## OPNAME ## 
h264_qpel16_h_lowpass_l2_ ## EXT(u
 
 
 #if ARCH_X86_64
-#define QPEL_H264_H16_XMM(OPNAME, OP, MMX)\
+#define QPEL_H264_H16_XMM(OPNAME, MMX)\
 
 void ff_avg_h264_qpel16_h_lowpass_l2_ssse3(uint8_t *dst, const uint8_t *src, 
const uint8_t *src2, ptrdiff_t dstStride, ptrdiff_t src2Stride);
 void ff_put_h264_qpel16_h_lowpass_l2_ssse3(uint8_t *dst, const uint8_t *src, 
const uint8_t *src2, ptrdiff_t dstStride, ptrdiff_t src2Stride);
 
 #else // ARCH_X86_64
-#define QPEL_H264_H16_XMM(OPNAME, OP, EXT) QPEL_H264_H16(OPNAME, EXT)
+#define QPEL_H264_H16_XMM(OPNAME, EXT) QPEL_H264_H16(OPNAME, EXT)
 #endif // ARCH_X86_64
 
-#define QPEL_H264_H_XMM(OPNAME, OP, MMX)\
-QPEL_H264_H16_XMM(OPNAME, OP, MMX)\
+#define QPEL_H264_H_XMM(OPNAME, MMX)\
+QPEL_H264_H16_XMM(OPNAME, MMX)\
 static av_always_inline void ff_ ## OPNAME ## h264_qpel16_h_lowpass_ ## 
MMX(uint8_t *dst, const uint8_t *src, ptrdiff_t dstStride, ptrdiff_t srcStride)\
 {\
 ff_ ## OPNAME ## h264_qpel8_h_lowpass_ ## MMX(dst  , src  , dstStride, 
srcStride);\
@@ -121,15 +121,15 @@ static av_always_inline void ff_ ## OPNAME ## 
h264_qpel16_h_lowpass_ ## MMX(uint
 ff_ ## OPNAME ## h264_qpel8_h_lowpass_ ## MMX(dst+8, src+8, dstStride, 
srcStride);\
 }\
 
-#define QPEL_H264_V_XMM(OPNAME, OP, MMX)\
-static av_always_inline void ff_ ## OPNAME ## h264_qpel8_v_lowpass_ ## 
MMX(uint8_t *dst, const uint8_t *src, ptrdiff_t dstStride, ptrdiff_t srcStride)\
+#define QPEL_H264_V_XMM(OPNAME, XMM, XMM2)\
+static av_always_inline void ff_ ## OPNAME ## h264_qpel8_v_lowpass_ ## 
XMM(uint8_t *dst, const uint8_t *src, ptrdiff_t dstStride, ptrdiff_t srcStride)\
 {\
-ff_ ## OPNAME ## h264_qpel8or16_v_lowpass_ ## MMX(dst  , src  , dstStride, 
srcStride, 8);\
+ff_ ## OPNAME ## h264_qpel8or16_v_lowpass_ ## XMM2(dst  , src  , 
dstStride, srcStride, 8);\
 }\
-static av_always_inline void ff_ ## OPNAME ## h264_qpel16_v_lowpass_ ## 
MMX(uint8_t *dst, const uint8_t *src, ptrdiff_t dstStride, ptrdiff_t srcStride)\
+static av_always_inline void ff_ ## OPNAME ## h264_qpel16_v_lowpass_ ## 
XMM(uint8_t *dst, const uint8_t *src, ptrdiff_t dstStride, ptrdiff_t srcStride)\
 {\
-ff_ ## OPNAME ## h264_qpel8or16_v_lowpass_ ## MMX(dst  , src  , dstStride, 
srcStride, 16);\
-ff_ ## OPNAME ## h264_qpel8or16_v_lowpass_ ## MMX(dst+8, src+8, dstStride, 
srcStride, 16);\
+ff_ ## OPNAME ## h264_qpel8or16_v_lowpass_ ## XMM2(dst  , src  , 
dstStride, srcStride, 16);\
+ff_ ## OPNAME ## h264_qpel8or16_v_lowpass_ ## XMM2(dst+8, src+8, 
dstStride, srcStride, 16);\
 }
 
 static av_always_inline void put_h264_qpel8or16_hv1_lowpass_sse2(int16_t *tmp,
@@ -146,7 +146,7 @@ static av_always_inline void 
put_h264_qpel8or16_hv1_lowpass_sse2(int16_t *tmp,
 }
 }
 
-#define QPEL_H264_HV_XMM(OPNAME, OP, MMX)\
+#define QPEL_H264_HV_XMM(OPNAME, MMX)\
 static av_always_inline void OPNAME ## h264_qpel8_hv_lowpass_ ## MMX(uint8_t 
*dst, int16_t *tmp, const uint8_t *src, ptrdiff_t dstStride, ptrdiff_t 
srcStride)\
 {\
 put_h264_qpel8or16_hv1_lowpass_sse2(tmp, src, srcStride, 8);\

[FFmpeg-cvslog] [ffmpeg] branch master updated. b80f28fcbc avfilter/vf_libplacebo: introduce `fit_sense` option

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  b80f28fcbcedbf48b760921e85c5f2ae4f2f802a (commit)
   via  12d696cff4eeaccb8610c02056fd5f7342d51ac3 (commit)
   via  6ad839ff2e1ac36b6ab9ad6f687208a57731df7e (commit)
  from  74115b017c3038b717162bb56346afb4ad937be3 (commit)


- Log -
commit b80f28fcbcedbf48b760921e85c5f2ae4f2f802a
Author: Niklas Haas 
AuthorDate: Tue Sep 23 20:49:07 2025 +0200
Commit: Niklas Haas 
CommitDate: Tue Sep 30 15:39:39 2025 +

avfilter/vf_libplacebo: introduce `fit_sense` option

This allows choosing whether the `fit_mode` merely controls the placement
of the image within the output resolution, or whether the output resolution
is also adjusted according to the given `fit_mode`.

diff --git a/doc/filters.texi b/doc/filters.texi
index bb96e75d2a..262e7ad009 100644
--- a/doc/filters.texi
+++ b/doc/filters.texi
@@ -16449,7 +16449,8 @@ will be performed.
 
 @item force_original_aspect_ratio
 @item force_divisible_by
-Work the same as the identical @ref{scale} filter options.
+Work the same as the identical @ref{scale} filter options. Note that
+@option{force_divisible_by} also works with @code{fit_sense=constraint}.
 
 @item reset_sar
 If enabled, output frames will always have a pixel aspect ratio of 1:1.  If
@@ -16503,6 +16504,22 @@ to either @code{contain} or @code{none}, depending on 
whether the input is
 larger than the output or not.
 @end table
 
+@item fit_sense
+When @option{fit_mode} is in use, this option controls how the fit strategy
+is applied against the specified output resolution. Mutually exclusive with
+@option{force_original_aspect_ratio}. Valid values are:
+
+@table @samp
+@item target
+The computed output resolution is taken as the exact size of the output frame.
+This is the default behavior.
+
+@item constraint
+The computed output resolution is a size reference against which the fit mode
+is applied, enlarging or decreasing the true frame size as needed to fit the
+content.
+@end table
+
 @item fillcolor
 Set the color used to fill the output area not covered by the output image, for
 example as a result of @option{normalize_sar}. For the general syntax of this
diff --git a/libavfilter/vf_libplacebo.c b/libavfilter/vf_libplacebo.c
index 2cf58b1f8d..2b3738c8e0 100644
--- a/libavfilter/vf_libplacebo.c
+++ b/libavfilter/vf_libplacebo.c
@@ -161,6 +161,12 @@ enum fit_mode {
 FIT_MODE_NB,
 };
 
+enum fit_sense {
+FIT_TARGET,
+FIT_CONSTRAINT,
+FIT_SENSE_NB,
+};
+
 typedef struct LibplaceboContext {
 /* lavfi vulkan*/
 FFVulkanContext vkctx;
@@ -206,6 +212,7 @@ typedef struct LibplaceboContext {
 int reset_sar;
 int normalize_sar;
 int fit_mode;
+int fit_sense;
 int apply_filmgrain;
 int apply_dovi;
 int colorspace;
@@ -1452,11 +1459,24 @@ static int libplacebo_config_output(AVFilterLink 
*outlink)
 double sar_in = inlink->sample_aspect_ratio.num ?
 av_q2d(inlink->sample_aspect_ratio) : 1.0;
 
+int force_oar = s->force_original_aspect_ratio;
+if (!force_oar && s->fit_sense == FIT_CONSTRAINT) {
+if (s->fit_mode == FIT_CONTAIN || s->fit_mode == FIT_SCALE_DOWN) {
+force_oar = SCALE_FORCE_OAR_DECREASE;
+} else if (s->fit_mode == FIT_COVER) {
+force_oar = SCALE_FORCE_OAR_INCREASE;
+}
+}
+
 ff_scale_adjust_dimensions(inlink, &outlink->w, &outlink->h,
-   s->force_original_aspect_ratio,
-   s->force_divisible_by,
+   force_oar, s->force_divisible_by,
s->reset_sar ? sar_in : 1.0);
 
+if (s->fit_mode == FIT_SCALE_DOWN && s->fit_sense == FIT_CONSTRAINT) {
+int w_adj = s->reset_sar ? sar_in * inlink->w : inlink->w;
+outlink->w = FFMIN(outlink->w, w_adj);
+outlink->h = FFMIN(outlink->h, inlink->h);
+}
 
 if (s->nb_inputs > 1 && !s->disable_fbos) {
 /* Create a separate renderer and composition texture */
@@ -1586,6 +1606,9 @@ static const AVOption libplacebo_options[] = {
 { "none",   "Keep input unscaled, padding and cropping as needed", 
 0, AV_OPT_TYPE_CONST, {.i64 = FIT_NONE },   0, 0, STATIC, .unit = 
"fit_mode" },
 { "place",  "Keep input unscaled, padding and cropping as needed", 
 0, AV_OPT_TYPE_CONST, {.i64 = FIT_NONE },   0, 0, STATIC, .unit = 
"fit_mode" },
 { "scale_down", "Downscale only if larger, padding to preserve 
aspect", 0, AV_OPT_TYPE_CONST, {.i64 = FIT_SCALE_DOWN }, 0, 0, STATIC, .unit = 
"fit_mode" },
+{ "fit_sense", "Output size strategy (for the base layer only)", 
OFFSET(fit_sense), AV_OPT_TYPE_INT, {.i64 = FIT_TARGET }, 0, FIT_SENSE_NB - 1, 
STATIC, .unit = "fit_sense" },
+{ "target", "Computed resolution is the exact output size",
 0, AV_OPT_TYPE_CONST, {.i64 = FIT_TARGET }, 0, 0, STATIC

[FFmpeg-cvslog] [ffmpeg] branch master updated. 1a02412170 avformat/movenc_ttml: fix memleaks

2025-10-01 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  1a02412170144f07711428ddc2d1051c4284ee0a (commit)
  from  cb4052beae1e347e0c357a5b7ab860328aa01dd4 (commit)


- Log -
commit 1a02412170144f07711428ddc2d1051c4284ee0a
Author: Zhao Zhili 
AuthorDate: Tue Sep 23 22:08:02 2025 +0800
Commit: Zhao Zhili 
CommitDate: Wed Oct 1 22:31:03 2025 +0800

avformat/movenc_ttml: fix memleaks

Memory leaks can happen on normal case when break from while loop
early, and it can happen on error path with goto cleanup.

Signed-off-by: Zhao Zhili 

diff --git a/libavformat/movenc_ttml.c b/libavformat/movenc_ttml.c
index c5232e589c..ff09c14fa2 100644
--- a/libavformat/movenc_ttml.c
+++ b/libavformat/movenc_ttml.c
@@ -140,7 +140,7 @@ static int 
mov_write_ttml_document_from_queue(AVFormatContext *s,
 } else if (pkt->pts >= end_ts) {
 // starts after this fragment, put back to original queue
 ret = avpriv_packet_list_put(&track->squashed_packet_queue,
- pkt, av_packet_ref,
+ pkt, NULL,
  FF_PACKETLIST_FLAG_PREPEND);
 if (ret < 0)
 goto cleanup;
@@ -215,6 +215,7 @@ static int 
mov_write_ttml_document_from_queue(AVFormatContext *s,
 ret = 0;
 
 cleanup:
+av_packet_unref(pkt);
 while (!avpriv_packet_list_get(&back_to_queue_list, pkt)) {
 ret = avpriv_packet_list_put(&track->squashed_packet_queue,
  pkt, av_packet_ref,

---

Summary of changes:
 libavformat/movenc_ttml.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 8e11e2cdb8 avformat/tls_openssl: initialize underlying protocol early for dtls_start()

2025-09-30 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  8e11e2cdb82299e7f0b6d8884bf2bc65c1c3f5e8 (commit)
   via  2762ae74c53b058345660019ecce4ba41a85a050 (commit)
   via  3166e3b5394540dd827691773f499e98d7c0c69b (commit)
   via  f231439ee747f2e72bacc9fe7af30bd117eb46a9 (commit)
   via  49c6e6cc44f011ea43a3cab1b965510569bd229d (commit)
   via  7e58fff9d0b9b05f118917b5eb5704bb3514c6bd (commit)
   via  2d06ed9308ebaa785d8b3389ad8da033b8839c89 (commit)
   via  70e0e3e2572447c559aac5179578be5a584e942b (commit)
   via  c5be4b70754d276e7370dd90e807e883c4bec627 (commit)
   via  6f17053e6c75e5c44eaee9d4da0a4c80470274d0 (commit)
  from  8cb1ff78ac62ff0f652b0cb06369ba50d5e946c6 (commit)


- Log -
commit 8e11e2cdb82299e7f0b6d8884bf2bc65c1c3f5e8
Author: Marton Balint 
AuthorDate: Wed Sep 3 00:55:46 2025 +0200
Commit: Marton Balint 
CommitDate: Wed Oct 1 00:34:19 2025 +0200

avformat/tls_openssl: initialize underlying protocol early for dtls_start()

The same way we do with TLS, so all tls URL options will be properly 
supported.

Signed-off-by: Marton Balint 

diff --git a/doc/protocols.texi b/doc/protocols.texi
index 9f88f005b9..b74383122a 100644
--- a/doc/protocols.texi
+++ b/doc/protocols.texi
@@ -2052,12 +2052,19 @@ Datagram Transport Layer Security (DTLS)
 
 The required syntax for a DTLS URL is:
 @example
-dtls://@var{hostname}:@var{port}
+dtls://@var{hostname}:@var{port}[?@var{options}]
 @end example
 
+@var{options} contains a list of &-separated options of the form
+@var{key}=@var{val}. Standard percent-encoding (and using the plus sign for
+space) can be used to escape keys and values.
+
+Options can also can be specified via command line options (or in code via
+@code{AVOption}s).
+
 DTLS shares most options with TLS, but operates over UDP instead of TCP.
-The following parameters can be set via command line options
-(or in code via @code{AVOption}s):
+
+The list of supported options follows.
 
 @table @option
 
diff --git a/libavformat/tls_openssl.c b/libavformat/tls_openssl.c
index 5fc0b639d7..c2adaa38d1 100644
--- a/libavformat/tls_openssl.c
+++ b/libavformat/tls_openssl.c
@@ -747,6 +747,13 @@ static int dtls_start(URLContext *h, const char *url, int 
flags, AVDictionary **
 int ret = 0;
 s->is_dtls = 1;
 
+if (!c->tls_shared.external_sock) {
+if ((ret = ff_tls_open_underlying(&c->tls_shared, h, url, options)) < 
0) {
+av_log(c, AV_LOG_ERROR, "Failed to connect %s\n", url);
+return ret;
+}
+}
+
 c->ctx = SSL_CTX_new(s->listen ? DTLS_server_method() : 
DTLS_client_method());
 if (!c->ctx) {
 ret = AVERROR(ENOMEM);
@@ -799,13 +806,6 @@ static int dtls_start(URLContext *h, const char *url, int 
flags, AVDictionary **
 DTLS_set_link_mtu(c->ssl, s->mtu);
 init_bio_method(h);
 
-if (!c->tls_shared.external_sock) {
-if ((ret = ff_tls_open_underlying(&c->tls_shared, h, url, options)) < 
0) {
-av_log(c, AV_LOG_ERROR, "Failed to connect %s\n", url);
-return ret;
-}
-}
-
 /* This seems to be necessary despite explicitly setting client/server 
method above. */
 if (s->listen)
 SSL_set_accept_state(c->ssl);
@@ -836,6 +836,7 @@ static int dtls_start(URLContext *h, const char *url, int 
flags, AVDictionary **
 
 ret = 0;
 fail:
+tls_close(h);
 return ret;
 }
 

commit 2762ae74c53b058345660019ecce4ba41a85a050
Author: Marton Balint 
AuthorDate: Tue Aug 26 00:23:16 2025 +0200
Commit: Marton Balint 
CommitDate: Wed Oct 1 00:34:19 2025 +0200

avformat/tls: use ff_parse_opts_from_query_string() to set URL parameters

Note that this changes the code to work the same way as other protocols 
where
an URL parameter can override an AVOption.

Signed-off-by: Marton Balint 

diff --git a/doc/protocols.texi b/doc/protocols.texi
index 3d9685ed6d..9f88f005b9 100644
--- a/doc/protocols.texi
+++ b/doc/protocols.texi
@@ -1984,8 +1984,14 @@ The required syntax for a TLS/SSL url is:
 tls://@var{hostname}:@var{port}[?@var{options}]
 @end example
 
-The following parameters can be set via command line options
-(or in code via @code{AVOption}s):
+@var{options} contains a list of &-separated options of the form
+@var{key}=@var{val}. Standard percent-encoding (and using the plus sign for
+space) can be used to escape keys and values.
+
+Options can also can be specified via command line options (or in code via
+@code{AVOption}s).
+
+The list of supported options follows.
 
 @table @option
 
diff --git a/libavformat/tls.c b/libavformat/tls.c
index bd9c05e6dc..2cf0c99a6b 100644
--- a/libavformat/tls.c
+++ b/libavformat/tls.c
@@ -31,41 +31,6 @@
 #include "libavutil/mem.h"
 #include "libavutil/parseutils.h"
 
-static int set_options(TLSShared *c, const char *uri)
-{
-char buf[1024];
-const char *p = strchr(uri, '?');
-if (!p)
-   

[FFmpeg-cvslog] [ffmpeg] branch master updated. 8cb1ff78ac avformat/dhav: Factorize some code in get_duration()

2025-09-30 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  8cb1ff78ac62ff0f652b0cb06369ba50d5e946c6 (commit)
  from  b80f28fcbcedbf48b760921e85c5f2ae4f2f802a (commit)


- Log -
commit 8cb1ff78ac62ff0f652b0cb06369ba50d5e946c6
Author: Michael Niedermayer 
AuthorDate: Sat Sep 20 01:56:20 2025 +0200
Commit: michaelni 
CommitDate: Tue Sep 30 21:13:56 2025 +

avformat/dhav: Factorize some code in get_duration()

Signed-off-by: Michael Niedermayer 

diff --git a/libavformat/dhav.c b/libavformat/dhav.c
index b3fa612ab3..614934dc68 100644
--- a/libavformat/dhav.c
+++ b/libavformat/dhav.c
@@ -242,7 +242,7 @@ static int64_t get_duration(AVFormatContext *s)
 
 int64_t start_pos = avio_tell(s->pb);
 int64_t pos = -1;
-int64_t start = 0, end = 0;
+int64_t start = 0;
 struct tm timeinfo;
 uint8_t *buffer;
 int64_t buffer_size;
@@ -250,6 +250,7 @@ static int64_t get_duration(AVFormatContext *s)
 int64_t offset;
 unsigned date;
 int64_t size = avio_size(s->pb);
+int64_t ret = 0;
 
 if (start_pos + 20 > size)
 return 0;
@@ -284,17 +285,12 @@ static int64_t get_duration(AVFormatContext *s)
 
 date = AV_RL32(buffer + (pos - buffer_pos) + 16);
 get_timeinfo(date, &timeinfo);
-end = av_timegm(&timeinfo) * 1000LL;
-
-av_freep(&buffer);
 
-avio_seek(s->pb, start_pos, SEEK_SET);
-
-return end - start;
+ret = av_timegm(&timeinfo) * 1000LL - start;
 fail:
 av_freep(&buffer);
 avio_seek(s->pb, start_pos, SEEK_SET);
-return 0;
+return ret;
 }
 
 static int dhav_read_header(AVFormatContext *s)

---

Summary of changes:
 libavformat/dhav.c | 12 
 1 file changed, 4 insertions(+), 8 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. dd977adcfe Add myself to CODEOWNERS

2025-09-28 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  dd977adcfe4d74b4240f1122a7c900966a0d0bc3 (commit)
  from  635cb4543f1bb08b645740406077dad845d5d7d4 (commit)


- Log -
commit dd977adcfe4d74b4240f1122a7c900966a0d0bc3
Author: Rémi Denis-Courmont 
AuthorDate: Sat Sep 27 14:07:36 2025 +0300
Commit: Rémi Denis-Courmont 
CommitDate: Sun Sep 28 12:35:14 2025 +

Add myself to CODEOWNERS

diff --git a/.forgejo/CODEOWNERS b/.forgejo/CODEOWNERS
index 780c80cef4..09d5976720 100644
--- a/.forgejo/CODEOWNERS
+++ b/.forgejo/CODEOWNERS
@@ -82,6 +82,7 @@ libavcodec/bsf/smpte436m_to_eia608.* @programmerjake
 libavcodec/aarch64/.* @lynne @mstorsjo
 libavcodec/arm/.* @mstorsjo
 libavcodec/ppc/.* @sean_mcg
+libavcodec/riscv/.* @Courmisch
 libavcodec/wasm/hevc/.* @quink
 libavcodec/x86/.* @lynne
 libavcodec/x86/vp8.* @rbultje
@@ -110,6 +111,7 @@ libavfilter/vf_yadif.* @michaelni
 libavfilter/vsrc_mandelbrot.* @michaelni
 
 libavfilter/aarch64/.* @mstorsjo
+libavfilter/riscv/.* @Courmisch
 libavfilter/x86/colorspace.* @rbultje
 libavfilter/x86/scene_sad.* @haasn
 
@@ -180,6 +182,7 @@ libavutil/tx.* @lynne
 libavutil/aarch64/.* @lynne @mstorsjo
 libavutil/arm/.* @mstorsjo
 libavutil/ppc/.* @sean_mcg
+libavutil/riscv/.* @Courmisch
 libavutil/x86/.* @lynne
 
 # swresample
@@ -193,6 +196,7 @@ libswresample/.* @michaelni
 libswscale/aarch64/.* @mstorsjo
 libswscale/arm/.* @mstorsjo
 libswscale/ppc/.* @sean_mcg
+libswscale/riscv/.* @Courmisch
 libswscale/.* @haasn
 
 # tools
@@ -210,4 +214,5 @@ doc/.* @GyanD
 
 # tests
 # =
+tests/checkasm/riscv/.* @Courmisch
 tests/ref/fate/sub-mcc.* @programmerjake

---

Summary of changes:
 .forgejo/CODEOWNERS | 5 +
 1 file changed, 5 insertions(+)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. f1d5114103 avformat/tls_openssl: do not cleanup tls after a successful dtls_start()

2025-10-02 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  f1d5114103a8164869a279326043645e7bacdc86 (commit)
  from  61b6877637041a1f817ad9811c839b0feae2b8af (commit)


- Log -
commit f1d5114103a8164869a279326043645e7bacdc86
Author: Marton Balint 
AuthorDate: Thu Oct 2 00:27:29 2025 +0200
Commit: Marton Balint 
CommitDate: Thu Oct 2 18:41:47 2025 +0200

avformat/tls_openssl: do not cleanup tls after a successful dtls_start()

Regression since 8e11e2cdb82299e7f0b6d8884bf2bc65c1c3f5e8.

Signed-off-by: Marton Balint 

diff --git a/libavformat/tls_openssl.c b/libavformat/tls_openssl.c
index c2adaa38d1..c7d6ff6cf4 100644
--- a/libavformat/tls_openssl.c
+++ b/libavformat/tls_openssl.c
@@ -834,7 +834,7 @@ static int dtls_start(URLContext *h, const char *url, int 
flags, AVDictionary **
 
 av_log(c, AV_LOG_VERBOSE, "Setup ok, MTU=%d\n", c->tls_shared.mtu);
 
-ret = 0;
+return 0;
 fail:
 tls_close(h);
 return ret;

---

Summary of changes:
 libavformat/tls_openssl.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. ed007ad427 avcodec/x86/fpel: Port ff_put_pixels8_mmx() to SSE2

2025-10-17 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  ed007ad427a659667fd3b20e6b7bfebc2844c832 (commit)
  from  d91b1559e0f61b7ee486c46854013d6c9ddb3e84 (commit)


- Log -
commit ed007ad427a659667fd3b20e6b7bfebc2844c832
Author: Andreas Rheinhardt 
AuthorDate: Tue Oct 14 15:06:13 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Fri Oct 17 13:27:56 2025 +0200

avcodec/x86/fpel: Port ff_put_pixels8_mmx() to SSE2

This has the advantage of not violating the ABI by using
MMX registers without issuing emms; it e.g. allows
to remove an emms_c from bink.c.

This commit uses GP registers on Unix64 (there are not
enough volatile registers to do likewise on Win64) which
reduces codesize and is faster on some CPUs.

Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/bink.c b/libavcodec/bink.c
index ef8e974589..e5300be000 100644
--- a/libavcodec/bink.c
+++ b/libavcodec/bink.c
@@ -21,7 +21,6 @@
  */
 
 #include "libavutil/attributes.h"
-#include "libavutil/emms.h"
 #include "libavutil/imgutils.h"
 #include "libavutil/mem.h"
 #include "libavutil/mem_internal.h"
@@ -1297,7 +1296,6 @@ static int decode_frame(AVCodecContext *avctx, AVFrame 
*frame,
 if (get_bits_count(&gb) >= bits_count)
 break;
 }
-emms_c();
 
 if (c->version > 'b') {
 if ((ret = av_frame_replace(c->last, frame)) < 0)
diff --git a/libavcodec/x86/cavsdsp.c b/libavcodec/x86/cavsdsp.c
index d14b472d54..e333bbee49 100644
--- a/libavcodec/x86/cavsdsp.c
+++ b/libavcodec/x86/cavsdsp.c
@@ -46,13 +46,6 @@ static void cavs_idct8_add_sse2(uint8_t *dst, int16_t 
*block, ptrdiff_t stride)
 
 #endif /* HAVE_SSE2_EXTERNAL */
 
-static av_cold void cavsdsp_init_mmx(CAVSDSPContext *c)
-{
-#if HAVE_MMX_EXTERNAL
-c->put_cavs_qpel_pixels_tab[1][0] = ff_put_pixels8x8_mmx;
-#endif /* HAVE_MMX_EXTERNAL */
-}
-
 #if HAVE_SSE2_EXTERNAL
 #define DEF_QPEL(OPNAME) \
 void ff_ ## OPNAME ## _cavs_qpel8_mc20_sse2(uint8_t *dst, const uint8_t 
*src, ptrdiff_t stride); \
@@ -98,9 +91,6 @@ av_cold void ff_cavsdsp_init_x86(CAVSDSPContext *c)
 {
 av_unused int cpu_flags = av_get_cpu_flags();
 
-if (X86_MMX(cpu_flags))
-cavsdsp_init_mmx(c);
-
 #if HAVE_MMX_EXTERNAL
 if (EXTERNAL_MMXEXT(cpu_flags)) {
 c->avg_cavs_qpel_pixels_tab[1][0] = ff_avg_pixels8x8_mmxext;
@@ -113,6 +103,7 @@ av_cold void ff_cavsdsp_init_x86(CAVSDSPContext *c)
 c->put_cavs_qpel_pixels_tab[0][ 4] = put_cavs_qpel16_mc01_sse2;
 c->put_cavs_qpel_pixels_tab[0][ 8] = put_cavs_qpel16_mc02_sse2;
 c->put_cavs_qpel_pixels_tab[0][12] = put_cavs_qpel16_mc03_sse2;
+c->put_cavs_qpel_pixels_tab[1][ 0] = ff_put_pixels8x8_sse2;
 c->put_cavs_qpel_pixels_tab[1][ 2] = ff_put_cavs_qpel8_mc20_sse2;
 c->put_cavs_qpel_pixels_tab[1][ 4] = put_cavs_qpel8_mc01_sse2;
 c->put_cavs_qpel_pixels_tab[1][ 8] = ff_put_cavs_qpel8_mc02_sse2;
diff --git a/libavcodec/x86/fpel.asm b/libavcodec/x86/fpel.asm
index 68a05310f2..e4becca5fb 100644
--- a/libavcodec/x86/fpel.asm
+++ b/libavcodec/x86/fpel.asm
@@ -27,7 +27,7 @@ SECTION .text
 
 ; void ff_put/avg_pixels(uint8_t *block, const uint8_t *pixels,
 ;ptrdiff_t line_size, int h)
-%macro OP_PIXELS 2
+%macro OP_PIXELS 2-3 0
 %if %2 == mmsize/2
 %define LOAD movh
 %define SAVE movh
@@ -35,14 +35,25 @@ SECTION .text
 %define LOAD movu
 %define SAVE mova
 %endif
-cglobal %1_pixels%2x%2, 3,5,4
+cglobal %1_pixels%2x%2, 3,5+4*%3,%3 ? 4 : 0
 mov r3d, %2
 jmp %1_pixels%2_after_prologue
 
-cglobal %1_pixels%2, 4,5,4
+cglobal %1_pixels%2, 4,5+4*%3,%3 ? 4 : 0
 %1_pixels%2_after_prologue:
 lea  r4, [r2*3]
 .loop:
+%if %3
+; Use GPRs on UNIX64 for put8, but not on Win64 due to a lack of volatile GPRs
+mov r5q, [r1]
+mov r6q, [r1+r2]
+mov r7q, [r1+r2*2]
+mov r8q, [r1+r4]
+mov[r0], r5q
+mov [r0+r2], r6q
+mov   [r0+r2*2], r7q
+mov [r0+r4], r8q
+%else
 LOAD m0, [r1]
 LOAD m1, [r1+r2]
 LOAD m2, [r1+r2*2]
@@ -57,6 +68,7 @@ cglobal %1_pixels%2, 4,5,4
 SAVE[r0+r2], m1
 SAVE  [r0+r2*2], m2
 SAVE[r0+r4], m3
+%endif
 sub r3d, 4
 lea  r1, [r1+r2*4]
 lea  r0, [r0+r2*4]
@@ -64,12 +76,10 @@ cglobal %1_pixels%2, 4,5,4
 RET
 %endmacro
 
-INIT_MMX mmx
-OP_PIXELS put, 8
-
 INIT_MMX mmxext
 OP_PIXELS avg, 8
 
 INIT_XMM sse2
+OP_PIXELS put, 8, UNIX64
 OP_PIXELS put, 16
 OP_PIXELS avg, 16
diff --git a/libavcodec/x86/fpel.h b/libavcodec/x86/fpel.h
index 598a7a6f63..0b0056021e 100644
--- a/libavcodec/x86/fpel.h
+++ b/libavcodec/x86/fpel.h
@@ -30,10 +30,10 @@ void ff_avg_pixels16_sse2(uint8_t *block, const uint8_t 
*pixels,
   ptrdiff_t line_size, int h);
 void ff_avg_pixels16x16_sse2(uint8_t *block, const uint8_t *pixels,
   

[FFmpeg-cvslog] [ffmpeg] branch master updated. db6cd6c6bf avformat/tls_openssl: Don't call functions inside FFMIN

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  db6cd6c6bfe6f306dd8d9de2a0086586cbd27ec1 (commit)
  from  ced4a6ebc9e7cd92d0ca9b9fb8f9d1013d23cbfa (commit)


- Log -
commit db6cd6c6bfe6f306dd8d9de2a0086586cbd27ec1
Author: Andreas Rheinhardt 
AuthorDate: Mon Sep 22 15:34:30 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Mon Sep 22 21:58:00 2025 +0200

avformat/tls_openssl: Don't call functions inside FFMIN

It may call the function multiple times.

Reviewed-by: Timo Rothenpieler 
Reviewed-by: Steven Liu 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavformat/tls_openssl.c b/libavformat/tls_openssl.c
index edfd657a3f..86b4d21799 100644
--- a/libavformat/tls_openssl.c
+++ b/libavformat/tls_openssl.c
@@ -939,8 +939,10 @@ static int tls_write(URLContext *h, const uint8_t *buf, 
int size)
 uc->flags &= ~AVIO_FLAG_NONBLOCK;
 uc->flags |= h->flags & AVIO_FLAG_NONBLOCK;
 
-if (s->is_dtls)
-size = FFMIN(size, DTLS_get_data_mtu(c->ssl));
+if (s->is_dtls) {
+const size_t mtu_size = DTLS_get_data_mtu(c->ssl);
+size = FFMIN(size, mtu_size);
+}
 
 ret = SSL_write(c->ssl, buf, size);
 if (ret > 0)

---

Summary of changes:
 libavformat/tls_openssl.c | 6 --
 1 file changed, 4 insertions(+), 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. d975dbd7b7 avcodec/libdav1d: bump minimum supported version to 1.0.0

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  d975dbd7b70e0b2f3f3b2950e5513c299b838810 (commit)
  from  0fdb5829e38dabea9cbe4073a35b6c6315e7508e (commit)


- Log -
commit d975dbd7b70e0b2f3f3b2950e5513c299b838810
Author: James Almer 
AuthorDate: Sun Sep 28 23:51:19 2025 -0300
Commit: James Almer 
CommitDate: Sun Sep 28 23:53:27 2025 -0300

avcodec/libdav1d: bump minimum supported version to 1.0.0

This allows us to remove old deprecated options.

Signed-off-by: James Almer 

diff --git a/configure b/configure
index 2cb39cbd57..aaa72c9f93 100755
--- a/configure
+++ b/configure
@@ -7116,7 +7116,7 @@ enabled libcelt   && require libcelt celt/celt.h 
celt_decode -lcelt0 &&
die "ERROR: libcelt must be installed and 
version must be >= 0.11.0."; }
 enabled libcaca   && require_pkg_config libcaca caca caca.h 
caca_create_canvas
 enabled libcodec2 && require libcodec2 codec2/codec2.h codec2_create 
-lcodec2
-enabled libdav1d  && require_pkg_config libdav1d "dav1d >= 0.5.0" 
"dav1d/dav1d.h" dav1d_version
+enabled libdav1d  && require_pkg_config libdav1d "dav1d >= 1.0.0" 
"dav1d/dav1d.h" dav1d_version
 enabled libdavs2  && require_pkg_config libdavs2 "davs2 >= 1.6.0" 
davs2.h davs2_decoder_open
 enabled libdc1394 && require_pkg_config libdc1394 libdc1394-2 
dc1394/dc1394.h dc1394_new
 enabled libdrm&& check_pkg_config libdrm libdrm xf86drm.h 
drmGetVersion
diff --git a/doc/decoders.texi b/doc/decoders.texi
index b7d80ca3d7..9248e2283a 100644
--- a/doc/decoders.texi
+++ b/doc/decoders.texi
@@ -119,16 +119,6 @@ The following options are supported by the libdav1d 
wrapper.
 
 @table @option
 
-@item framethreads
-Set amount of frame threads to use during decoding. The default value is 0 
(autodetect).
-This option is deprecated for libdav1d >= 1.0 and will be removed in the 
future. Use the
-option @code{max_frame_delay} and the global option @code{threads} instead.
-
-@item tilethreads
-Set amount of tile threads to use during decoding. The default value is 0 
(autodetect).
-This option is deprecated for libdav1d >= 1.0 and will be removed in the 
future. Use the
-global option @code{threads} instead.
-
 @item max_frame_delay
 Set max amount of frames the decoder may buffer internally. The default value 
is 0
 (autodetect).
diff --git a/libavcodec/libdav1d.c b/libavcodec/libdav1d.c
index bd3050b881..01fe2c415f 100644
--- a/libavcodec/libdav1d.c
+++ b/libavcodec/libdav1d.c
@@ -50,8 +50,6 @@ typedef struct Libdav1dContext {
 int pool_size;
 
 Dav1dData data;
-int tile_threads;
-int frame_threads;
 int max_frame_delay;
 int apply_grain;
 int operating_point;
@@ -215,11 +213,7 @@ static av_cold int libdav1d_init(AVCodecContext *c)
 {
 Libdav1dContext *dav1d = c->priv_data;
 Dav1dSettings s;
-#if FF_DAV1D_VERSION_AT_LEAST(6,0)
 int threads = c->thread_count;
-#else
-int threads = (c->thread_count ? c->thread_count : av_cpu_count()) * 3 / 2;
-#endif
 const AVPacketSideData *sd;
 int res;
 
@@ -240,32 +234,14 @@ static av_cold int libdav1d_init(AVCodecContext *c)
 s.all_layers = dav1d->all_layers;
 if (dav1d->operating_point >= 0)
 s.operating_point = dav1d->operating_point;
-#if FF_DAV1D_VERSION_AT_LEAST(6,2)
 s.strict_std_compliance = c->strict_std_compliance > 0;
-#endif
 
-#if FF_DAV1D_VERSION_AT_LEAST(6,0)
-if (dav1d->frame_threads || dav1d->tile_threads)
-s.n_threads = FFMAX(dav1d->frame_threads, dav1d->tile_threads);
-else
-s.n_threads = FFMIN(threads, DAV1D_MAX_THREADS);
+s.n_threads = FFMIN(threads, DAV1D_MAX_THREADS);
 if (dav1d->max_frame_delay > 0 && (c->flags & AV_CODEC_FLAG_LOW_DELAY))
 av_log(c, AV_LOG_WARNING, "Low delay mode requested, forcing 
max_frame_delay 1\n");
 s.max_frame_delay = (c->flags & AV_CODEC_FLAG_LOW_DELAY) ? 1 : 
dav1d->max_frame_delay;
 av_log(c, AV_LOG_DEBUG, "Using %d threads, %d max_frame_delay\n",
s.n_threads, s.max_frame_delay);
-#else
-s.n_tile_threads = dav1d->tile_threads
- ? dav1d->tile_threads
- : FFMIN(floor(sqrt(threads)), DAV1D_MAX_TILE_THREADS);
-s.n_frame_threads = dav1d->frame_threads
-  ? dav1d->frame_threads
-  : FFMIN(ceil(threads / s.n_tile_threads), 
DAV1D_MAX_FRAME_THREADS);
-if (dav1d->max_frame_delay > 0)
-s.n_frame_threads = FFMIN(s.n_frame_threads, dav1d->max_frame_delay);
-av_log(c, AV_LOG_DEBUG, "Using %d frame threads, %d tile threads\n",
-   s.n_frame_threads, s.n_tile_threads);
-#endif
 
 #if FF_DAV1D_VERSION_AT_LEAST(6,8)
 if (c->skip_frame >= AVDISCARD_NONKEY)
@@ -465,9 +441,7 @@ static int libdav1d_receive_frame(AVCodecContext *c, 
AVFrame *frame)
 Libdav1dContext *dav1d = c->priv_data;
 Dav1dPicture pic = { 0 }

[FFmpeg-cvslog] [ffmpeg] branch master updated. 96065d1261 avcodec/aom_film_grain: fix AVCOL_*_NB range check

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  96065d12612180a57fceee58256de47077f6ec9a (commit)
  from  0599d508c90b49bdead385edcec429e2dd50526e (commit)


- Log -
commit 96065d12612180a57fceee58256de47077f6ec9a
Author: Niklas Haas 
AuthorDate: Mon Sep 22 17:14:45 2025 +0200
Commit: Niklas Haas 
CommitDate: Thu Sep 25 11:08:37 2025 +

avcodec/aom_film_grain: fix AVCOL_*_NB range check

These should also exclude the _NB values themselves.

diff --git a/libavcodec/aom_film_grain.c b/libavcodec/aom_film_grain.c
index 0f24a2bcf8..bd9647afe9 100644
--- a/libavcodec/aom_film_grain.c
+++ b/libavcodec/aom_film_grain.c
@@ -199,13 +199,13 @@ int ff_aom_parse_film_grain_sets(AVFilmGrainAFGS1Params 
*s,
 fgp->color_trc = get_bits(gb, 8);
 fgp->color_space = get_bits(gb, 8);
 fgp->color_range = get_bits1(gb) ? AVCOL_RANGE_JPEG : 
AVCOL_RANGE_MPEG;
-if (fgp->color_primaries > AVCOL_PRI_NB ||
+if (fgp->color_primaries >= AVCOL_PRI_NB ||
 fgp->color_primaries == AVCOL_PRI_RESERVED ||
 fgp->color_primaries == AVCOL_PRI_RESERVED0 ||
-fgp->color_trc > AVCOL_TRC_NB ||
+fgp->color_trc >= AVCOL_TRC_NB ||
 fgp->color_trc == AVCOL_TRC_RESERVED ||
 fgp->color_trc == AVCOL_TRC_RESERVED0 ||
-fgp->color_space > AVCOL_SPC_NB ||
+fgp->color_space >= AVCOL_SPC_NB ||
 fgp->color_space == AVCOL_SPC_RESERVED)
 goto error;
 }

---

Summary of changes:
 libavcodec/aom_film_grain.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 2e1d702cfc avformat/dump: fix log level passed to av_log when printing stream group side data

2025-10-18 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  2e1d702cfc5c530c213361e6a1b77dca847a30e7 (commit)
  from  74a3c1ddb6f7aee90575697975b480d78dd78f4f (commit)


- Log -
commit 2e1d702cfc5c530c213361e6a1b77dca847a30e7
Author: James Almer 
AuthorDate: Mon Oct 13 23:39:52 2025 -0300
Commit: James Almer 
CommitDate: Wed Oct 15 17:49:11 2025 -0300

avformat/dump: fix log level passed to av_log when printing stream group 
side data

Signed-off-by: James Almer 

diff --git a/libavformat/dump.c b/libavformat/dump.c
index dfa33fd3c9..2948189432 100644
--- a/libavformat/dump.c
+++ b/libavformat/dump.c
@@ -367,11 +367,11 @@ static void dump_content_light_metadata(void *ctx, const 
AVPacketSideData *sd,
metadata->MaxCLL, metadata->MaxFALL);
 }
 
-static void dump_ambient_viewing_environment_metadata(void *ctx, const 
AVPacketSideData *sd)
+static void dump_ambient_viewing_environment_metadata(void *ctx, const 
AVPacketSideData *sd, int log_level)
 {
 const AVAmbientViewingEnvironment *ambient =
 (const AVAmbientViewingEnvironment *)sd->data;
-av_log(ctx, AV_LOG_INFO,
+av_log(ctx, log_level,
"ambient_illuminance=%f, ambient_light_x=%f, ambient_light_y=%f",
av_q2d(ambient->ambient_illuminance),
av_q2d(ambient->ambient_light_x),
@@ -445,12 +445,12 @@ static void dump_s12m_timecode(void *ctx, AVRational 
avg_frame_rate, const AVPac
 }
 }
 
-static void dump_cropping(void *ctx, const AVPacketSideData *sd)
+static void dump_cropping(void *ctx, const AVPacketSideData *sd, int log_level)
 {
 uint32_t top, bottom, left, right;
 
 if (sd->size < sizeof(uint32_t) * 4) {
-av_log(ctx, AV_LOG_ERROR, "invalid data\n");
+av_log(ctx, log_level, "invalid data\n");
 return;
 }
 
@@ -459,15 +459,15 @@ static void dump_cropping(void *ctx, const 
AVPacketSideData *sd)
 left   = AV_RL32(sd->data +  8);
 right  = AV_RL32(sd->data + 12);
 
-av_log(ctx, AV_LOG_INFO, "%d/%d/%d/%d", left, right, top, bottom);
+av_log(ctx, log_level, "%d/%d/%d/%d", left, right, top, bottom);
 }
 
-static void dump_tdrdi(void *ctx, const AVPacketSideData *sd)
+static void dump_tdrdi(void *ctx, const AVPacketSideData *sd, int log_level)
 {
 const AV3DReferenceDisplaysInfo *tdrdi =
 (const AV3DReferenceDisplaysInfo *)sd->data;
 
-av_log(ctx, AV_LOG_INFO, "number of reference displays: %u", 
tdrdi->num_ref_displays);
+av_log(ctx, log_level, "number of reference displays: %u", 
tdrdi->num_ref_displays);
 }
 
 static void dump_sidedata(void *ctx, const AVPacketSideData *side_data, int 
nb_side_data,
@@ -485,7 +485,7 @@ static void dump_sidedata(void *ctx, const AVPacketSideData 
*side_data, int nb_s
 
 av_log(ctx, log_level, "%s  ", indent);
 if (name)
-av_log(ctx, AV_LOG_INFO, "%s: ", name);
+av_log(ctx, log_level, "%s: ", name);
 switch (sd->type) {
 case AV_PKT_DATA_PARAM_CHANGE:
 dump_paramchange(ctx, sd, log_level);
@@ -526,13 +526,13 @@ static void dump_sidedata(void *ctx, const 
AVPacketSideData *side_data, int nb_s
 dump_s12m_timecode(ctx, avg_frame_rate, sd, log_level);
 break;
 case AV_PKT_DATA_AMBIENT_VIEWING_ENVIRONMENT:
-dump_ambient_viewing_environment_metadata(ctx, sd);
+dump_ambient_viewing_environment_metadata(ctx, sd, log_level);
 break;
 case AV_PKT_DATA_FRAME_CROPPING:
-dump_cropping(ctx, sd);
+dump_cropping(ctx, sd, log_level);
 break;
 case AV_PKT_DATA_3D_REFERENCE_DISPLAYS:
-dump_tdrdi(ctx, sd);
+dump_tdrdi(ctx, sd, log_level);
 break;
 default:
 if (name)
@@ -678,7 +678,7 @@ FF_ENABLE_DEPRECATION_WARNINGS
 
 if (st->start_time != AV_NOPTS_VALUE && st->start_time != 0 && 
st->time_base.den && st->time_base.num) {
 const double stream_start = av_q2d(st->time_base) * st->start_time;
-av_log(NULL, AV_LOG_INFO, ", start %.6f", stream_start);
+av_log(NULL, log_level, ", start %.6f", stream_start);
 }
 
 dump_disposition(st->disposition, log_level);

---

Summary of changes:
 libavformat/dump.c | 24 
 1 file changed, 12 insertions(+), 12 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. f1a155d975 avcodec/aarch64/vvc: Optimize dmvr_hv_10

2025-09-21 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  f1a155d9754f2f38da121b8935ea1a5483021a5a (commit)
  from  0bd5a7d3719456f049f4d29abb313968ccacb28c (commit)


- Log -
commit f1a155d9754f2f38da121b8935ea1a5483021a5a
Author: Krzysztof Pyrkosz 
AuthorDate: Fri Sep 5 19:52:11 2025 +0200
Commit: Martin Storsjö 
CommitDate: Sun Sep 21 19:39:27 2025 +

avcodec/aarch64/vvc: Optimize dmvr_hv_10

Before and after on A53:
dmvr_hv_10_12x20_neon:1838.2 ( 3.02x)
dmvr_hv_10_20x12_neon:1330.2 ( 1.83x)
dmvr_hv_10_20x20_neon:2148.2 ( 1.85x)
dmvr_hv_12_12x20_neon:1839.2 ( 3.02x)
dmvr_hv_12_20x12_neon:1330.6 ( 1.83x)
dmvr_hv_12_20x20_neon:2147.2 ( 1.85x)

dmvr_hv_10_12x20_neon:1755.0 ( 3.17x)
dmvr_hv_10_20x12_neon:1165.8 ( 2.09x)
dmvr_hv_10_20x20_neon:1876.1 ( 2.12x)
dmvr_hv_12_12x20_neon:1754.4 ( 3.17x)
dmvr_hv_12_20x12_neon:1167.8 ( 2.09x)
dmvr_hv_12_20x20_neon:1878.8 ( 2.12x)

diff --git a/libavcodec/aarch64/vvc/inter.S b/libavcodec/aarch64/vvc/inter.S
index 01d2ff155c..79ff720cdd 100644
--- a/libavcodec/aarch64/vvc/inter.S
+++ b/libavcodec/aarch64/vvc/inter.S
@@ -599,18 +599,13 @@ function ff_vvc_dmvr_hv_8_neon, export=1
 endfunc
 
 function ff_vvc_dmvr_hv_12_neon, export=1
-moviv29.4s, #(12 - 6)
-moviv30.4s, #(1 << (12 - 7))// offset1
+mvniv29.4s, #(12 - 6 - 1)
 b   0f
 endfunc
 
 function ff_vvc_dmvr_hv_10_neon, export=1
-moviv29.4s, #(10 - 6)
-moviv30.4s, #(1 << (10 - 7))// offset1
+mvniv29.4s, #(10 - 6 - 1)
 0:
-moviv31.4s, #8  // offset2
-neg v29.4s, v29.4s
-
 sub sp, sp, #(VVC_MAX_PB_SIZE * 4)
 
 movrel  x9, X(ff_vvc_inter_luma_dmvr_filters)
@@ -626,7 +621,6 @@ function ff_vvc_dmvr_hv_10_neon, export=1
 add x12, x9, my, lsl #1
 ldrbw10, [x12]
 ldrbw11, [x12, #1]
-sxtwx6, w6
 dup v2.8h, w10  // filter_y[0]
 dup v3.8h, w11  // filter_y[1]
 
@@ -635,7 +629,7 @@ function ff_vvc_dmvr_hv_10_neon, export=1
 mov w10, #0 // start filter_y or not
 add height, height, #1
 sub dst, dst, #(VVC_MAX_PB_SIZE * 2)
-sub src_stride, src_stride, x6, lsl #1
+sub src_stride, src_stride, w6, sxtw #1
 csetw15, gt // width > 16
 1:
 mov x12, tmp0
@@ -656,14 +650,10 @@ function ff_vvc_dmvr_hv_10_neon, export=1
 umlal   v18.4s, v17.4h, v1.4h
 umlal2  v19.4s, v17.8h, v1.8h
 
-add v4.4s, v4.4s, v30.4s
-add v5.4s, v5.4s, v30.4s
-add v18.4s, v18.4s, v30.4s
-add v19.4s, v19.4s, v30.4s
-ushlv4.4s, v4.4s, v29.4s
-ushlv5.4s, v5.4s, v29.4s
-ushlv18.4s, v18.4s, v29.4s
-ushlv19.4s, v19.4s, v29.4s
+urshl   v4.4s, v4.4s, v29.4s
+urshl   v5.4s, v5.4s, v29.4s
+urshl   v18.4s, v18.4s, v29.4s
+urshl   v19.4s, v19.4s, v29.4s
 uqxtn   v6.4h, v4.4s
 uqxtn2  v6.8h, v5.4s
 uqxtn   v7.4h, v18.4s
@@ -681,18 +671,10 @@ function ff_vvc_dmvr_hv_10_neon, export=1
 umlal2  v18.4s, v6.8h, v3.8h
 umlal   v19.4s, v7.4h, v3.4h
 umlal2  v20.4s, v7.8h, v3.8h
-add v17.4s, v17.4s, v31.4s
-add v18.4s, v18.4s, v31.4s
-add v19.4s, v19.4s, v31.4s
-add v20.4s, v20.4s, v31.4s
-ushrv17.4s, v17.4s, #4
-ushrv18.4s, v18.4s, #4
-ushrv19.4s, v19.4s, #4
-ushrv20.4s, v20.4s, #4
-uqxtn   v6.4h, v17.4s
-uqxtn2  v6.8h, v18.4s
-uqxtn   v7.4h, v19.4s
-uqxtn2  v7.8h, v20.4s
+uqrshrn v6.4h, v17.4s, #4
+uqrshrn2v6.8h, v18.4s, #4
+uqrshrn v7.4h, v19.4s, #4
+uqrshrn2v7.8h, v20.4s, #4
 stp q6, q7, [x14], #32
 b   3f
 2:
@@ -704,10 +686,8 @@ function ff_vvc_d

[FFmpeg-cvslog] [ffmpeg] branch master updated. c9168717bf avcodec/h274: Make H274FilmGrainDatabase a shared object

2025-09-21 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  c9168717bf4c7d6f72d5cb02064ce832f4af9c89 (commit)
  from  b5e0d9f648712198e83566ea8a49498127f370d2 (commit)


- Log -
commit c9168717bf4c7d6f72d5cb02064ce832f4af9c89
Author: Andreas Rheinhardt 
AuthorDate: Thu Sep 18 17:57:16 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Mon Sep 22 04:54:22 2025 +0200

avcodec/h274: Make H274FilmGrainDatabase a shared object

Right now, the private contexts of every decoder supporting
H.274 film grain synthesis (namely H.264, HEVC and VVC)
contain a H274FilmGrainDatabase; said structure is very large
700442B before this commit) and takes up the overwhelming
majority of said contexts: Removing it reduces sizeof(H264Context)
by 92.88%, sizeof(HEVCContext) by 97.78% and sizeof(VVCContext)
by 99.86%. This is especially important for H.264 and HEVC
when using frame-threading.

The content of said film grain database does not depend on
any input parameter; it is shareable between all its users and
could be hardcoded in the binary (but isn't, because it is so huge).

This commit adds a database with static storage duration to h274.c
and uses it instead of the elements in the private contexts above.
It is still lazily initialized as-needed; a mutex is used
for the necessary synchronization. An alternative would be to use
an AV_ONCE to initialize the whole database either in the decoders'
init function (which would be wasteful given that most videos
don't use film grain synthesis) or in ff_h274_apply_film_grain().

Reviewed-by: Niklas Haas 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/h264_picture.c b/libavcodec/h264_picture.c
index f5d2b31cd6..aa3d2629c8 100644
--- a/libavcodec/h264_picture.c
+++ b/libavcodec/h264_picture.c
@@ -30,10 +30,10 @@
 #include "error_resilience.h"
 #include "avcodec.h"
 #include "h264dec.h"
+#include "h274.h"
 #include "hwaccel_internal.h"
 #include "mpegutils.h"
 #include "libavutil/refstruct.h"
-#include "thread.h"
 #include "threadframe.h"
 
 void ff_h264_unref_picture(H264Picture *pic)
@@ -213,7 +213,7 @@ int ff_h264_field_end(H264Context *h, H264SliceContext *sl, 
int in_setup)
 
 err = AVERROR_INVALIDDATA;
 if (sd) // a decoding error may have happened before the side data 
could be allocated
-err = ff_h274_apply_film_grain(cur->f_grain, cur->f, &h->h274db,
+err = ff_h274_apply_film_grain(cur->f_grain, cur->f,
(AVFilmGrainParams *) sd->data);
 if (err < 0) {
 av_log(h->avctx, AV_LOG_WARNING, "Failed synthesizing film "
diff --git a/libavcodec/h264dec.h b/libavcodec/h264dec.h
index 1df99015cc..74fd09dfaa 100644
--- a/libavcodec/h264dec.h
+++ b/libavcodec/h264dec.h
@@ -28,7 +28,6 @@
 #ifndef AVCODEC_H264DEC_H
 #define AVCODEC_H264DEC_H
 
-#include "libavutil/buffer.h"
 #include "libavutil/mem_internal.h"
 
 #include "cabac.h"
@@ -41,7 +40,6 @@
 #include "h264dsp.h"
 #include "h264pred.h"
 #include "h264qpel.h"
-#include "h274.h"
 #include "mpegutils.h"
 #include "threadframe.h"
 #include "videodsp.h"
@@ -344,7 +342,6 @@ typedef struct H264Context {
 H264DSPContext h264dsp;
 H264ChromaContext h264chroma;
 H264QpelContext h264qpel;
-H274FilmGrainDatabase h274db;
 
 H264Picture DPB[H264_MAX_PICTURE_COUNT];
 H264Picture *cur_pic_ptr;
diff --git a/libavcodec/h274.c b/libavcodec/h274.c
index 332d0c2c52..93ad2d1014 100644
--- a/libavcodec/h274.c
+++ b/libavcodec/h274.c
@@ -25,6 +25,8 @@
  * @author Niklas Haas 
  */
 
+#include 
+
 #include "libavutil/avassert.h"
 #include "libavutil/bswap.h"
 #include "libavcodec/bswapdsp.h"
@@ -32,9 +34,18 @@
 #include "libavutil/imgutils.h"
 #include "libavutil/md5.h"
 #include "libavutil/mem.h"
+#include "libavutil/thread.h"
 
 #include "h274.h"
 
+typedef struct H274FilmGrainDatabase {
+// Database of film grain patterns, lazily computed as-needed
+int8_t db[13 /* h */][13 /* v */][64][64];
+atomic_uint residency[6];
+} H274FilmGrainDatabase;
+
+static H274FilmGrainDatabase film_grain_db;
+
 static const int8_t Gaussian_LUT[2048+4];
 static const uint32_t Seed_LUT[256];
 static const int8_t R64T[64][64];
@@ -47,8 +58,7 @@ static void prng_shift(uint32_t *state)
 *state = (x << 1) | (feedback & 1u);
 }
 
-static void init_slice_c(int8_t out[64][64], uint8_t h, uint8_t v,
- int16_t tmp[64][64])
+static void init_slice_c(int8_t out[64][64], uint8_t h, uint8_t v)
 {
 static const uint8_t deblock_factors[13] = {
 64, 71, 77, 84, 90, 96, 103, 109, 116, 122, 128, 128, 128
@@ -57,6 +67,9 @@ static void init_slice_c(int8_t out[64][64], uint8_t h, 
uint8_t v,
 const uint8_t deblock_coeff = deblock_factors[v];
 const uint8_t freq_h = ((h + 3) << 2) - 1;
 const uint8_t freq_v = ((v + 3) << 2) - 1;
+

[FFmpeg-cvslog] [ffmpeg] branch master updated. b5e0d9f648 fftools/opt_common: add separator line to show_filters output

2025-09-21 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  b5e0d9f648712198e83566ea8a49498127f370d2 (commit)
  from  f1a155d9754f2f38da121b8935ea1a5483021a5a (commit)


- Log -
commit b5e0d9f648712198e83566ea8a49498127f370d2
Author: zhanghongyuan 
AuthorDate: Tue Sep 2 15:03:39 2025 +0800
Commit: Zhao Zhili 
CommitDate: Mon Sep 22 02:47:40 2025 +

fftools/opt_common: add separator line to show_filters output

Add a separator line to show_filters() function output to maintain
consistent formatting with other show functions like show_codecs,
show_formats_devices, etc. This provides uniform formatting across
all command-line output functions for better readability and
parsing by external tools.

diff --git a/fftools/opt_common.c b/fftools/opt_common.c
index 5dcb14e261..e217456be7 100644
--- a/fftools/opt_common.c
+++ b/fftools/opt_common.c
@@ -809,7 +809,8 @@ int show_filters(void *optctx, const char *opt, const char 
*arg)
"  A = Audio input/output\n"
"  V = Video input/output\n"
"  N = Dynamic number and/or type of input/output\n"
-   "  | = Source or sink filter\n");
+   "  | = Source or sink filter\n"
+   "  --\n");
 while ((filter = av_filter_iterate(&opaque))) {
 descr_cur = descr;
 for (i = 0; i < 2; i++) {

---

Summary of changes:
 fftools/opt_common.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 371931250a avcodec/ohdec: Check mutex/conditions initialization

2025-09-24 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  371931250a2b8d9cf2a726d4992f9107af3df782 (commit)
   via  748fa0a9bbd807cb6b3b7964f3793caf68bb5ed0 (commit)
   via  320133aafc4103e1f8c85a2589d1818af9507b06 (commit)
  from  5cb6d2221a6d4c07453b6c301ecfcaed48402680 (commit)


- Log -
commit 371931250a2b8d9cf2a726d4992f9107af3df782
Author: Andreas Rheinhardt 
AuthorDate: Tue Sep 23 16:05:30 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Thu Sep 25 05:29:58 2025 +0200

avcodec/ohdec: Check mutex/conditions initialization

Reviewed-by: Zhao Zhili 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/ohdec.c b/libavcodec/ohdec.c
index 86f3c84279..943b027681 100644
--- a/libavcodec/ohdec.c
+++ b/libavcodec/ohdec.c
@@ -37,6 +37,7 @@
 #include "decode.h"
 #include "hwconfig.h"
 #include "ohcodec.h"
+#include "pthread_internal.h"
 
 typedef struct OHCodecDecContext {
 AVClass *avclass;
@@ -70,8 +71,14 @@ typedef struct OHCodecDecContext {
 
 char *name;
 int allow_sw;
+unsigned mutex_cond_cnt;
 } OHCodecDecContext;
 
+#define OFFSET(x) offsetof(OHCodecDecContext, x)
+DEFINE_OFFSET_ARRAY(OHCodecDecContext, mutex_cond, mutex_cond_cnt,
+(OFFSET(input_mutex), OFFSET(output_mutex)),
+(OFFSET(input_cond), OFFSET(output_cond)));
+
 typedef struct OHCodecBuffer {
 uint32_t index;
 OH_AVBuffer *buffer;
@@ -367,12 +374,11 @@ static av_cold int oh_decode_init(AVCodecContext *avctx)
 OHCodecDecContext *s = avctx->priv_data;
 
 // Initialize these fields first, so oh_decode_close can destroy them 
safely
-ff_mutex_init(&s->input_mutex, NULL);
-ff_cond_init(&s->input_cond, NULL);
-ff_mutex_init(&s->output_mutex, NULL);
-ff_cond_init(&s->output_cond, NULL);
+int ret = ff_pthread_init(s, mutex_cond_offsets);
+if (ret < 0)
+return ret;
 
-int ret = oh_decode_create(s, avctx);
+ret = oh_decode_create(s, avctx);
 if (ret < 0)
 return ret;
 ret = oh_decode_set_format(s, avctx);
@@ -414,14 +420,12 @@ static av_cold int oh_decode_close(AVCodecContext *avctx)
 
 av_packet_unref(&s->pkt);
 
-ff_mutex_destroy(&s->input_mutex);
-ff_cond_destroy(&s->input_cond);
 av_fifo_freep2(&s->input_queue);
 
-ff_mutex_destroy(&s->output_mutex);
-ff_cond_destroy(&s->output_cond);
 av_fifo_freep2(&s->output_queue);
 
+ff_pthread_free(s, mutex_cond_offsets);
+
 return 0;
 }
 
@@ -718,7 +722,6 @@ static const AVCodecHWConfigInternal *const oh_hw_configs[] 
= {
 NULL
 };
 
-#define OFFSET(x) offsetof(OHCodecDecContext, x)
 #define VD (AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_DECODING_PARAM)
 static const AVOption ohcodec_vdec_options[] = {
 {"codec_name", "Select codec by name",

commit 748fa0a9bbd807cb6b3b7964f3793caf68bb5ed0
Author: Andreas Rheinhardt 
AuthorDate: Tue Sep 23 15:52:09 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Thu Sep 25 05:29:26 2025 +0200

avcodec/ohdec: Switch to RefStruct API for internal refcounting

It avoids allocations and corresponding error conditions.

Reviewed-by: Zhao Zhili 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/ohdec.c b/libavcodec/ohdec.c
index 08b03a7e7b..86f3c84279 100644
--- a/libavcodec/ohdec.c
+++ b/libavcodec/ohdec.c
@@ -29,6 +29,7 @@
 #include "libavutil/imgutils.h"
 #include "libavutil/mem.h"
 #include "libavutil/opt.h"
+#include "libavutil/refstruct.h"
 #include "libavutil/thread.h"
 
 #include "avcodec.h"
@@ -40,11 +41,11 @@
 typedef struct OHCodecDecContext {
 AVClass *avclass;
 OH_AVCodec *dec;
-/* A reference count to dec. Each hardware frame has a reference count to
+/* A RefStruct reference backing dec. Each hardware frame has a reference 
count to
  * dec. dec will be destroyed only after oh_decode_close and all hardware
  * frames have been released.
  */
-AVBufferRef *dec_ref;
+OH_AVCodec **dec_ref;
 
 AVMutex input_mutex;
 AVCond input_cond;
@@ -74,13 +75,13 @@ typedef struct OHCodecDecContext {
 typedef struct OHCodecBuffer {
 uint32_t index;
 OH_AVBuffer *buffer;
-AVBufferRef *dec_ref;
+OH_AVCodec **dec_ref;  ///< RefStruct reference
 } OHCodecBuffer;
 
-static void oh_decode_release(void *opaque, uint8_t *data)
+static void oh_decode_release(AVRefStructOpaque unused, void *obj)
 {
-OH_AVCodec *dec = (OH_AVCodec *)data;
-OH_AVErrCode err = OH_VideoDecoder_Destroy(dec);
+OH_AVCodec **decp = obj;
+OH_AVErrCode err = OH_VideoDecoder_Destroy(*decp);
 if (err == AV_ERR_OK)
 av_log(NULL, AV_LOG_DEBUG, "Destroy decoder success\n");
 else
@@ -122,13 +123,13 @@ static int oh_decode_create(OHCodecDecContext *s, 
AVCodecContext *avctx)
 }
 av_log(avctx, AV_LOG_DEBUG, "Create decoder %s success\n", name);
 
-s->dec_ref = av_buffer_create((uint8_t *)s->dec, 0, oh_decode_release,
- 

[FFmpeg-cvslog] [ffmpeg] branch master updated. a54d6b1d91 avcodec/x86/rnd_template: Merge into hpeldsp_init.c

2025-09-25 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  a54d6b1d91ba17f6e1316997dd5f0ced4cee8ee5 (commit)
   via  43fe9554cc7998fbe0bae455c7b374e76a4d253f (commit)
   via  00e046df132fd1751c50798334b985beec89661f (commit)
   via  30c4007c65e1f73de5ce1b5eb459c71e0b21389a (commit)
   via  1e677e696488d52068e83c669ae871caa7c34583 (commit)
   via  262791b8d8c7a5e3df44c8784de192857e67d52f (commit)
   via  c7161befb4ae7d0f40e35676f52507e7de1c8b01 (commit)
   via  4fc05c28f426d6073e6e15db334b0c88ff925f1d (commit)
   via  5ef613bcb0508f16bd5b190168183326391de9b0 (commit)
   via  6a47ea5f9fdaedd6aa4bc8723c86a0c7a30d8ed1 (commit)
   via  918d37d9d156f15b63952a22bfba0541dd087129 (commit)
   via  e86f137514fb8a69cf145f26c83b1b053c727b52 (commit)
   via  2cf9e733c6a00423a0967f23341d9f09e3c8 (commit)
   via  1f9ef6a8dc6e57b360cf53dd644fde1936ad3047 (commit)
   via  8a7858dacf50797c7b81aad119e8811a849d0552 (commit)
   via  4d691da5edb360fa043df8ce267a382cfcdaf07a (commit)
   via  4e2ef29cbaa258cb73f06e62435198736e493a10 (commit)
   via  fcb9e0b5f019ec46dffb6d769793ccb7d884fb14 (commit)
   via  89f2016ece77868cc1982ae104d56b25aaf519c3 (commit)
   via  b316a1bdd122ca1bcb43b20dbd6bc9c244f98cfe (commit)
  from  baace56169a8cea7b44d727bdf656110aace011d (commit)


- Log -
commit a54d6b1d91ba17f6e1316997dd5f0ced4cee8ee5
Author: Andreas Rheinhardt 
AuthorDate: Tue Sep 23 05:01:41 2025 +0200
Commit: Andreas Rheinhardt 
CommitDate: Fri Sep 26 06:21:58 2025 +0200

avcodec/x86/rnd_template: Merge into hpeldsp_init.c

It is now only included exactly once.

Reviewed-by: Lynne 
Signed-off-by: Andreas Rheinhardt 

diff --git a/libavcodec/x86/hpeldsp_init.c b/libavcodec/x86/hpeldsp_init.c
index 66ed886ea9..cb47cb7752 100644
--- a/libavcodec/x86/hpeldsp_init.c
+++ b/libavcodec/x86/hpeldsp_init.c
@@ -33,6 +33,7 @@
 #include "libavcodec/pixels.h"
 #include "fpel.h"
 #include "hpeldsp.h"
+#include "inline_asm.h"
 
 void ff_put_pixels8_x2_mmxext(uint8_t *block, const uint8_t *pixels,
   ptrdiff_t line_size, int h);
@@ -73,15 +74,74 @@ void ff_avg_pixels8_y2_mmxext(uint8_t *block, const uint8_t 
*pixels,
 
 /***/
 /* MMX no rounding */
-#define DEF(x, y) x ## _no_rnd_ ## y ## _mmx
-#define SET_RND  MOVQ_WONE
-#define STATIC static
 
-#include "rnd_template.c"
+// put_pixels
+static void put_no_rnd_pixels8_xy2_mmx(uint8_t *block, const uint8_t *pixels,
+   ptrdiff_t line_size, int h)
+{
+MOVQ_ZERO(mm7);
+MOVQ_WONE(mm6); // =1 for no_rnd version
+__asm__ volatile(
+"movq   (%1), %%mm0 \n\t"
+"movq   1(%1), %%mm4\n\t"
+"movq   %%mm0, %%mm1\n\t"
+"movq   %%mm4, %%mm5\n\t"
+"punpcklbw %%mm7, %%mm0 \n\t"
+"punpcklbw %%mm7, %%mm4 \n\t"
+"punpckhbw %%mm7, %%mm1 \n\t"
+"punpckhbw %%mm7, %%mm5 \n\t"
+"paddusw %%mm0, %%mm4   \n\t"
+"paddusw %%mm1, %%mm5   \n\t"
+"xor%%"FF_REG_a", %%"FF_REG_a" \n\t"
+"add%3, %1  \n\t"
+".p2align 3 \n\t"
+"1: \n\t"
+"movq   (%1, %%"FF_REG_a"), %%mm0  \n\t"
+"movq   1(%1, %%"FF_REG_a"), %%mm2 \n\t"
+"movq   %%mm0, %%mm1\n\t"
+"movq   %%mm2, %%mm3\n\t"
+"punpcklbw %%mm7, %%mm0 \n\t"
+"punpcklbw %%mm7, %%mm2 \n\t"
+"punpckhbw %%mm7, %%mm1 \n\t"
+"punpckhbw %%mm7, %%mm3 \n\t"
+"paddusw %%mm2, %%mm0   \n\t"
+"paddusw %%mm3, %%mm1   \n\t"
+"paddusw %%mm6, %%mm4   \n\t"
+"paddusw %%mm6, %%mm5   \n\t"
+"paddusw %%mm0, %%mm4   \n\t"
+"paddusw %%mm1, %%mm5   \n\t"
+"psrlw  $2, %%mm4   \n\t"
+"psrlw  $2, %%mm5   \n\t"
+"packuswb  %%mm5, %%mm4 \n\t"
+"movq   %%mm4, (%2, %%"FF_REG_a")  \n\t"
+"add%3, %%"FF_REG_a"   \n\t"
+
+"movq   (%1, %%"FF_REG_a"), %%mm2  \n\t" // 0 <-> 2   1 <-> 3
+"movq   1(%1, %%"FF_REG_a"), %%mm4 \n\t"
+"movq   %%mm2, %%mm3\n\t"
+"movq   %%mm4, %%mm5\n\t"
+"punpcklbw %%mm7, %%mm2 \n\t"
+"punpcklbw %%mm7, %%mm4 \n\t"
+"punpckhbw %%mm7, %%mm3 \n\t"
+"punpckhbw %%mm7, %%mm5 \n\t"
+"paddusw %%mm2, %%mm4   \n\t"
+"paddusw %%mm3, %%mm5   \n\t"
+"paddusw %%mm6, %%mm0   \n\t"
+"paddusw %%mm6, %%mm1   \n\t"
+"paddusw %%mm4, %%mm0   \n\t"
+"paddusw %%mm5, %%mm1   \n\

[FFmpeg-cvslog] [ffmpeg] branch master updated. 6d8732f397 avformat/movenc: clear subsample information on fragment flush

2025-09-25 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  6d8732f397bfb07f2292e15a61904665abe13ce3 (commit)
  from  fa72f9a2921556923fa598317db4fcdc3c85ac24 (commit)


- Log -
commit 6d8732f397bfb07f2292e15a61904665abe13ce3
Author: James Almer 
AuthorDate: Tue Sep 16 21:45:00 2025 -0300
Commit: James Almer 
CommitDate: Thu Sep 25 23:18:08 2025 -0300

avformat/movenc: clear subsample information on fragment flush

Don't keep around information from a previous traf atom.

Fixes issue #20492.

Signed-off-by: James Almer 

diff --git a/libavformat/movenc.c b/libavformat/movenc.c
index bfe76a2034..067d38b14b 100644
--- a/libavformat/movenc.c
+++ b/libavformat/movenc.c
@@ -6592,6 +6592,9 @@ static int mov_flush_fragment(AVFormatContext *s, int 
force)
 mov_write_moof_tag(s->pb, mov, moof_tracks, mdat_size);
 mov->fragments++;
 
+if (track->cenc.aes_ctr)
+ff_mov_cenc_flush(&track->cenc);
+
 avio_wb32(s->pb, mdat_size + 8);
 ffio_wfourcc(s->pb, "mdat");
 mdat_start = avio_tell(s->pb);
diff --git a/libavformat/movenccenc.c b/libavformat/movenccenc.c
index 32094ebd7b..e5ae11a9c9 100644
--- a/libavformat/movenccenc.c
+++ b/libavformat/movenccenc.c
@@ -629,6 +629,12 @@ int ff_mov_cenc_init(MOVMuxCencContext* ctx, uint8_t* 
encryption_key,
 return 0;
 }
 
+void ff_mov_cenc_flush(MOVMuxCencContext* ctx)
+{
+ctx->auxiliary_info_entries = 0;
+ctx->auxiliary_info_size= 0;
+}
+
 void ff_mov_cenc_free(MOVMuxCencContext* ctx)
 {
 av_aes_ctr_free(ctx->aes_ctr);
diff --git a/libavformat/movenccenc.h b/libavformat/movenccenc.h
index 77a0716c81..f03e2fe6aa 100644
--- a/libavformat/movenccenc.h
+++ b/libavformat/movenccenc.h
@@ -91,6 +91,12 @@ int ff_mov_cenc_avc_write_nal_units(AVFormatContext *s, 
MOVMuxCencContext* ctx,
 
 int ff_mov_cenc_av1_write_obus(AVFormatContext *s, MOVMuxCencContext* ctx,
AVIOContext *pb, const AVPacket *pkt);
+
+/**
+ * Clear subsample data. To be called for fragmented output.
+ */
+void ff_mov_cenc_flush(MOVMuxCencContext* ctx);
+
 /**
  * Write the cenc atoms that should reside inside stbl
  */

---

Summary of changes:
 libavformat/movenc.c | 3 +++
 libavformat/movenccenc.c | 6 ++
 libavformat/movenccenc.h | 6 ++
 3 files changed, 15 insertions(+)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


[FFmpeg-cvslog] [ffmpeg] branch master updated. 994a368451 configure: deprecate support for libnpp

2025-09-26 Thread ffmpeg-git--- via ffmpeg-cvslog
The branch, master has been updated
   via  994a368451b37b97ed2ff76354fd97d5c6a0fff2 (commit)
  from  a54d6b1d91ba17f6e1316997dd5f0ced4cee8ee5 (commit)


- Log -
commit 994a368451b37b97ed2ff76354fd97d5c6a0fff2
Author: Timo Rothenpieler 
AuthorDate: Fri Sep 19 17:35:29 2025 +0200
Commit: Timo Rothenpieler 
CommitDate: Fri Sep 26 12:31:39 2025 +

configure: deprecate support for libnpp

diff --git a/configure b/configure
index a01f0fbba4..2cb39cbd57 100755
--- a/configure
+++ b/configure
@@ -7190,9 +7190,13 @@ enabled libmp3lame&& require "libmp3lame >= 
3.98.3" lame/lame.h lame_set
 enabled libmpeghdec   && require_pkg_config libmpeghdec "mpeghdec >= 
3.0.0" mpeghdec/mpeghdecoder.h mpeghdecoder_init
 enabled libmysofa && { check_pkg_config libmysofa libmysofa mysofa.h 
mysofa_neighborhood_init_withstepdefine ||
require libmysofa mysofa.h 
mysofa_neighborhood_init_withstepdefine -lmysofa $zlib_extralibs; }
-enabled libnpp&& { check_lib libnpp npp.h nppGetLibVersion -lnppig 
-lnppicc -lnppc -lnppidei -lnppif ||
+enabled libnpp&& { test_cpp_condition "$(cd "$source_path"; 
pwd)/libavfilter/version_major.h" FF_API_LIBNPP_SUPPORT ||
+   die "ERROR: libnpp support is removed in this 
version"; } &&
+ { check_lib libnpp npp.h nppGetLibVersion -lnppig 
-lnppicc -lnppc -lnppidei -lnppif ||
check_lib libnpp npp.h nppGetLibVersion -lnppi 
-lnppif -lnppc -lnppidei ||
-   die "ERROR: libnpp not found"; }
+   die "ERROR: libnpp not found"; } &&
+ { check_func_headers "nppi.h" 
nppiYCbCr420_8u_P2P3R $libnpp_extralibs ||
+   die "ERROR: libnpp support is deprecated, 
version 13.0 and up are not supported"; }
 enabled libopencore_amrnb && require libopencore_amrnb 
opencore-amrnb/interf_dec.h Decoder_Interface_init -lopencore-amrnb
 enabled libopencore_amrwb && require libopencore_amrwb opencore-amrwb/dec_if.h 
D_IF_init -lopencore-amrwb
 enabled libopencv && { check_headers opencv2/core/core_c.h &&
diff --git a/libavfilter/version_major.h b/libavfilter/version_major.h
index af6f59832f..539d5caa3d 100644
--- a/libavfilter/version_major.h
+++ b/libavfilter/version_major.h
@@ -37,5 +37,6 @@
 
 #define FF_API_BUFFERSINK_OPTS (LIBAVFILTER_VERSION_MAJOR < 12)
 #define FF_API_CONTEXT_PUBLIC  (LIBAVFILTER_VERSION_MAJOR < 12)
+#define FF_API_LIBNPP_SUPPORT  (LIBAVFILTER_VERSION_MAJOR < 12)
 
 #endif /* AVFILTER_VERSION_MAJOR_H */
diff --git a/libavfilter/vf_scale_npp.c b/libavfilter/vf_scale_npp.c
index 1b1b7b9fc9..0529db3a29 100644
--- a/libavfilter/vf_scale_npp.c
+++ b/libavfilter/vf_scale_npp.c
@@ -281,6 +281,8 @@ static av_cold int nppscale_init(AVFilterContext* ctx)
 NPPScaleContext* scale = ctx->priv;
 int i, ret;
 
+av_log(ctx, AV_LOG_WARNING, "The libnpp based filters are deprecated.\n");
+
 if (!strcmp(scale->format_str, "same")) {
 scale->format = AV_PIX_FMT_NONE;
 } else {
diff --git a/libavfilter/vf_sharpen_npp.c b/libavfilter/vf_sharpen_npp.c
index c7769f5837..3ec74f8c0c 100644
--- a/libavfilter/vf_sharpen_npp.c
+++ b/libavfilter/vf_sharpen_npp.c
@@ -53,6 +53,8 @@ static int nppsharpen_init(AVFilterContext* ctx)
 {
 NPPSharpenContext* s = ctx->priv;
 
+av_log(ctx, AV_LOG_WARNING, "The libnpp based filters are deprecated.\n");
+
 s->own_frame = av_frame_alloc();
 if (!s->own_frame)
 goto fail;
diff --git a/libavfilter/vf_transpose_npp.c b/libavfilter/vf_transpose_npp.c
index e781d7c58b..2315b1043a 100644
--- a/libavfilter/vf_transpose_npp.c
+++ b/libavfilter/vf_transpose_npp.c
@@ -85,6 +85,8 @@ static int npptranspose_init(AVFilterContext *ctx)
 NPPTransposeContext *s = ctx->priv;
 int i;
 
+av_log(ctx, AV_LOG_WARNING, "The libnpp based filters are deprecated.\n");
+
 for (i = 0; i < FF_ARRAY_ELEMS(s->stages); i++) {
 s->stages[i].frame = av_frame_alloc();
 if (!s->stages[i].frame)

---

Summary of changes:
 configure  | 8 ++--
 libavfilter/version_major.h| 1 +
 libavfilter/vf_scale_npp.c | 2 ++
 libavfilter/vf_sharpen_npp.c   | 2 ++
 libavfilter/vf_transpose_npp.c | 2 ++
 5 files changed, 13 insertions(+), 2 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]


  1   2   3   4   5   >