1# The samples were produced by simply rewrapping the official test vectors from 2# their custom format into Matroska. The reference decoded outputs are from the 3# newest testvectors file from RFC8251 4 5OPUS_CELT_SAMPLES = $(addprefix testvector, 01 11) tron.6ch.tinypkts 6OPUS_HYBRID_SAMPLES = $(addprefix testvector, 05 06) 7OPUS_SILK_SAMPLES = $(addprefix testvector, 02 03 04) 8OPUS_OTHER_SAMPLES = $(addprefix testvector, 07 08 09 10 12) 9 10define FATE_OPUS_TEST 11FATE_OPUS_$(1)-$(call FILTERDEMDECENCMUX, ARESAMPLE, MATROSKA, OPUS, PCM_S16LE, PCM_S16LE, PIPE_PROTOCOL) := $(addprefix fate-opus-,$(OPUS_$(1)_SAMPLES)) 12FATE_OPUS += $$(FATE_OPUS_$(1)-yes) 13endef 14 15$(foreach N, CELT HYBRID SILK OTHER, $(eval $(call FATE_OPUS_TEST,$(N)))) 16 17$(FATE_OPUS): CMD = ffmpeg -i $(TARGET_SAMPLES)/opus/$(@:fate-opus-%=%).mka -f s16le -af aresample - 18$(FATE_OPUS): REF = $(SAMPLES)/opus/$(@:fate-opus-%=%).dec 19$(FATE_OPUS_HYBRID-yes): REF = $(SAMPLES)/opus/$(@:fate-opus-%=%)_v2.dec 20 21$(FATE_OPUS): CMP = stddev 22$(FATE_OPUS): CMP_UNIT = s16 23$(FATE_OPUS): FUZZ = 3 24fate-opus-testvector01: CMP_TARGET = 0 25fate-opus-testvector02: CMP_TARGET = 191 26fate-opus-testvector03: CMP_TARGET = 139 27fate-opus-testvector04: CMP_TARGET = 119 28fate-opus-testvector05: CMP_TARGET = 108 29fate-opus-testvector06: CMP_TARGET = 106 30fate-opus-testvector07: CMP_TARGET = 0 31fate-opus-testvector08: CMP_TARGET = 6 32fate-opus-testvector09: CMP_TARGET = 0 33fate-opus-testvector10: CMP_TARGET = 38 34fate-opus-testvector11: CMP_TARGET = 0 35fate-opus-testvector12: CMP_TARGET = 160 36fate-opus-tron.6ch.tinypkts: CMP_SHIFT = 1440 37fate-opus-tron.6ch.tinypkts: CMP_TARGET = 0 38 39FATE_SAMPLES_FFMPEG += $(FATE_OPUS) 40fate-opus-celt: $(FATE_OPUS_CELT-yes) 41fate-opus-hybrid: $(FATE_OPUS_HYBRID-yes) 42fate-opus-silk: $(FATE_OPUS_SILK-yes) 43fate-opus: $(FATE_OPUS) 44