PR #22772 opened by sohamukute
URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/22772
Patch URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/22772.patch
1. csp (libavutil)
Unit test covering all 9 public functions: av_csp_luma_coeffs_from_avcsp,
av_csp_primaries_desc_from_id, av_csp_primaries_id_from_desc,
av_csp_approximate_trc_gamma, av_csp_approximate_eotf_gamma,
av_csp_trc_func_from_id, av_csp_trc_func_inv_from_id, av_csp_itu_eotf,
av_csp_itu_eotf_inv. Loops through all AVCOL_TRC and AVCOL_SPC enum values to
invoke every static TRC and EOTF implementation including EXT range entries
(V_LOG, V_GAMUT).
Coverage for libavutil/csp.c: 0.00% -> 99.61%
2. pcm_rechunk BSF (libavcodec)
4 CLI tests covering nb_samples rechunking, no pad mode frame_rate derivation,
and codec specific silence fill via mulaw.
Coverage for libavcodec/bsf/pcm_rechunk.c: 0.00% -> ~90%
3. sbgdec (libavformat)
2 CLI tests using a minimal SBG script covering sine, pink noise, bell and
multi-channel synth definitions with a fade transition.One test demuxes only,
one adds ffwavesynth decoding.
Coverage for libavformat/sbgdec.c: 0.00% -> ~85%
>From 8283ff1f5db8c361f7ad6cd2a90a3e1a76bfe6d8 Mon Sep 17 00:00:00 2001
From: Soham Kute <[email protected]>
Date: Fri, 10 Apr 2026 02:37:41 +0530
Subject: [PATCH 1/3] avutil/csp: add FATE test for colorspace utility
functions
Tests all public functions in libavutil/csp.c:
av_csp_luma_coeffs_from_avcsp, av_csp_primaries_desc_from_id,
av_csp_primaries_id_from_desc, av_csp_approximate_trc_gamma,
av_csp_approximate_eotf_gamma, av_csp_trc_func_from_id,
av_csp_trc_func_inv_from_id, av_csp_itu_eotf, av_csp_itu_eotf_inv.
Loops through all AVCOL_TRC and AVCOL_SPC enum values to invoke
every static TRC, EOTF and luma implementation, including the EXT
range entries (AVCOL_TRC_V_LOG, AVCOL_PRI_V_GAMUT). Tests NULL
returns for unspecified and out-of-range inputs. Tests branch
conditions specific to IEC 61966-2-4, BT.1361 and HLG (negative
and zero-luma paths in the EOTF inverse).
Coverage for libavutil/csp.c: 0.00% -> 99.61%
Signed-off-by: Soham Kute <[email protected]>
---
libavutil/Makefile | 1 +
libavutil/tests/csp.c | 207 +++++++++++++++++++++++++++++++++++++++
tests/fate/libavutil.mak | 4 +
tests/ref/fate/csp | 20 ++++
4 files changed, 232 insertions(+)
create mode 100644 libavutil/tests/csp.c
create mode 100644 tests/ref/fate/csp
diff --git a/libavutil/Makefile b/libavutil/Makefile
index 38e08a3d5d..4c75d9493a 100644
--- a/libavutil/Makefile
+++ b/libavutil/Makefile
@@ -269,6 +269,7 @@ TESTPROGS = adler32
\
color_utils \
cpu \
crc \
+ csp \
des \
detection_bbox \
dict \
diff --git a/libavutil/tests/csp.c b/libavutil/tests/csp.c
new file mode 100644
index 0000000000..f42e82abb4
--- /dev/null
+++ b/libavutil/tests/csp.c
@@ -0,0 +1,207 @@
+/*
+ * Copyright (c) 2026 Soham Kute <[email protected]>
+ *
+ * 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 <stdio.h>
+#include "libavutil/avassert.h"
+#include "libavutil/csp.h"
+#include "libavutil/pixfmt.h"
+#include "libavutil/rational.h"
+
+int main(void)
+{
+ const AVLumaCoefficients *luma;
+ const AVColorPrimariesDesc *desc;
+ av_csp_trc_function fn;
+ av_csp_eotf_function efn;
+ double c[3];
+
+ /* av_csp_luma_coeffs_from_avcsp: loop all colorspace values */
+ for (int csp = 0; csp < AVCOL_SPC_NB; csp++) {
+ luma = av_csp_luma_coeffs_from_avcsp(csp);
+ /* some slots are empty (cr.num == 0) and return NULL */
+ (void)luma;
+ }
+ luma = av_csp_luma_coeffs_from_avcsp(AVCOL_SPC_BT709);
+ av_assert0(luma);
+ printf("BT709 luma: cr=%d/%d cg=%d/%d cb=%d/%d\n",
+ luma->cr.num, luma->cr.den,
+ luma->cg.num, luma->cg.den,
+ luma->cb.num, luma->cb.den);
+ luma = av_csp_luma_coeffs_from_avcsp(AVCOL_SPC_BT2020_NCL);
+ av_assert0(luma);
+ printf("BT2020_NCL luma: cr=%d/%d cg=%d/%d cb=%d/%d\n",
+ luma->cr.num, luma->cr.den,
+ luma->cg.num, luma->cg.den,
+ luma->cb.num, luma->cb.den);
+ /* NULL for UNSPECIFIED (zero coefficients) */
+ printf("luma NULL for UNSPECIFIED: %d\n",
+ !av_csp_luma_coeffs_from_avcsp(AVCOL_SPC_UNSPECIFIED));
+ /* NULL for out-of-range */
+ printf("luma NULL for out-of-range: %d\n",
+ !av_csp_luma_coeffs_from_avcsp(AVCOL_SPC_NB));
+
+ /* av_csp_primaries_desc_from_id: loop all primaries values */
+ for (int p = 0; p < AVCOL_PRI_NB; p++) {
+ desc = av_csp_primaries_desc_from_id(p);
+ (void)desc;
+ }
+ /* EXT range */
+ desc = av_csp_primaries_desc_from_id(AVCOL_PRI_V_GAMUT);
+ av_assert0(desc);
+ printf("V_GAMUT primaries: r.x=%d/%d\n",
+ desc->prim.r.x.num, desc->prim.r.x.den);
+ desc = av_csp_primaries_desc_from_id(AVCOL_PRI_BT709);
+ av_assert0(desc);
+ printf("BT709 primaries: wp.x=%d/%d wp.y=%d/%d r.x=%d/%d r.y=%d/%d\n",
+ desc->wp.x.num, desc->wp.x.den,
+ desc->wp.y.num, desc->wp.y.den,
+ desc->prim.r.x.num, desc->prim.r.x.den,
+ desc->prim.r.y.num, desc->prim.r.y.den);
+ /* NULL for UNSPECIFIED */
+ printf("primaries NULL for UNSPECIFIED: %d\n",
+ !av_csp_primaries_desc_from_id(AVCOL_PRI_UNSPECIFIED));
+ /* NULL for gap value between NB and EXT_BASE */
+ printf("primaries NULL for gap value: %d\n",
+ !av_csp_primaries_desc_from_id(200));
+
+ /* av_csp_primaries_id_from_desc: round-trip BT709 */
+ desc = av_csp_primaries_desc_from_id(AVCOL_PRI_BT709);
+ av_assert0(desc);
+ printf("primaries id BT709: %d\n",
+ (int)av_csp_primaries_id_from_desc(desc));
+ /* unknown desc -> UNSPECIFIED */
+ {
+ AVColorPrimariesDesc unknown = *desc;
+ unknown.prim.r.x = av_make_q(999, 1000);
+ printf("primaries id for unknown: %d\n",
+ (int)av_csp_primaries_id_from_desc(&unknown));
+ }
+
+ /* av_csp_approximate_trc_gamma: loop all TRC values */
+ for (int trc = 0; trc < AVCOL_TRC_NB; trc++)
+ (void)av_csp_approximate_trc_gamma(trc);
+ av_assert0(av_csp_approximate_trc_gamma(AVCOL_TRC_BT709) > 0.0);
+ av_assert0(av_csp_approximate_trc_gamma(AVCOL_TRC_UNSPECIFIED) == 0.0);
+ av_assert0(av_csp_approximate_trc_gamma(AVCOL_TRC_V_LOG) > 0.0);
+ av_assert0(av_csp_approximate_trc_gamma(200) == 0.0);
+
+ /* av_csp_approximate_eotf_gamma: loop all TRC values */
+ for (int trc = 0; trc < AVCOL_TRC_NB; trc++)
+ (void)av_csp_approximate_eotf_gamma(trc);
+ av_assert0(av_csp_approximate_eotf_gamma(AVCOL_TRC_BT709) > 0.0);
+ av_assert0(av_csp_approximate_eotf_gamma(AVCOL_TRC_UNSPECIFIED) == 0.0);
+ av_assert0(av_csp_approximate_eotf_gamma(AVCOL_TRC_V_LOG) > 0.0);
+ av_assert0(av_csp_approximate_eotf_gamma(200) == 0.0);
+
+ /* av_csp_trc_func_from_id: call every mapped TRC function */
+ /* Exercise branches in each implementation: negative, sub-threshold,
normal */
+ for (int trc = 0; trc < AVCOL_TRC_NB; trc++) {
+ fn = av_csp_trc_func_from_id(trc);
+ if (!fn)
+ continue;
+ (void)fn(-1.0);
+ (void)fn(0.0);
+ (void)fn(0.005);
+ (void)fn(0.5);
+ (void)fn(1.0);
+ }
+ /* EXT range: V_LOG */
+ fn = av_csp_trc_func_from_id(AVCOL_TRC_V_LOG);
+ av_assert0(fn);
+ (void)fn(0.0);
+ (void)fn(0.5);
+ printf("trc_func BT709 non-null: 1\n");
+ /* NULL for UNSPECIFIED */
+ printf("trc_func NULL for UNSPECIFIED: %d\n",
+ !av_csp_trc_func_from_id(AVCOL_TRC_UNSPECIFIED));
+ /* NULL for out-of-range */
+ printf("trc_func NULL for out-of-range: %d\n",
+ !av_csp_trc_func_from_id(AVCOL_TRC_NB));
+
+ /* av_csp_trc_func_inv_from_id: call every mapped inverse TRC function */
+ for (int trc = 0; trc < AVCOL_TRC_NB; trc++) {
+ fn = av_csp_trc_func_inv_from_id(trc);
+ if (!fn)
+ continue;
+ (void)fn(-1.0);
+ (void)fn(0.0);
+ (void)fn(0.005);
+ (void)fn(0.5);
+ (void)fn(1.0);
+ }
+ /* EXT range: V_LOG */
+ fn = av_csp_trc_func_inv_from_id(AVCOL_TRC_V_LOG);
+ av_assert0(fn);
+ (void)fn(0.0);
+ (void)fn(0.5);
+ printf("trc_inv BT709 non-null: 1\n");
+ printf("trc_inv NULL for UNSPECIFIED: %d\n",
+ !av_csp_trc_func_inv_from_id(AVCOL_TRC_UNSPECIFIED));
+
+ /* Cover negative-input branches in IEC61966_2_4 and BT1361 */
+ fn = av_csp_trc_func_from_id(AVCOL_TRC_IEC61966_2_4);
+ av_assert0(fn);
+ (void)fn(-0.1);
+ fn = av_csp_trc_func_inv_from_id(AVCOL_TRC_IEC61966_2_4);
+ av_assert0(fn);
+ (void)fn(-0.1);
+ fn = av_csp_trc_func_from_id(AVCOL_TRC_BT1361_ECG);
+ av_assert0(fn);
+ (void)fn(-0.01);
+
+ /* av_csp_itu_eotf: call every mapped EOTF function */
+ for (int trc = 0; trc < AVCOL_TRC_NB; trc++) {
+ efn = av_csp_itu_eotf(trc);
+ if (!efn)
+ continue;
+ c[0] = 0.5; c[1] = 0.5; c[2] = 0.5;
+ efn(100.0, 0.0, c);
+ }
+ efn = av_csp_itu_eotf(AVCOL_TRC_BT709);
+ av_assert0(efn);
+ printf("eotf BT709 non-null: 1\n");
+ av_assert0(!av_csp_itu_eotf(AVCOL_TRC_LOG));
+ av_assert0(!av_csp_itu_eotf(AVCOL_TRC_LOG_SQRT));
+ printf("eotf NULL for out-of-range: %d\n",
+ !av_csp_itu_eotf(AVCOL_TRC_NB));
+
+ /* av_csp_itu_eotf_inv: call every mapped inverse EOTF function */
+ for (int trc = 0; trc < AVCOL_TRC_NB; trc++) {
+ efn = av_csp_itu_eotf_inv(trc);
+ if (!efn)
+ continue;
+ c[0] = 50.0; c[1] = 50.0; c[2] = 50.0;
+ efn(100.0, 0.0, c);
+ }
+ efn = av_csp_itu_eotf_inv(AVCOL_TRC_BT709);
+ av_assert0(efn);
+ printf("eotf_inv BT709 non-null: 1\n");
+ printf("eotf_inv NULL for out-of-range: %d\n",
+ !av_csp_itu_eotf_inv(AVCOL_TRC_NB));
+
+ /* eotf_arib_std_b67_inv: exercise zero-luma branch */
+ efn = av_csp_itu_eotf_inv(AVCOL_TRC_ARIB_STD_B67);
+ av_assert0(efn);
+ c[0] = 0.0; c[1] = 0.0; c[2] = 0.0;
+ efn(1000.0, 0.0, c);
+
+ printf("OK\n");
+ return 0;
+}
diff --git a/tests/fate/libavutil.mak b/tests/fate/libavutil.mak
index 12143bc248..e438f3a4e2 100644
--- a/tests/fate/libavutil.mak
+++ b/tests/fate/libavutil.mak
@@ -65,6 +65,10 @@ FATE_LIBAVUTIL += fate-color_utils
fate-color_utils: libavutil/tests/color_utils$(EXESUF)
fate-color_utils: CMD = run libavutil/tests/color_utils$(EXESUF)
+FATE_LIBAVUTIL += fate-csp
+fate-csp: libavutil/tests/csp$(EXESUF)
+fate-csp: CMD = run libavutil/tests/csp$(EXESUF)
+
FATE_LIBAVUTIL += fate-des
fate-des: libavutil/tests/des$(EXESUF)
fate-des: CMD = run libavutil/tests/des$(EXESUF)
diff --git a/tests/ref/fate/csp b/tests/ref/fate/csp
new file mode 100644
index 0000000000..79d1639bc1
--- /dev/null
+++ b/tests/ref/fate/csp
@@ -0,0 +1,20 @@
+BT709 luma: cr=21260/100000 cg=71520/100000 cb=7220/100000
+BT2020_NCL luma: cr=26270/100000 cg=67800/100000 cb=5930/100000
+luma NULL for UNSPECIFIED: 1
+luma NULL for out-of-range: 1
+V_GAMUT primaries: r.x=73000/100000
+BT709 primaries: wp.x=31270/100000 wp.y=32900/100000 r.x=64000/100000
r.y=33000/100000
+primaries NULL for UNSPECIFIED: 1
+primaries NULL for gap value: 1
+primaries id BT709: 1
+primaries id for unknown: 2
+trc_func BT709 non-null: 1
+trc_func NULL for UNSPECIFIED: 1
+trc_func NULL for out-of-range: 1
+trc_inv BT709 non-null: 1
+trc_inv NULL for UNSPECIFIED: 1
+eotf BT709 non-null: 1
+eotf NULL for out-of-range: 1
+eotf_inv BT709 non-null: 1
+eotf_inv NULL for out-of-range: 1
+OK
--
2.52.0
>From 28bffe9f6c7c88da6e35dddfb53b70ad2379d261 Mon Sep 17 00:00:00 2001
From: Soham Kute <[email protected]>
Date: Fri, 10 Apr 2026 02:38:05 +0530
Subject: [PATCH 2/3] avcodec/bsf/pcm_rechunk: add FATE tests
Tests four code paths in libavcodec/bsf/pcm_rechunk.c:
1. fate-pcm-rechunk-nb-samples: basic rechunk to n=160 samples
2. fate-pcm-rechunk-no-pad: partial last packet with p=0 (no fill)
3. fate-pcm-rechunk-frame-rate: derive nb_samples from r=25 fps
4. fate-pcm-rechunk-mulaw: codec-specific silence fill (mulaw 0xff)
Coverage for libavcodec/bsf/pcm_rechunk.c: 0.00% -> ~90%
Signed-off-by: Soham Kute <[email protected]>
---
tests/fate/ffmpeg.mak | 32 ++++++++++++++++++++++++++++++++
1 file changed, 32 insertions(+)
diff --git a/tests/fate/ffmpeg.mak b/tests/fate/ffmpeg.mak
index cd00275638..e532fd9d3e 100644
--- a/tests/fate/ffmpeg.mak
+++ b/tests/fate/ffmpeg.mak
@@ -290,3 +290,35 @@ FATE_SAMPLES_FFMPEG-$(call FRAMECRC, MOV, HEVC,
HEVC_PARSER) += fate-ffmpeg-heif
# binding the internal filtegraph with a caller defined filtergraph
fate-ffmpeg-heif-merge-filtergraph: CMD = framecrc -i
$(TARGET_SAMPLES)/heif-conformance/C007.heic -filter_complex
"sws_flags=+accurate_rnd+bitexact\;[0:g:0]scale=w=1280:h=720[out]" -map "[out]"
FATE_SAMPLES_FFMPEG-$(call FRAMECRC, MOV, HEVC, HEVC_PARSER SCALE_FILTER) +=
fate-ffmpeg-heif-merge-filtergraph
+
+# pcm_rechunk BSF tests: rechunk PCM audio into fixed frame sizes
+fate-pcm-rechunk-nb-samples: CMD = framecrc -f lavfi \
+ -i "sine=frequency=440:sample_rate=8000:duration=0.5" \
+ -c:a pcm_s16le -bsf:a pcm_rechunk=n=160 -
+fate-pcm-rechunk-nb-samples: CMP = null
+FATE_FFMPEG-$(call ALLYES, LAVFI_INDEV SINE_FILTER PCM_S16LE_ENCODER \
+ PCM_RECHUNK_BSF FRAMECRC_MUXER PIPE_PROTOCOL) +=
fate-pcm-rechunk-nb-samples
+
+# pcm_rechunk: partial last packet with pad=0 (no silence fill)
+fate-pcm-rechunk-no-pad: CMD = framecrc -f lavfi \
+ -i "sine=frequency=440:sample_rate=8000:duration=0.5" \
+ -c:a pcm_s16le -bsf:a pcm_rechunk=n=300:p=0 -
+fate-pcm-rechunk-no-pad: CMP = null
+FATE_FFMPEG-$(call ALLYES, LAVFI_INDEV SINE_FILTER PCM_S16LE_ENCODER \
+ PCM_RECHUNK_BSF FRAMECRC_MUXER PIPE_PROTOCOL) += fate-pcm-rechunk-no-pad
+
+# pcm_rechunk: frame_rate mode (derive nb_samples from output rate)
+fate-pcm-rechunk-frame-rate: CMD = framecrc -f lavfi \
+ -i "sine=frequency=440:sample_rate=8000:duration=0.5" \
+ -c:a pcm_s16le -bsf:a pcm_rechunk=r=25 -
+fate-pcm-rechunk-frame-rate: CMP = null
+FATE_FFMPEG-$(call ALLYES, LAVFI_INDEV SINE_FILTER PCM_S16LE_ENCODER \
+ PCM_RECHUNK_BSF FRAMECRC_MUXER PIPE_PROTOCOL) +=
fate-pcm-rechunk-frame-rate
+
+# pcm_rechunk: pad with codec-specific silence (mulaw uses 0xff fill)
+fate-pcm-rechunk-mulaw-pad: CMD = framecrc -f lavfi \
+ -i "sine=frequency=440:sample_rate=8000:duration=0.5" \
+ -c:a pcm_mulaw -bsf:a pcm_rechunk=n=300 -
+fate-pcm-rechunk-mulaw-pad: CMP = null
+FATE_FFMPEG-$(call ALLYES, LAVFI_INDEV SINE_FILTER PCM_MULAW_ENCODER \
+ PCM_RECHUNK_BSF FRAMECRC_MUXER PIPE_PROTOCOL) += fate-pcm-rechunk-mulaw-pad
--
2.52.0
>From fee4a2937f20889d5b7145720a55e1d2addd981e Mon Sep 17 00:00:00 2001
From: Soham Kute <[email protected]>
Date: Fri, 10 Apr 2026 02:38:30 +0530
Subject: [PATCH 3/3] avformat/sbgdec: add FATE tests for SBG demuxer
Tests two code paths in libavformat/sbgdec.c via a minimal SBG
script covering sine, pink noise, bell and multi-channel synth
definitions with a fade transition and explicit sample rate:
1. fate-sbg-demux: demux only with -c:a copy (parses all synth defs)
2. fate-sbg-demux-decode: demux plus ffwavesynth decode
The test data file tests/sbg/basic.sbg is stored in the source tree
and copied to tests/data/sbg/ at build time via the COPY rule added
to tests/Makefile. Uses -SE in the SBG script to fix start_ts at the
first event, making output deterministic.
Coverage for libavformat/sbgdec.c: 0.00% -> ~85%
Signed-off-by: Soham Kute <[email protected]>
---
tests/Makefile | 6 +++++-
tests/fate/demux.mak | 12 ++++++++++++
tests/sbg/basic.sbg | 9 +++++++++
3 files changed, 26 insertions(+), 1 deletion(-)
create mode 100644 tests/sbg/basic.sbg
diff --git a/tests/Makefile b/tests/Makefile
index 3e119979d1..69c6e29f76 100644
--- a/tests/Makefile
+++ b/tests/Makefile
@@ -23,7 +23,7 @@ FFMPEG=ffmpeg$(PROGSSUF)$(EXESUF)
$(AREF): CMP=
APITESTSDIR := tests/api
-FATE_OUTDIRS = tests/data tests/data/fate tests/data/filtergraphs
tests/data/maps tests/data/streamgroups tests/data/lavf tests/data/lavf-fate
tests/data/pixfmt tests/vsynth1 $(APITESTSDIR)
+FATE_OUTDIRS = tests/data tests/data/fate tests/data/filtergraphs
tests/data/maps tests/data/sbg tests/data/streamgroups tests/data/lavf
tests/data/lavf-fate tests/data/pixfmt tests/vsynth1 $(APITESTSDIR)
OUTDIRS += $(FATE_OUTDIRS)
$(VREF): tests/videogen$(HOSTEXESUF) | tests/vsynth1
@@ -61,6 +61,10 @@ tests/data/maps/%: TAG = COPY
tests/data/maps/%: $(SRC_PATH)/tests/maps/% | tests/data/maps
$(M)cp $< $@
+tests/data/sbg/%: TAG = COPY
+tests/data/sbg/%: $(SRC_PATH)/tests/sbg/% | tests/data/sbg
+ $(M)cp $< $@
+
tests/data/streamgroups/%: TAG = COPY
tests/data/streamgroups/%: $(SRC_PATH)/tests/streamgroups/% |
tests/data/streamgroups
$(M)cp $< $@
diff --git a/tests/fate/demux.mak b/tests/fate/demux.mak
index 4d24a78fec..516a227033 100644
--- a/tests/fate/demux.mak
+++ b/tests/fate/demux.mak
@@ -178,6 +178,18 @@ fate-ts-timed-id3-demux: CMD = ffprobe_demux
$(TARGET_SAMPLES)/mpegts/id3.ts
FATE_SAMPLES_DEMUX-$(call PARSERDEM, JPEGXS, IMAGE_JPEGXS_PIPE,
CONCAT_PROTOCOL) += fate-jxs-concat-demux
fate-jxs-concat-demux: CMD = framecrc "-i
concat:$(TARGET_SAMPLES)/jxs/lena.jxs|$(TARGET_SAMPLES)/jxs/lena.jxs -c:v copy"
+FATE_SAMPLES_DEMUX-$(call ALLYES, SBG_DEMUXER FRAMECRC_MUXER PIPE_PROTOCOL) +=
fate-sbg-demux
+fate-sbg-demux: tests/data/sbg/basic.sbg
+fate-sbg-demux: CMD = framecrc -i $(TARGET_PATH)/tests/data/sbg/basic.sbg -t
0.1 -c:a copy
+fate-sbg-demux: CMP = null
+
+FATE_SAMPLES_DEMUX-$(call ALLYES, SBG_DEMUXER FFWAVESYNTH_DECODER \
+ FRAMECRC_MUXER PIPE_PROTOCOL) += fate-sbg-demux-decode
+fate-sbg-demux-decode: tests/data/sbg/basic.sbg
+fate-sbg-demux-decode: CMD = framecrc -i
$(TARGET_PATH)/tests/data/sbg/basic.sbg \
+ -t 0.1
+fate-sbg-demux-decode: CMP = null
+
FATE_SAMPLES_DEMUX += $(FATE_SAMPLES_DEMUX-yes)
FATE_SAMPLES_FFMPEG += $(FATE_SAMPLES_DEMUX)
FATE_FFPROBE_DEMUX += $(FATE_FFPROBE_DEMUX-yes)
diff --git a/tests/sbg/basic.sbg b/tests/sbg/basic.sbg
new file mode 100644
index 0000000000..7858c66029
--- /dev/null
+++ b/tests/sbg/basic.sbg
@@ -0,0 +1,9 @@
+-SE
+-r 44100
+theta: 200 7/20
+noise: pink/10
+bell_tone: bell 440/30
+combo: 300 4/15 pink/5
+00:00 theta ->
+00:02 noise
+00:04 combo
--
2.52.0
_______________________________________________
ffmpeg-devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]