annotate tests/faterun.sh @ 34809:ea97bcb28df1

Allow direct rendering for non-reference frames in H.264. This might work for other codecs that currently have DR disabled, but H.264 is the only one tested so far.
author reimar
date Mon, 14 May 2012 18:11:24 +0000
parents 8d19b1ec5ea5
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
34241
f6cce8c4ea66 Add beginnings of a test framework.
reimar
parents:
diff changeset
1 #!/bin/sh
34440
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
2 if [ -z "$FATE_SAMPLES" ] ; then
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
3 echo "FATE_SAMPLES is not set!"
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
4 exit 1
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
5 fi
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
6
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
7 sample="$1"
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
8 md5out="tests/res/$sample.md5"
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
9 ref_file="tests/ref/$sample.md5"
34449
8d19b1ec5ea5 Force "simple" IDCT to avoid different results on different PCs.
reimar
parents: 34445
diff changeset
10 options="-noconfig all -lavdopts threads=4:bitexact:idct=2 -really-quiet -noconsolecontrols -nosound -benchmark"
34445
1b8e44d85ef7 Fix testing of H.264 conformance tests.
reimar
parents: 34440
diff changeset
11 if [ -z ${sample##h264-conformance/*} ] ; then
1b8e44d85ef7 Fix testing of H.264 conformance tests.
reimar
parents: 34440
diff changeset
12 # these files generally only work when a fps is given explicitly
1b8e44d85ef7 Fix testing of H.264 conformance tests.
reimar
parents: 34440
diff changeset
13 options="$options -fps 25"
1b8e44d85ef7 Fix testing of H.264 conformance tests.
reimar
parents: 34440
diff changeset
14 fi
34440
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
15 echo "testing $sample"
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
16
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
17 # create necessary files and run
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
18 mkdir -p $(dirname "$md5out")
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
19 touch "$md5out"
34445
1b8e44d85ef7 Fix testing of H.264 conformance tests.
reimar
parents: 34440
diff changeset
20 ./mplayer $options -vo md5sum:outfile="$md5out" "$FATE_SAMPLES/$sample"
34440
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
21
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
22 # check result
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
23 if ! [ -e "$ref_file" ] ; then
34418
6faf474f9ce3 build: Merge tests/Makefile into top-level Makefile and test non-recursively.
diego
parents: 34241
diff changeset
24 touch tests/ref/empty.md5
6faf474f9ce3 build: Merge tests/Makefile into top-level Makefile and test non-recursively.
diego
parents: 34241
diff changeset
25 ref_file=tests/ref/empty.md5
34241
f6cce8c4ea66 Add beginnings of a test framework.
reimar
parents:
diff changeset
26 fi
34440
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
27 if ! diff -uw "$ref_file" "$md5out" ; then
57d1ace7fb63 Clean up faterun.sh.
reimar
parents: 34418
diff changeset
28 mv "$md5out" "$md5out.bad"
34241
f6cce8c4ea66 Add beginnings of a test framework.
reimar
parents:
diff changeset
29 exit 1
f6cce8c4ea66 Add beginnings of a test framework.
reimar
parents:
diff changeset
30 fi