]> git.sesse.net Git - ffmpeg/blob - tests/fate/libswresample.mak
Merge commit '6d9ccee4519f41155c88655c77bfb1ef085797fd'
[ffmpeg] / tests / fate / libswresample.mak
1 CROSS_TEST = $(foreach I,$(1),                                        \
2                  $(foreach J,$(1),                                    \
3                      $(if $(filter-out $(I),$(J)),                    \
4                          $(eval $(call $(2),$(I),$(J),$(3),$(4),$(5))),    \
5                      )))
6
7
8 SAMPLERATES = 2626 8000 44100 48000 96000
9
10 SAMPLERATES_LITE = 8000 44100 48000
11
12 define ARESAMPLE
13 FATE_SWR_RESAMPLE += fate-swr-resample-$(3)-$(1)-$(2)
14 fate-swr-resample-$(3)-$(1)-$(2): tests/data/asynth-$(1)-1.wav
15 fate-swr-resample-$(3)-$(1)-$(2): CMD = ffmpeg -i $(TARGET_PATH)/tests/data/asynth-$(1)-1.wav -af atrim=end_sample=10240,aresample=$(2):internal_sample_fmt=$(3),aformat=$(3),aresample=$(1):internal_sample_fmt=$(3) -f wav -acodec pcm_s16le -
16
17 fate-swr-resample-$(3)-$(1)-$(2): CMP = stddev
18 fate-swr-resample-$(3)-$(1)-$(2): CMP_UNIT = $(5)
19 fate-swr-resample-$(3)-$(1)-$(2): FUZZ = 0.1
20 fate-swr-resample-$(3)-$(1)-$(2): REF = tests/data/asynth-$(1)-1.wav
21
22 #below list is generated by:
23 #you can use this if you need to update it!
24 #make -k  `make fate-list | grep swr` | egrep 'TEST|stddev' | tr '\n' '@' | sed 's#TEST *\([^@]*\)@stddev: *\([0-9.]*\)[^b@]*bytes: *\([0-9]*\) */ *\([0-9]*\)@#fate-\1: CMP_TARGET = \2@fate-\1: SIZE_TOLERANCE = \3 - \4@@#g' | tr '@' '\n'
25
26 fate-swr-resample-dblp-2626-44100: CMP_TARGET = 1393.01
27 fate-swr-resample-dblp-2626-44100: SIZE_TOLERANCE = 31512 - 20480
28
29 fate-swr-resample-dblp-2626-48000: CMP_TARGET = 1393.01
30 fate-swr-resample-dblp-2626-48000: SIZE_TOLERANCE = 31512 - 20480
31
32 fate-swr-resample-dblp-2626-8000: CMP_TARGET = 1393.90
33 fate-swr-resample-dblp-2626-8000: SIZE_TOLERANCE = 31512 - 20482
34
35 fate-swr-resample-dblp-2626-96000: CMP_TARGET = 1393.01
36 fate-swr-resample-dblp-2626-96000: SIZE_TOLERANCE = 31512 - 20480
37
38 fate-swr-resample-dblp-44100-2626: CMP_TARGET = 185.84
39 fate-swr-resample-dblp-44100-2626: SIZE_TOLERANCE = 529200 - 20490
40
41 fate-swr-resample-dblp-44100-48000: CMP_TARGET = 9.70
42 fate-swr-resample-dblp-44100-48000: SIZE_TOLERANCE = 529200 - 20482
43
44 fate-swr-resample-dblp-44100-8000: CMP_TARGET = 75.46
45 fate-swr-resample-dblp-44100-8000: SIZE_TOLERANCE = 529200 - 20486
46
47 fate-swr-resample-dblp-44100-96000: CMP_TARGET = 11.47
48 fate-swr-resample-dblp-44100-96000: SIZE_TOLERANCE = 529200 - 20482
49
50 fate-swr-resample-dblp-48000-2626: CMP_TARGET = 456.55
51 fate-swr-resample-dblp-48000-2626: SIZE_TOLERANCE = 576000 - 20510
52
53 fate-swr-resample-dblp-48000-44100: CMP_TARGET = 1.16
54 fate-swr-resample-dblp-48000-44100: SIZE_TOLERANCE = 576000 - 20480
55
56 fate-swr-resample-dblp-48000-8000: CMP_TARGET = 62.41
57 fate-swr-resample-dblp-48000-8000: SIZE_TOLERANCE = 576000 - 20484
58
59 fate-swr-resample-dblp-48000-96000: CMP_TARGET = 0.47
60 fate-swr-resample-dblp-48000-96000: SIZE_TOLERANCE = 576000 - 20480
61
62 fate-swr-resample-dblp-8000-2626: CMP_TARGET = 2506.01
63 fate-swr-resample-dblp-8000-2626: SIZE_TOLERANCE = 96000 - 20486
64
65 fate-swr-resample-dblp-8000-44100: CMP_TARGET = 15.09
66 fate-swr-resample-dblp-8000-44100: SIZE_TOLERANCE = 96000 - 20480
67
68 fate-swr-resample-dblp-8000-48000: CMP_TARGET = 14.68
69 fate-swr-resample-dblp-8000-48000: SIZE_TOLERANCE = 96000 - 20480
70
71 fate-swr-resample-dblp-8000-96000: CMP_TARGET = 13.82
72 fate-swr-resample-dblp-8000-96000: SIZE_TOLERANCE = 96000 - 20480
73
74 fate-swr-resample-dblp-96000-2626: CMP_TARGET = 675.14
75 fate-swr-resample-dblp-96000-2626: SIZE_TOLERANCE = 1152000 - 20474
76
77 fate-swr-resample-dblp-96000-44100: CMP_TARGET = 1.58
78 fate-swr-resample-dblp-96000-44100: SIZE_TOLERANCE = 1152000 - 20480
79
80 fate-swr-resample-dblp-96000-48000: CMP_TARGET = 1.04
81 fate-swr-resample-dblp-96000-48000: SIZE_TOLERANCE = 1152000 - 20480
82
83 fate-swr-resample-dblp-96000-8000: CMP_TARGET = 58.60
84 fate-swr-resample-dblp-96000-8000: SIZE_TOLERANCE = 1152000 - 20496
85
86 fate-swr-resample-fltp-2626-44100: CMP_TARGET = 1393.01
87 fate-swr-resample-fltp-2626-44100: SIZE_TOLERANCE = 31512 - 20480
88
89 fate-swr-resample-fltp-2626-48000: CMP_TARGET = 1393.01
90 fate-swr-resample-fltp-2626-48000: SIZE_TOLERANCE = 31512 - 20480
91
92 fate-swr-resample-fltp-2626-8000: CMP_TARGET = 1393.90
93 fate-swr-resample-fltp-2626-8000: SIZE_TOLERANCE = 31512 - 20482
94
95 fate-swr-resample-fltp-2626-96000: CMP_TARGET = 1393.01
96 fate-swr-resample-fltp-2626-96000: SIZE_TOLERANCE = 31512 - 20480
97
98 fate-swr-resample-fltp-44100-2626: CMP_TARGET = 185.84
99 fate-swr-resample-fltp-44100-2626: SIZE_TOLERANCE = 529200 - 20490
100
101 fate-swr-resample-fltp-44100-48000: CMP_TARGET = 9.70
102 fate-swr-resample-fltp-44100-48000: SIZE_TOLERANCE = 529200 - 20482
103
104 fate-swr-resample-fltp-44100-8000: CMP_TARGET = 75.46
105 fate-swr-resample-fltp-44100-8000: SIZE_TOLERANCE = 529200 - 20486
106
107 fate-swr-resample-fltp-44100-96000: CMP_TARGET = 11.47
108 fate-swr-resample-fltp-44100-96000: SIZE_TOLERANCE = 529200 - 20482
109
110 fate-swr-resample-fltp-48000-2626: CMP_TARGET = 456.55
111 fate-swr-resample-fltp-48000-2626: SIZE_TOLERANCE = 576000 - 20510
112
113 fate-swr-resample-fltp-48000-44100: CMP_TARGET = 1.16
114 fate-swr-resample-fltp-48000-44100: SIZE_TOLERANCE = 576000 - 20480
115
116 fate-swr-resample-fltp-48000-8000: CMP_TARGET = 62.41
117 fate-swr-resample-fltp-48000-8000: SIZE_TOLERANCE = 576000 - 20484
118
119 fate-swr-resample-fltp-48000-96000: CMP_TARGET = 0.47
120 fate-swr-resample-fltp-48000-96000: SIZE_TOLERANCE = 576000 - 20480
121
122 fate-swr-resample-fltp-8000-2626: CMP_TARGET = 2506.01
123 fate-swr-resample-fltp-8000-2626: SIZE_TOLERANCE = 96000 - 20486
124
125 fate-swr-resample-fltp-8000-44100: CMP_TARGET = 15.09
126 fate-swr-resample-fltp-8000-44100: SIZE_TOLERANCE = 96000 - 20480
127
128 fate-swr-resample-fltp-8000-48000: CMP_TARGET = 14.68
129 fate-swr-resample-fltp-8000-48000: SIZE_TOLERANCE = 96000 - 20480
130
131 fate-swr-resample-fltp-8000-96000: CMP_TARGET = 13.82
132 fate-swr-resample-fltp-8000-96000: SIZE_TOLERANCE = 96000 - 20480
133
134 fate-swr-resample-fltp-96000-2626: CMP_TARGET = 675.14
135 fate-swr-resample-fltp-96000-2626: SIZE_TOLERANCE = 1152000 - 20474
136
137 fate-swr-resample-fltp-96000-44100: CMP_TARGET = 1.58
138 fate-swr-resample-fltp-96000-44100: SIZE_TOLERANCE = 1152000 - 20480
139
140 fate-swr-resample-fltp-96000-48000: CMP_TARGET = 1.04
141 fate-swr-resample-fltp-96000-48000: SIZE_TOLERANCE = 1152000 - 20480
142
143 fate-swr-resample-fltp-96000-8000: CMP_TARGET = 58.60
144 fate-swr-resample-fltp-96000-8000: SIZE_TOLERANCE = 1152000 - 20496
145
146 fate-swr-resample-s16p-2626-44100: CMP_TARGET = 1393.01
147 fate-swr-resample-s16p-2626-44100: SIZE_TOLERANCE = 31512 - 20480
148
149 fate-swr-resample-s16p-2626-48000: CMP_TARGET = 1392.99
150 fate-swr-resample-s16p-2626-48000: SIZE_TOLERANCE = 31512 - 20480
151
152 fate-swr-resample-s16p-2626-8000: CMP_TARGET = 1393.90
153 fate-swr-resample-s16p-2626-8000: SIZE_TOLERANCE = 31512 - 20482
154
155 fate-swr-resample-s16p-2626-96000: CMP_TARGET = 1393.08
156 fate-swr-resample-s16p-2626-96000: SIZE_TOLERANCE = 31512 - 20480
157
158 fate-swr-resample-s16p-44100-2626: CMP_TARGET = 185.84
159 fate-swr-resample-s16p-44100-2626: SIZE_TOLERANCE = 529200 - 20490
160
161 fate-swr-resample-s16p-44100-48000: CMP_TARGET = 9.71
162 fate-swr-resample-s16p-44100-48000: SIZE_TOLERANCE = 529200 - 20482
163
164 fate-swr-resample-s16p-44100-8000: CMP_TARGET = 75.46
165 fate-swr-resample-s16p-44100-8000: SIZE_TOLERANCE = 529200 - 20486
166
167 fate-swr-resample-s16p-44100-96000: CMP_TARGET = 11.48
168 fate-swr-resample-s16p-44100-96000: SIZE_TOLERANCE = 529200 - 20482
169
170 fate-swr-resample-s16p-48000-2626: CMP_TARGET = 456.55
171 fate-swr-resample-s16p-48000-2626: SIZE_TOLERANCE = 576000 - 20510
172
173 fate-swr-resample-s16p-48000-44100: CMP_TARGET = 1.22
174 fate-swr-resample-s16p-48000-44100: SIZE_TOLERANCE = 576000 - 20480
175
176 fate-swr-resample-s16p-48000-8000: CMP_TARGET = 62.41
177 fate-swr-resample-s16p-48000-8000: SIZE_TOLERANCE = 576000 - 20484
178
179 fate-swr-resample-s16p-48000-96000: CMP_TARGET = 0.50
180 fate-swr-resample-s16p-48000-96000: SIZE_TOLERANCE = 576000 - 20480
181
182 fate-swr-resample-s16p-8000-2626: CMP_TARGET = 2506.02
183 fate-swr-resample-s16p-8000-2626: SIZE_TOLERANCE = 96000 - 20486
184
185 fate-swr-resample-s16p-8000-44100: CMP_TARGET = 15.12
186 fate-swr-resample-s16p-8000-44100: SIZE_TOLERANCE = 96000 - 20480
187
188 fate-swr-resample-s16p-8000-48000: CMP_TARGET = 14.69
189 fate-swr-resample-s16p-8000-48000: SIZE_TOLERANCE = 96000 - 20480
190
191 fate-swr-resample-s16p-8000-96000: CMP_TARGET = 13.83
192 fate-swr-resample-s16p-8000-96000: SIZE_TOLERANCE = 96000 - 20480
193
194 fate-swr-resample-s16p-96000-2626: CMP_TARGET = 675.14
195 fate-swr-resample-s16p-96000-2626: SIZE_TOLERANCE = 1152000 - 20474
196
197 fate-swr-resample-s16p-96000-44100: CMP_TARGET = 1.62
198 fate-swr-resample-s16p-96000-44100: SIZE_TOLERANCE = 1152000 - 20480
199
200 fate-swr-resample-s16p-96000-48000: CMP_TARGET = 1.03
201 fate-swr-resample-s16p-96000-48000: SIZE_TOLERANCE = 1152000 - 20480
202
203 fate-swr-resample-s16p-96000-8000: CMP_TARGET = 58.60
204 fate-swr-resample-s16p-96000-8000: SIZE_TOLERANCE = 1152000 - 20496
205
206 fate-swr-resample-s32p-2626-44100: CMP_TARGET = 1393.01
207 fate-swr-resample-s32p-2626-44100: SIZE_TOLERANCE = 31512 - 20480
208
209 fate-swr-resample-s32p-2626-48000: CMP_TARGET = 1393.01
210 fate-swr-resample-s32p-2626-48000: SIZE_TOLERANCE = 31512 - 20480
211
212 fate-swr-resample-s32p-2626-8000: CMP_TARGET = 1393.90
213 fate-swr-resample-s32p-2626-8000: SIZE_TOLERANCE = 31512 - 20482
214
215 fate-swr-resample-s32p-2626-96000: CMP_TARGET = 1393.01
216 fate-swr-resample-s32p-2626-96000: SIZE_TOLERANCE = 31512 - 20480
217
218 fate-swr-resample-s32p-44100-2626: CMP_TARGET = 185.84
219 fate-swr-resample-s32p-44100-2626: SIZE_TOLERANCE = 529200 - 20490
220
221 fate-swr-resample-s32p-44100-48000: CMP_TARGET = 9.70
222 fate-swr-resample-s32p-44100-48000: SIZE_TOLERANCE = 529200 - 20482
223
224 fate-swr-resample-s32p-44100-8000: CMP_TARGET = 75.46
225 fate-swr-resample-s32p-44100-8000: SIZE_TOLERANCE = 529200 - 20486
226
227 fate-swr-resample-s32p-44100-96000: CMP_TARGET = 11.47
228 fate-swr-resample-s32p-44100-96000: SIZE_TOLERANCE = 529200 - 20482
229
230 fate-swr-resample-s32p-48000-2626: CMP_TARGET = 456.55
231 fate-swr-resample-s32p-48000-2626: SIZE_TOLERANCE = 576000 - 20510
232
233 fate-swr-resample-s32p-48000-44100: CMP_TARGET = 1.16
234 fate-swr-resample-s32p-48000-44100: SIZE_TOLERANCE = 576000 - 20480
235
236 fate-swr-resample-s32p-48000-8000: CMP_TARGET = 62.41
237 fate-swr-resample-s32p-48000-8000: SIZE_TOLERANCE = 576000 - 20484
238
239 fate-swr-resample-s32p-48000-96000: CMP_TARGET = 0.47
240 fate-swr-resample-s32p-48000-96000: SIZE_TOLERANCE = 576000 - 20480
241
242 fate-swr-resample-s32p-8000-2626: CMP_TARGET = 2506.01
243 fate-swr-resample-s32p-8000-2626: SIZE_TOLERANCE = 96000 - 20486
244
245 fate-swr-resample-s32p-8000-44100: CMP_TARGET = 15.09
246 fate-swr-resample-s32p-8000-44100: SIZE_TOLERANCE = 96000 - 20480
247
248 fate-swr-resample-s32p-8000-48000: CMP_TARGET = 14.68
249 fate-swr-resample-s32p-8000-48000: SIZE_TOLERANCE = 96000 - 20480
250
251 fate-swr-resample-s32p-8000-96000: CMP_TARGET = 13.82
252 fate-swr-resample-s32p-8000-96000: SIZE_TOLERANCE = 96000 - 20480
253
254 fate-swr-resample-s32p-96000-2626: CMP_TARGET = 675.14
255 fate-swr-resample-s32p-96000-2626: SIZE_TOLERANCE = 1152000 - 20474
256
257 fate-swr-resample-s32p-96000-44100: CMP_TARGET = 1.58
258 fate-swr-resample-s32p-96000-44100: SIZE_TOLERANCE = 1152000 - 20480
259
260 fate-swr-resample-s32p-96000-48000: CMP_TARGET = 1.04
261 fate-swr-resample-s32p-96000-48000: SIZE_TOLERANCE = 1152000 - 20480
262
263 fate-swr-resample-s32p-96000-8000: CMP_TARGET = 58.60
264 fate-swr-resample-s32p-96000-8000: SIZE_TOLERANCE = 1152000 - 20496
265 endef
266
267 define ARESAMPLE_LIN
268 FATE_SWR_RESAMPLE += fate-swr-resample_lin-$(3)-$(1)-$(2)
269 fate-swr-resample_lin-$(3)-$(1)-$(2): tests/data/asynth-$(1)-1.wav
270 fate-swr-resample_lin-$(3)-$(1)-$(2): CMD = ffmpeg -i $(TARGET_PATH)/tests/data/asynth-$(1)-1.wav -af atrim=end_sample=10240,aresample=$(2):linear_interp=1:internal_sample_fmt=$(3),aformat=$(3),aresample=$(1):internal_sample_fmt=$(3) -f wav -acodec pcm_s16le -
271
272 fate-swr-resample_lin-$(3)-$(1)-$(2): CMP = stddev
273 fate-swr-resample_lin-$(3)-$(1)-$(2): CMP_UNIT = $(5)
274 fate-swr-resample_lin-$(3)-$(1)-$(2): FUZZ = 0.1
275 fate-swr-resample_lin-$(3)-$(1)-$(2): REF = tests/data/asynth-$(1)-1.wav
276
277 fate-swr-resample_lin-s16p-8000-44100: CMP_TARGET = 14.63
278 fate-swr-resample_lin-s16p-8000-44100: SIZE_TOLERANCE = 96000 - 20480
279
280 fate-swr-resample_lin-s16p-8000-48000: CMP_TARGET = 14.53
281 fate-swr-resample_lin-s16p-8000-48000: SIZE_TOLERANCE = 96000 - 20480
282
283 fate-swr-resample_lin-s16p-44100-8000: CMP_TARGET = 75.45
284 fate-swr-resample_lin-s16p-44100-8000: SIZE_TOLERANCE = 529200 - 20486
285
286 fate-swr-resample_lin-s16p-44100-48000: CMP_TARGET = 9.68
287 fate-swr-resample_lin-s16p-44100-48000: SIZE_TOLERANCE = 529200 - 20482
288
289 fate-swr-resample_lin-s16p-48000-8000: CMP_TARGET = 62.41
290 fate-swr-resample_lin-s16p-48000-8000: SIZE_TOLERANCE = 576000 - 20484
291
292 fate-swr-resample_lin-s16p-48000-44100: CMP_TARGET = 0.86
293 fate-swr-resample_lin-s16p-48000-44100: SIZE_TOLERANCE = 576000 - 20480
294
295 fate-swr-resample_lin-fltp-8000-44100: CMP_TARGET = 14.61
296 fate-swr-resample_lin-fltp-8000-44100: SIZE_TOLERANCE = 96000 - 20480
297
298 fate-swr-resample_lin-fltp-8000-48000: CMP_TARGET = 14.50
299 fate-swr-resample_lin-fltp-8000-48000: SIZE_TOLERANCE = 96000 - 20480
300
301 fate-swr-resample_lin-fltp-44100-8000: CMP_TARGET = 75.45
302 fate-swr-resample_lin-fltp-44100-8000: SIZE_TOLERANCE = 529200 - 20486
303
304 fate-swr-resample_lin-fltp-44100-48000: CMP_TARGET = 9.67
305 fate-swr-resample_lin-fltp-44100-48000: SIZE_TOLERANCE = 529200 - 20482
306
307 fate-swr-resample_lin-fltp-48000-8000: CMP_TARGET = 62.41
308 fate-swr-resample_lin-fltp-48000-8000: SIZE_TOLERANCE = 576000 - 20484
309
310 fate-swr-resample_lin-fltp-48000-44100: CMP_TARGET = 0.79
311 fate-swr-resample_lin-fltp-48000-44100: SIZE_TOLERANCE = 576000 - 20480
312 endef
313
314 $(call CROSS_TEST,$(SAMPLERATES),ARESAMPLE,s16p,s16le,s16)
315 $(call CROSS_TEST,$(SAMPLERATES),ARESAMPLE,s32p,s32le,s16)
316 $(call CROSS_TEST,$(SAMPLERATES),ARESAMPLE,fltp,f32le,s16)
317 $(call CROSS_TEST,$(SAMPLERATES),ARESAMPLE,dblp,f64le,s16)
318
319 $(call CROSS_TEST,$(SAMPLERATES_LITE),ARESAMPLE_LIN,s16p,s16le,s16)
320 $(call CROSS_TEST,$(SAMPLERATES_LITE),ARESAMPLE_LIN,fltp,f32le,s16)
321
322 FATE_SWR_RESAMPLE-$(call FILTERDEMDECENCMUX, ARESAMPLE, WAV, PCM_S16LE, PCM_S16LE, WAV) += $(FATE_SWR_RESAMPLE)
323 fate-swr-resample: $(FATE_SWR_RESAMPLE-yes)
324 FATE_SWR += $(FATE_SWR_RESAMPLE-yes)
325
326 FATE_FFMPEG += $(FATE_SWR)
327 fate-swr: $(FATE_SWR)