#!/bin/sh
vlc="/usr/bin/vlc"
if [ ! -e "$vlc" ]; then
echo "Command '$vlc' does not exist"
exit 1
fi
for file in "$@"; do
echo "=> Transcoding '$file'... "
dst=`dirname "$file"`
temp=$dst/`basename "$file" | sed 's@\.[a-z][a-z][a-z]$@@'`.temp
$vlc -I dummy -q "$file" \
--sout "#transcode{acodec=s16l,samplerate=44100}:standard{mux=wav,dst=\"$temp\",access=file}" \
vlc://quit
mv "$temp" "$file"
done
The scripts runs on GNU/Linux (Ubuntu in my case) and the package vlc (or vlc-nox) is a prerequisite for running it. You should create a script called "convert.sh" with the previous content, and make it executable with:
chown u+x convert.sh
You can then run the batch convert with:
./convert.sh my_wav_folder/*.wav
All files in the target folder will be replaced by the script with files of the right format, so then you should be able to load them on the MPC1000.
Nessun commento:
Posta un commento