MagicPodcast/bash_commands/split_channels_to_two_ways.sh

15 lines
327 B
Bash
Raw Normal View History

#!/bin/bash
tmp_dir=$1
2021-01-20 12:58:08 +01:00
number_of_files=$2
file_1=$3
file_2=$4
if [ $number_of_files != "2" ]
then
ffmpeg -i $file_1 -map_channel 0.0.0 $tmp_dir/left.wav -map_channel 0.0.1 $tmp_dir/right.wav -y
2021-01-20 12:58:08 +01:00
else
ffmpeg -i $file_1 -map_channel 0.0.0 $tmp_dir/left.wav -y
ffmpeg -i $file_2 -map_channel 0.0.1 $tmp_dir/right.wav -y
2021-01-20 12:58:08 +01:00
fi