Adding Chinese watermarks to images using ffmpeg on Windows 10
Code:
Multi Line Version:
Replace "仅为开户使用" with the watermark text you want to write.
ffmpeg -i i1.jpg -vf "drawtext=text='仅为开户使用':fontfile='C\:/Windows/Fonts/msyh.ttc':fontsize=168:fontcolor=white@0.5:x=(w-text_w)/2:y=(h-text_h)/2" output.jpg
Multi Line Version:
ffmpeg -i i1.jpg -vf "drawtext=text='仅为开户使用':fontfile='C\:/Windows/Fonts/msyh.ttc':fontsize=w*0.03:fontcolor=white@0.7:x=w*0.1:y=h*0.2,drawtext=text='仅为开户使用':fontfile='C\:/Windows/Fonts/msyh.ttc':fontsize=w*0.03:fontcolor=white@0.7:x=w*0.4:y=h*0.2,drawtext=text='仅为开户使用':fontfile='C\:/Windows/Fonts/msyh.ttc':fontsize=w*0.03:fontcolor=white@0.7:x=w*0.7:y=h*0.2,drawtext=text='仅为开户使用':fontfile='C\:/Windows/Fonts/msyh.ttc':fontsize=w*0.03:fontcolor=white@0.7:x=w*0.1:y=h*0.5,drawtext=text='仅为开户使用':fontfile='C\:/Windows/Fonts/msyh.ttc':fontsize=w*0.03:fontcolor=white@0.7:x=w*0.4:y=h*0.5,drawtext=text='仅为开户使用':fontfile='C\:/Windows/Fonts/msyh.ttc':fontsize=w*0.03:fontcolor=white@0.7:x=w*0.7:y=h*0.5,drawtext=text='仅为开户使用':fontfile='C\:/Windows/Fonts/msyh.ttc':fontsize=w*0.03:fontcolor=white@0.7:x=w*0.1:y=h*0.8,drawtext=text='仅为开户使用':fontfile='C\:/Windows/Fonts/msyh.ttc':fontsize=w*0.03:fontcolor=white@0.7:x=w*0.4:y=h*0.8,drawtext=text='仅为开户使用':fontfile='C\:/Windows/Fonts/msyh.ttc':fontsize=w*0.03:fontcolor=white@0.7:x=w*0.7:y=h*0.8" output6.jpg
Replace "仅为开户使用" with the watermark text you want to write.
Comments
Post a Comment