-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathffmpeg backup.txt
64 lines (61 loc) · 1.71 KB
/
ffmpeg backup.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
mixed audio files + RGB COLOR resolution padding working
change: input files and n=# in filter_complex
output .mkv file
ffmpeg \
-loop 1 \
-framerate 2 \
-i front.png \
-i song1.wav \
-i song2.mp3 \
-i song3.flac \
-i song4.wma \
-i song5.aiff \
-i song6.m4a \
-i song7.aac \
-c:a pcm_s32le \
-filter_complex 'concat=n=7:v=0:a=1' \
-vcodec libx264 \
-bufsize 3M \
-filter:v "format=rgb24,scale=w='if(gt(a,1.7777777777777777),1280,trunc(720*a/2)*2)':h='if(lt(a,1.7777777777777777),720,trunc(1280/a/2)*2)',pad=w=1280:h=720:x='if(gt(a,1.7777777777777777),0,(1280-iw)/2)':y='if(lt(a,1.7777777777777777),0,(720-ih)/2)':color=#966e6e " \
-crf 18 \
-pix_fmt yuv420p \
-shortest \
-tune stillimage \
-t 1730 \
out_white.mkv
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
mixed audio files mp4 output
• 7 audio files
• total length in seconds video should be
• vid resolution and/or padding with rgb color
• video output audio codec:
○ .mkv output
§ -c:a pcm_s32le \
○ .mp4 output:
§ -c:a libmp3lame \
-b:a 320k \
○
ffmpeg \
-loop 1 \
-framerate 2 \
-i front.png \
-i song1.wav \
-i song2.mp3 \
-i song3.flac \
-i song4.wma \
-i song5.aiff \
-i song6.m4a \
-i song7.aac \
-c:a libmp3lame \
-b:a 320k \
-filter_complex 'concat=n=7:v=0:a=1' \
-vcodec libx264 \
-bufsize 3M \
-filter:v "format=rgb24,scale=w='if(gt(a,1.7777777777777777),1280,trunc(720*a/2)*2)':h='if(lt(a,1.7777777777777777),720,trunc(1280/a/2)*2)',pad=w=1280:h=720:x='if(gt(a,1.7777777777777777),0,(1280-iw)/2)':y='if(lt(a,1.7777777777777777),0,(720-ih)/2)':color=#966e6e " \
-crf 18 \
-pix_fmt yuv420p \
-shortest \
-tune stillimage \
-t 1730 \
out_color_mp4.mp4