Commit dc94ff43 authored by Stefan Westerfeld's avatar Stefan Westerfeld

Use mp3/ogg file directly in error test script.

Signed-off-by: Stefan Westerfeld's avatarStefan Westerfeld <stefan@space.twc.de>
parent 5f718b61
...@@ -58,8 +58,7 @@ do ...@@ -58,8 +58,7 @@ do
exit 1 exit 1
fi fi
lame -b $2 ${AWM_FILE}.wav ${AWM_FILE}.mp3 --quiet lame -b $2 ${AWM_FILE}.wav ${AWM_FILE}.mp3 --quiet
rm ${AWM_FILE}.wav OUT_FILE=${AWM_FILE}.mp3
ffmpeg -i ${AWM_FILE}.mp3 ${AWM_FILE}.wav -v quiet -nostdin
elif [ "x$TRANSFORM" == "xdouble-mp3" ]; then elif [ "x$TRANSFORM" == "xdouble-mp3" ]; then
if [ "x$2" == "x" ]; then if [ "x$2" == "x" ]; then
echo "need mp3 bitrate" >&2 echo "need mp3 bitrate" >&2
...@@ -72,23 +71,22 @@ do ...@@ -72,23 +71,22 @@ do
# second mp3 step # second mp3 step
lame -b $2 ${AWM_FILE}.wav ${AWM_FILE}.mp3 --quiet lame -b $2 ${AWM_FILE}.wav ${AWM_FILE}.mp3 --quiet
rm ${AWM_FILE}.wav OUT_FILE=${AWM_FILE}.mp3
ffmpeg -i ${AWM_FILE}.mp3 ${AWM_FILE}.wav -v quiet -nostdin
elif [ "x$TRANSFORM" == "xogg" ]; then elif [ "x$TRANSFORM" == "xogg" ]; then
if [ "x$2" == "x" ]; then if [ "x$2" == "x" ]; then
echo "need ogg bitrate" >&2 echo "need ogg bitrate" >&2
exit 1 exit 1
fi fi
oggenc -b $2 ${AWM_FILE}.wav -o ${AWM_FILE}.ogg --quiet oggenc -b $2 ${AWM_FILE}.wav -o ${AWM_FILE}.ogg --quiet
oggdec ${AWM_FILE}.ogg -o ${AWM_FILE}.wav --quiet OUT_FILE=${AWM_FILE}.ogg
elif [ "x$TRANSFORM" == "x" ]; then elif [ "x$TRANSFORM" == "x" ]; then
: OUT_FILE=${AWM_FILE}.wav
else else
echo "unknown transform $TRANSFORM" >&2 echo "unknown transform $TRANSFORM" >&2
exit 1 exit 1
fi fi
# blind decoding # blind decoding
audiowmark cmp ${AWM_FILE}.wav $PATTERN $AWM_PARAMS --test-key $SEED $TEST_CUT_ARGS audiowmark cmp $OUT_FILE $PATTERN $AWM_PARAMS --test-key $SEED $TEST_CUT_ARGS
# decoding with original # decoding with original
# audiowmark cmp-delta "$i" t.wav $PATTERN $AWM_PARAMS --test-key $SEED # audiowmark cmp-delta "$i" t.wav $PATTERN $AWM_PARAMS --test-key $SEED
done done
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment