以下のバッチを実行します。
rem 環境によって変えてね
set im=C:\Progra~1\ImageMagick-6.3.5-Q16
%im%\convert.exe sample4.jpg -fx "i>w/2?p[-sqrt(i-w/2),0]:p" sample210a.jpg
元画像(sample4.jpg)

出力画像(sample210a.jpg):画面の右半分を引き伸ばした例

さらに引き伸ばす場合は、以下のコマンドを実行します。
%im%\convert.exe sample4.jpg -fx "i>w/2?p[-(i-w/2)/2,0]:p" sample210b.jpg
出力画像(sample210b.jpg)

No comments:
Post a Comment