]> git.phdru.name Git - audio-cdr-video.git/blobdiff - video/transcoding/tc_encode_comments_a1
Move outdated scripts to separate subdirectories
[audio-cdr-video.git] / video / transcoding / tc_encode_comments_a1
diff --git a/video/transcoding/tc_encode_comments_a1 b/video/transcoding/tc_encode_comments_a1
new file mode 100755 (executable)
index 0000000..fdb6c10
--- /dev/null
@@ -0,0 +1,24 @@
+#! /bin/sh
+
+if [ -z "$8" ]; then
+   echo "Usage: $0 input title aid1 bitrate1 scale1 aid2 bitrate2 scale2 [transcode options]" >&2
+   exit 1
+fi
+
+input="$1"
+title="$2"
+aid1="$3"
+bitrate1="$4"
+scale1="$5"
+aid2="$6"
+bitrate2="$7"
+scale2="$8"
+shift 8
+
+echo "INAM $title" | iconv -f koi8-r -t utf-8 >avi_comments.txt
+echo "ICMT Codec: FFmpeg (DivX5)" >>avi_comments.txt
+
+abitrate="$bitrate1" ascale="$scale1" tc_encode "$input" -a "$aid1" "$@" &&
+tc_extract_a1_comments "$input" "$aid2" -b "$bitrate2" -s "$scale2" &&
+mv output2.avi "$title".avi &&
+exec rm avi_comments.txt divx4.log a"$aid2".mp3 output.avi