]> git.phdru.name Git - audio-cdr-video.git/blob - video/m_encode_comments_a1
Initail import
[audio-cdr-video.git] / video / m_encode_comments_a1
1 #! /bin/sh
2
3 if [ -z "$7" ]; then
4    echo "Usage: $0 title aid1 bitrate1 scale1 aid2 bitrate2 scale2 [menoder options]" >&2
5    exit 1
6 fi
7
8 title="$1"
9 aid1="$2"
10 bitrate1="$3"
11 scale1="$4"
12 aid2="$5"
13 bitrate2="$6"
14 scale2="$7"
15 shift 7
16
17 echo "INAM $title" | iconv -f koi8-r -t utf-8 >avi_comments.txt
18 echo "ICMT Codec: FFmpeg (DivX5)" >>avi_comments.txt
19
20 aid="$aid1" abitrate="$bitrate1" ascale="$scale1" m_encode "$@" &&
21 m_extract_a1_comments "$aid2" -lameopts cbr:br=$bitrate2:q=0 -af volume="$scale2" "$@" &&
22 mv output2.avi "$title".avi &&
23 exec rm avi_comments.txt divx2pass.log a"$aid2".mp3 output.avi