summaryrefslogtreecommitdiffstats
path: root/tools/audio_split
diff options
context:
space:
mode:
authorOle Kristian Lien <ole.k.lien@gmail.com>2009-12-10 06:22:08 +0000
committerOle Kristian Lien <ole.k.lien@gmail.com>2009-12-10 06:22:08 +0000
commiteb0f5ffae76f0834076793b5755e1e7c12705e88 (patch)
treec4f2b9aa79e14e9bb4cab1fddab4828811571741 /tools/audio_split
parentf109c2fc7c7ed195003d9deb20710b49d86f12c8 (diff)
Diverse fikser :)
Diffstat (limited to 'tools/audio_split')
-rwxr-xr-xtools/audio_split18
1 files changed, 18 insertions, 0 deletions
diff --git a/tools/audio_split b/tools/audio_split
new file mode 100755
index 0000000..a5e5525
--- /dev/null
+++ b/tools/audio_split
@@ -0,0 +1,18 @@
+#!/bin/bash
+#
+# Date: 2009-12-10
+# Author: Ole Kristian Lien
+# License: GNU General Public License
+#
+# Splits a audio-file to a left- and right-file.
+
+EXT=`echo "$1"|awk -F . '{print $NF}'`
+NAME=`basename $1 .$EXT`
+
+if [ -z "$1" ]; then
+ echo "Usage: $0 <audio-file>"
+ exit 1
+fi
+
+sox $1 -c 1 $NAME-left.$EXT mixer -l 2> /dev/null
+sox $1 -c 1 $NAME-right.$EXT mixer -r 2> /dev/null