diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2012-04-19 20:46:37 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-04-19 21:23:52 +0200 |
commit | 2a976debc1de10c22c258583b543ab5b4bbe5974 (patch) | |
tree | a2b0a12017a42e8a37365ca84a6bf2a0179311e8 /tests | |
parent | 2ff935f4bb6173daf3361b2ac7b58c6e33994878 (diff) | |
parent | 2b98377935384ecd22c2cd26106b9e03a6c9f598 (diff) | |
download | ffmpeg-2a976debc1de10c22c258583b543ab5b4bbe5974.tar.gz |
Merge remote-tracking branch 'qatar/master'
* qatar/master:
dv: Initialize encoder tables during encoder init.
dv: Replace some magic numbers by the appropriate #define.
FATE: pass the decoded output format and audio source file to enc_dec_pcm
FATE: specify the input format when decoding in enc_dec_pcm()
x86inc: support AVX abstraction for 2-operand instructions
configure: detect PGI compiler and set suitable flags
avconv: check for an incompatible changing channel layout
avio: make AVIOContext.av_class pointer to const
nutdec: add malloc check and fix const to non-const conversion warnings
Conflicts:
ffmpeg.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'tests')
-rwxr-xr-x | tests/fate-run.sh | 16 | ||||
-rw-r--r-- | tests/fate/aac.mak | 4 | ||||
-rw-r--r-- | tests/fate/ac3.mak | 4 | ||||
-rw-r--r-- | tests/fate/audio.mak | 2 | ||||
-rw-r--r-- | tests/fate/wma.mak | 4 |
5 files changed, 19 insertions, 11 deletions
diff --git a/tests/fate-run.sh b/tests/fate-run.sh index e9863af01c..47649f4246 100755 --- a/tests/fate-run.sh +++ b/tests/fate-run.sh @@ -28,6 +28,11 @@ errfile="${outdir}/${test}.err" cmpfile="${outdir}/${test}.diff" repfile="${outdir}/${test}.rep" +target_path(){ + test ${1} = ${1#/} && p=${target_path}/ + echo ${p}${1} +} + # $1=value1, $2=value2, $3=threshold # prints 0 if absolute difference between value1 and value2 is <= threshold compare(){ @@ -86,12 +91,15 @@ pcm(){ enc_dec_pcm(){ out_fmt=$1 - pcm_fmt=$2 - shift 2 + dec_fmt=$2 + pcm_fmt=$3 + src_file=$(target_path $4) + shift 4 encfile="${outdir}/${test}.${out_fmt}" cleanfiles=$encfile - avconv -i $ref "$@" -f $out_fmt -y ${target_path}/${encfile} || return - avconv -i ${target_path}/${encfile} -c:a pcm_${pcm_fmt} -f wav - + encfile=$(target_path ${encfile}) + avconv -i $src_file "$@" -f $out_fmt -y ${encfile} || return + avconv -i ${encfile} -c:a pcm_${pcm_fmt} -f ${dec_fmt} - } regtest(){ diff --git a/tests/fate/aac.mak b/tests/fate/aac.mak index 9d107ced52..2a0db6a224 100644 --- a/tests/fate/aac.mak +++ b/tests/fate/aac.mak @@ -73,7 +73,7 @@ FATE_AAC += $(FATE_AAC_CT:%=fate-aac-ct-%) FATE_AAC_ENCODE += fate-aac-aref-encode fate-aac-aref-encode: $(AREF) -fate-aac-aref-encode: CMD = enc_dec_pcm adts s16le -strict -2 -c:a aac -b:a 512k +fate-aac-aref-encode: CMD = enc_dec_pcm adts wav s16le $(REF) -strict -2 -c:a aac -b:a 512k fate-aac-aref-encode: CMP = stddev fate-aac-aref-encode: REF = ./tests/data/acodec.ref.wav fate-aac-aref-encode: CMP_SHIFT = -4096 @@ -81,7 +81,7 @@ fate-aac-aref-encode: CMP_TARGET = 1862 fate-aac-aref-encode: SIZE_TOLERANCE = 2464 FATE_AAC_ENCODE += fate-aac-ln-encode -fate-aac-ln-encode: CMD = enc_dec_pcm adts s16le -strict -2 -c:a aac -b:a 512k +fate-aac-ln-encode: CMD = enc_dec_pcm adts wav s16le $(REF) -strict -2 -c:a aac -b:a 512k fate-aac-ln-encode: CMP = stddev fate-aac-ln-encode: REF = $(SAMPLES)/audio-reference/luckynight_2ch_44kHz_s16.wav fate-aac-ln-encode: CMP_SHIFT = -4096 diff --git a/tests/fate/ac3.mak b/tests/fate/ac3.mak index 2e851864c3..ca0704d08d 100644 --- a/tests/fate/ac3.mak +++ b/tests/fate/ac3.mak @@ -29,7 +29,7 @@ fate-eac3-4: CMP = oneoff fate-eac3-4: REF = $(SAMPLES)/eac3/serenity_english_5.1_1536_small.pcm FATE_AC3 += fate-ac3-encode -fate-ac3-encode: CMD = enc_dec_pcm ac3 s16le -c:a ac3 -b:a 128k +fate-ac3-encode: CMD = enc_dec_pcm ac3 wav s16le $(REF) -c:a ac3 -b:a 128k fate-ac3-encode: CMP = stddev fate-ac3-encode: REF = $(SAMPLES)/audio-reference/luckynight_2ch_44kHz_s16.wav fate-ac3-encode: CMP_SHIFT = -1024 @@ -37,7 +37,7 @@ fate-ac3-encode: CMP_TARGET = 399.62 fate-ac3-encode: SIZE_TOLERANCE = 488 FATE_AC3 += fate-eac3-encode -fate-eac3-encode: CMD = enc_dec_pcm eac3 s16le -c:a eac3 -b:a 128k +fate-eac3-encode: CMD = enc_dec_pcm eac3 wav s16le $(REF) -c:a eac3 -b:a 128k fate-eac3-encode: CMP = stddev fate-eac3-encode: REF = $(SAMPLES)/audio-reference/luckynight_2ch_44kHz_s16.wav fate-eac3-encode: CMP_SHIFT = -1024 diff --git a/tests/fate/audio.mak b/tests/fate/audio.mak index ae598bac7b..186ac6e4ba 100644 --- a/tests/fate/audio.mak +++ b/tests/fate/audio.mak @@ -30,7 +30,7 @@ fate-nellymoser: REF = $(SAMPLES)/nellymoser/nellymoser.pcm FATE_AUDIO += fate-nellymoser-aref-encode fate-nellymoser-aref-encode: $(AREF) -fate-nellymoser-aref-encode: CMD = enc_dec_pcm flv s16le -c:a nellymoser +fate-nellymoser-aref-encode: CMD = enc_dec_pcm flv wav s16le $(REF) -c:a nellymoser fate-nellymoser-aref-encode: CMP = stddev fate-nellymoser-aref-encode: REF = ./tests/data/acodec-16000-1.ref.wav fate-nellymoser-aref-encode: CMP_SHIFT = -1172 diff --git a/tests/fate/wma.mak b/tests/fate/wma.mak index 9143f8c0f3..6fd4b38ca7 100644 --- a/tests/fate/wma.mak +++ b/tests/fate/wma.mak @@ -38,7 +38,7 @@ FATE_TESTS += $(FATE_WMAVOICE) fate-wmavoice: $(FATE_WMAVOICE) FATE_WMA_ENCODE += fate-wmav1-encode -fate-wmav1-encode: CMD = enc_dec_pcm asf s16le -c:a wmav1 -b:a 128k +fate-wmav1-encode: CMD = enc_dec_pcm asf wav s16le $(REF) -c:a wmav1 -b:a 128k fate-wmav1-encode: CMP = stddev fate-wmav1-encode: REF = $(SAMPLES)/audio-reference/luckynight_2ch_44kHz_s16.wav fate-wmav1-encode: CMP_SHIFT = -8192 @@ -46,7 +46,7 @@ fate-wmav1-encode: CMP_TARGET = 291.06 fate-wmav1-encode: SIZE_TOLERANCE = 4632 FATE_WMA_ENCODE += fate-wmav2-encode -fate-wmav2-encode: CMD = enc_dec_pcm asf s16le -c:a wmav2 -b:a 128k +fate-wmav2-encode: CMD = enc_dec_pcm asf wav s16le $(REF) -c:a wmav2 -b:a 128k fate-wmav2-encode: CMP = stddev fate-wmav2-encode: REF = $(SAMPLES)/audio-reference/luckynight_2ch_44kHz_s16.wav fate-wmav2-encode: CMP_SHIFT = -8192 |