PR #23474 opened by James Almer (jamrial)
URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/23474
Patch URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/23474.patch

None of the existing aac tests use edit lists to signal priming and remainder 
samples. Also, no test exists for the Ogg or Matroska demuxers implementations 
either, so add some using Opus.

```fate-samples
audiomatch/tones_fdkaac_44100_stereo_aac_he.m4a
audiomatch/tones_fdkaac_44100_stereo_aac_he2.m4a
audiomatch/tones_fdkaac_44100_stereo_aac_lc.m4a
audiomatch/tones_opus_48000_stereo.mka
audiomatch/tones_opus_48000_stereo.opus
```


>From c574a002d1fd24ff216c23ae4590b57ed5d1f83b Mon Sep 17 00:00:00 2001
From: James Almer <[email protected]>
Date: Sat, 13 Jun 2026 23:03:23 -0300
Subject: [PATCH] tests/fate/gapless: add tests for Opus and aac in m4a with
 edit lists

None of the existing aac tests use edit lists to signal priming and remainder 
samples.
Also, no test exists for the Ogg or Matroska demuxers implementations either, 
so add
some using Opus.

Signed-off-by: James Almer <[email protected]>
---
 tests/fate/gapless.mak                             | 14 ++++++++++++++
 .../ref/fate/audiomatch-fdkaac-44100-stereo-he-m4a |  1 +
 .../fate/audiomatch-fdkaac-44100-stereo-he2-m4a    |  1 +
 .../ref/fate/audiomatch-fdkaac-44100-stereo-lc-m4a |  1 +
 tests/ref/fate/audiomatch-opus-48000-stereo-mka    |  1 +
 tests/ref/fate/audiomatch-opus-48000-stereo-opus   |  1 +
 6 files changed, 19 insertions(+)
 create mode 100644 tests/ref/fate/audiomatch-fdkaac-44100-stereo-he-m4a
 create mode 100644 tests/ref/fate/audiomatch-fdkaac-44100-stereo-he2-m4a
 create mode 100644 tests/ref/fate/audiomatch-fdkaac-44100-stereo-lc-m4a
 create mode 100644 tests/ref/fate/audiomatch-opus-48000-stereo-mka
 create mode 100644 tests/ref/fate/audiomatch-opus-48000-stereo-opus

diff --git a/tests/fate/gapless.mak b/tests/fate/gapless.mak
index 9be8747988..c5addeebba 100644
--- a/tests/fate/gapless.mak
+++ b/tests/fate/gapless.mak
@@ -30,6 +30,10 @@ FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, 
ARESAMPLE_FILTER) += fate
 FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, ARESAMPLE_FILTER) += 
fate-audiomatch-dolby-44100-stereo-he2-mp4
 FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, ARESAMPLE_FILTER) += 
fate-audiomatch-dolby-44100-stereo-lc-mp4
 
+FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, ARESAMPLE_FILTER) += 
fate-audiomatch-fdkaac-44100-stereo-he-m4a
+FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, ARESAMPLE_FILTER) += 
fate-audiomatch-fdkaac-44100-stereo-he2-m4a
+FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, ARESAMPLE_FILTER) += 
fate-audiomatch-fdkaac-44100-stereo-lc-m4a
+
 FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, ARESAMPLE_FILTER) += 
fate-audiomatch-nero-16000-mono-lc-m4a
 FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, ARESAMPLE_FILTER) += 
fate-audiomatch-nero-44100-mono-lc-m4a
 FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, ARESAMPLE_FILTER) += 
fate-audiomatch-nero-16000-mono-he-m4a
@@ -41,6 +45,9 @@ FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, 
ARESAMPLE_FILTER) += fate
 FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, ARESAMPLE_FILTER) += 
fate-audiomatch-nero-16000-stereo-lc-m4a
 FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, ARESAMPLE_FILTER) += 
fate-audiomatch-nero-44100-stereo-lc-m4a
 
+FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE OPUS, WAV OGG, ARESAMPLE_FILTER) += 
fate-audiomatch-opus-48000-stereo-opus
+FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE OPUS, WAV MATROSKA, ARESAMPLE_FILTER) 
+= fate-audiomatch-opus-48000-stereo-mka
+
 FATE_GAPLESS-$(call TRANSCODE, PCM_S16LE AAC, WAV MOV, ARESAMPLE_FILTER) += 
fate-audiomatch-quicktime7-44100-stereo-lc-mp4 
fate-audiomatch-quicktimeX-44100-stereo-lc-m4a
 
 fate-audiomatch-square-aac: CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/square3.m4a $(SAMPLES)/audiomatch/square3.wav
@@ -81,6 +88,10 @@ fate-audiomatch-faac-44100-mono-lc-m4a:  CMD = audio_match 
$(TARGET_SAMPLES)/aud
 fate-audiomatch-faac-44100-stereo-lc-adts: CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_faac_44100_stereo_aac_lc.adts  
$(SAMPLES)/audiomatch/tones_44100_stereo.wav
 fate-audiomatch-faac-44100-stereo-lc-m4a:  CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_faac_44100_stereo_aac_lc.m4a   
$(SAMPLES)/audiomatch/tones_44100_stereo.wav
 
