implement MP3 encoding
This commit is contained in:
parent
3e1b6bc1c0
commit
a59a9915ce
26
atom
26
atom
@ -1068,14 +1068,24 @@ getDestFile() {
|
|||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
transcodeFile() {
|
encodeFile::mp3() {
|
||||||
#sox -> wav
|
lameopts="--quiet -v --abr ${destinationquality[$destination]}"
|
||||||
for format in $targets["format"]
|
[ -n "$album" ] && lameopts+=" --tl \"$album\""
|
||||||
do
|
[ -n "$artist" ] && lameopts+=" --ta \"$artist\""
|
||||||
#encodeFile::$format
|
[ -n "$genre" ] && lameopts+=" --tg \"$genre\""
|
||||||
:
|
[ -n "$title" ] && lameopts+=" --tt \"$title\""
|
||||||
done
|
[ -n "$track" ] && lameopts+=" --tn \"$track\""
|
||||||
#signal and of encoding to parent
|
[ -n "$year" ] && lameopts+=" --ty \"$year\""
|
||||||
|
encodetaskid=$(
|
||||||
|
Insert tasks <<-EOInsert
|
||||||
|
key ${fileid}lame$destination
|
||||||
|
requires ${soxtaskid:-$decodetaskid}
|
||||||
|
command_line lame $lameopts "$tempdir/$tmpfile.wav" "$destdir/$destfile.mp3"
|
||||||
|
source_file $fileid
|
||||||
|
status 0
|
||||||
|
EOInsert
|
||||||
|
)
|
||||||
|
progressSpin
|
||||||
}
|
}
|
||||||
|
|
||||||
checkFinished() {
|
checkFinished() {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user