Added last bits of replaygain patch
Changed lenth of 3,4 to 3,6 since we will be supporting both ogg and vorbis
git-svn-id: http://abcde.googlecode.com/svn/trunk@122
a0fa61bc-5347-0410-a1a9-
7f54aa4e1825
for OUTPUT in $( echo $OUTPUTTYPE | tr , \ )
# THE OUTPUT NEEDS TO BE CORRECTED WITH THE CONTAINER?
do
for OUTPUT in $( echo $OUTPUTTYPE | tr , \ )
# THE OUTPUT NEEDS TO BE CORRECTED WITH THE CONTAINER?
do
+ case $OUTPUT in
+ vorbis|ogg)
+ OUTPUT=$OGGOUTPUTCONTAINER
+ ;;
+ flac)
+ OUTPUT=$FLACOUTPUTCONTAINER
+ ;;
+ esac
OUTPUTFILES=""
for UTRACKNUM in $TRACKQUEUE
do
OUTPUTFILES=""
for UTRACKNUM in $TRACKQUEUE
do
OUTPUTFILES="$OUTPUTDIR/$OUTPUTFILE.$OUTPUT $OUTPUTFILES"
done
case "$OUTPUT" in
OUTPUTFILES="$OUTPUTDIR/$OUTPUTFILE.$OUTPUT $OUTPUTFILES"
done
case "$OUTPUT" in
+ flac)
+ run_command replaygain-flac $METAFLAC --add-replay-gain $OUTPUTFILES
+ ;;
+ vorbis|ogg)
+ run_command replaygain-vorbis $VORBISGAIN --album $OUTPUTFILES
+ ;;
- if [ "$RETURN" = "0" ]; then
- run_command replaygain-$OUTPUT true
- else
- runcommand replaygain-$OUTPUT false
- fi
- if checkerrors replaygain-.{3,4}; then
+ if checkerrors replaygain-.{3,6}; then
run_command replaygain false
else
run_command replaygain true
run_command replaygain false
else
run_command replaygain true
- if checkerrors "tagtrack-(.{3,4})-$1"; then
+ if checkerrors "tagtrack-(.{3,6})-$1"; then
run_command tagtrack-$1 false
else
run_command tagtrack-$1 true
run_command tagtrack-$1 false
else
run_command tagtrack-$1 true
esac
done
# Only remove .wav if the encoding succeeded
esac
done
# Only remove .wav if the encoding succeeded
- if checkerrors "encodetrack-(.{3,4})-$1"; then
+ if checkerrors "encodetrack-(.{3,6})-$1"; then
run_command encodetrack-$1 false
else
run_command encodetrack-$1 true
run_command encodetrack-$1 false
else
run_command encodetrack-$1 true