Changes between Version 37 and Version 38 of FilteringGuide
- Timestamp:
- Jan 9, 2015, 5:09:07 AM (6 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
FilteringGuide
v37 v38 106 106 cd $path 107 107 108 filter= "-vf \"yadif=0:-1:0, scale=400:226, drawtext=fontfile=/usr/share/fonts/truetype/DroidSans.ttf: \109 text='tod- %X':x=(w-text_w)/2:y=H-60 :fontcolor=white :box=1:boxcolor=0x00000000@1 \""110 codec= "-vcodec libx264 -pix_fmt yuv420p -b:v 700k -r 25 -maxrate 700k -bufsize 5097k"108 filter=(-vf "yadif=0:-1:0, scale=400:226, drawtext=fontfile=/usr/share/fonts/truetype/DroidSans.ttf: \ 109 text='tod- %X':x=(w-text_w)/2:y=H-60 :fontcolor=white :box=1:boxcolor=0x00000000@1") 110 codec=(-vcodec libx264 -pix_fmt yuv420p -b:v 700k -r 25 -maxrate 700k -bufsize 5097k) 111 111 112 command_line="ffmpeg -i $in_file $filter $codec-an $out_file"112 command_line="ffmpeg -i $in_file \"${filter[@]}\" \"${codec[@]}\" -an $out_file" 113 113 114 114 echo $command_line 115 eval$command_line115 $command_line 116 116 exit 117 117 }}} 118 118 Note that the double quotes " around the whole filtergraph have been escaped \" and the filtergraph spans more than one line, the echo command shows the full command as it is executed. Useful for debugging. 119 119 120 The {{{eval}}} invocation of the $command_line variable is required to avoid loss of the embedded escaped quotes which occurs if itis absent. Other shells may behave differently.120 The arrays in the $command_line variable are required to avoid loss of the embedded escaped quotes which occurs if they is absent. Other shells may behave differently. 121 121 122 122