+fate-audiomatch-fdkaac-44100-stereo-lc-m4a:  CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_fdkaac_44100_stereo_aac_lc.m4a   
$(SAMPLES)/audiomatch/tones_44100_stereo.wav
+fate-audiomatch-fdkaac-44100-stereo-he-m4a:  CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_fdkaac_44100_stereo_aac_he.m4a   
$(SAMPLES)/audiomatch/tones_44100_stereo.wav
+fate-audiomatch-fdkaac-44100-stereo-he2-m4a: CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_fdkaac_44100_stereo_aac_he2.m4a  
$(SAMPLES)/audiomatch/tones_44100_stereo.wav
+
 fate-audiomatch-nero-16000-mono-lc-m4a:  CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_nero_16000_mono_aac_lc.m4a   
$(SAMPLES)/audiomatch/tones_16000_mono.wav
 fate-audiomatch-nero-16000-mono-he-m4a:  CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_nero_16000_mono_aac_he.m4a   
$(SAMPLES)/audiomatch/tones_16000_mono.wav
 fate-audiomatch-nero-16000-stereo-lc-m4a:  CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_nero_16000_stereo_aac_lc.m4a   
$(SAMPLES)/audiomatch/tones_16000_stereo.wav
@@ -92,6 +103,9 @@ fate-audiomatch-nero-44100-stereo-lc-m4a:  CMD = audio_match 
$(TARGET_SAMPLES)/a
 fate-audiomatch-nero-44100-stereo-he-m4a:  CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_nero_44100_stereo_aac_he.m4a   
$(SAMPLES)/audiomatch/tones_44100_stereo.wav
 fate-audiomatch-nero-44100-stereo-he2-m4a: CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_nero_44100_stereo_aac_he2.m4a  
$(SAMPLES)/audiomatch/tones_44100_stereo.wav
 
+fate-audiomatch-opus-48000-stereo-opus: CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_opus_48000_stereo.opus  
$(SAMPLES)/audiomatch/tones_44100_stereo.wav "-ar 44100"
+fate-audiomatch-opus-48000-stereo-mka:  CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_opus_48000_stereo.mka   
$(SAMPLES)/audiomatch/tones_44100_stereo.wav "-ar 44100"
+
 fate-audiomatch-quicktime7-44100-stereo-lc-mp4: CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_quicktime7_44100_stereo_aac_lc.mp4  
$(SAMPLES)/audiomatch/tones_44100_stereo.wav
 fate-audiomatch-quicktimeX-44100-stereo-lc-m4a: CMD = audio_match 
$(TARGET_SAMPLES)/audiomatch/tones_quicktimeX_44100_stereo_aac_lc.m4a  
$(SAMPLES)/audiomatch/tones_44100_stereo.wav
 
diff --git a/tests/ref/fate/audiomatch-fdkaac-44100-stereo-he-m4a 
b/tests/ref/fate/audiomatch-fdkaac-44100-stereo-he-m4a
new file mode 100644
index 0000000000..80d1a71356
--- /dev/null
+++ b/tests/ref/fate/audiomatch-fdkaac-44100-stereo-he-m4a
@@ -0,0 +1 @@
+presig: 1922 postsig:1902 c: 0.9933 lenerr:3824
diff --git a/tests/ref/fate/audiomatch-fdkaac-44100-stereo-he2-m4a 
b/tests/ref/fate/audiomatch-fdkaac-44100-stereo-he2-m4a
new file mode 100644
index 0000000000..21076f5e77
--- /dev/null
+++ b/tests/ref/fate/audiomatch-fdkaac-44100-stereo-he2-m4a
@@ -0,0 +1 @@
+presig: 1922 postsig:1902 c: 0.9900 lenerr:3824
diff --git a/tests/ref/fate/audiomatch-fdkaac-44100-stereo-lc-m4a 
b/tests/ref/fate/audiomatch-fdkaac-44100-stereo-lc-m4a
new file mode 100644
index 0000000000..2289c8f0db
--- /dev/null
+++ b/tests/ref/fate/audiomatch-fdkaac-44100-stereo-lc-m4a
@@ -0,0 +1 @@
+presig: 0 postsig:1776 c: 0.9990 lenerr:1776
diff --git a/tests/ref/fate/audiomatch-opus-48000-stereo-mka 
b/tests/ref/fate/audiomatch-opus-48000-stereo-mka
new file mode 100644
index 0000000000..4ff2bd21cd
--- /dev/null
+++ b/tests/ref/fate/audiomatch-opus-48000-stereo-mka
@@ -0,0 +1 @@
+presig: 0 postsig:0 c: 1.0007 lenerr:0
diff --git a/tests/ref/fate/audiomatch-opus-48000-stereo-opus 
b/tests/ref/fate/audiomatch-opus-48000-stereo-opus
new file mode 100644
index 0000000000..4ff2bd21cd
--- /dev/null
+++ b/tests/ref/fate/audiomatch-opus-48000-stereo-opus
@@ -0,0 +1 @@
+presig: 0 postsig:0 c: 1.0007 lenerr:0
-- 
2.52.0

_______________________________________________
ffmpeg-devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to