aboutsummaryrefslogtreecommitdiffstats
path: root/tests/fate-run.sh
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-03-18 23:12:35 +0100
committerMichael Niedermayer <michaelni@gmx.at>2012-03-18 23:39:42 +0100
commitbae053fca4cf662a223821f1e1fe43236e1cf2ff (patch)
tree0a3c448cd41c5beaaae48a6a61430c9d6277bb7f /tests/fate-run.sh
parent7f4c5ab8a1cc5e7be8ce70edfcaa6f926791376b (diff)
parenta56fba502e9087c204b7d6cdc8e12d623f77d66d (diff)
downloadffmpeg-bae053fca4cf662a223821f1e1fe43236e1cf2ff.tar.gz
Merge remote-tracking branch 'qatar/master'
* qatar/master: fate: make compare() function compatible with POSIX bc Update Janne's email address. APIchanges: Replace Subversion revision numbers by Git hashes. bytestream: Eliminate one level of pointless macro indirection. xwd: convert to bytestream2. vqavideo: port to bytestream2 API Read preset files with suffix .avpreset prores: allow user to set fixed quantiser lavf: remove some disabled code. lavf: only set average frame rate for video. lavf: remove a pointless check. avcodec: add XBM encoder Conflicts: Changelog cmdutils.c cmdutils.h doc/APIchanges libavcodec/Makefile libavcodec/avcodec.h libavcodec/version.h libavcodec/vqavideo.c libavformat/img2enc.c libavformat/utils.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'tests/fate-run.sh')
-rwxr-xr-xtests/fate-run.sh3
1 files changed, 1 insertions, 2 deletions
diff --git a/tests/fate-run.sh b/tests/fate-run.sh
index fabf36e9d2..e9863af01c 100755
--- a/tests/fate-run.sh
+++ b/tests/fate-run.sh
@@ -31,8 +31,7 @@ repfile="${outdir}/${test}.rep"
# $1=value1, $2=value2, $3=threshold
# prints 0 if absolute difference between value1 and value2 is <= threshold
compare(){
- v=$(echo "scale=2; if ($1 >= $2) { $1 - $2 } else { $2 - $1 }" | bc)
- echo "if ($v <= $3) { 0 } else { 1 }" | bc
+ echo "scale=2; v = $1 - $2; if (v < 0) v = -v; if (v > $3) r = 1; r" | bc
}
do_tiny_psnr(){