如何使图像魔术中的淡入淡出边缘? [英] How to make fade edges in image magic?
本文介绍了如何使图像魔术中的淡入淡出边缘?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想使用imagemagic命令创建褪色的边缘图像效果.请帮助我,以使命令生效,例如 http://postimg.org/image/h51e4twyp/
I want to create faded edges image effect using imagemagic commands. Please help me for a command to make effect as like http://postimg.org/image/h51e4twyp/
推荐答案
从
curl -o doge.jpg http://i0.kym-cdn.com/photos/images/newsfeed/000/581/296/c09.jpg
下一步,模糊边缘.
convert doge.jpg -alpha set -virtual-pixel transparent -channel A -morphology Distance Euclidean:1,20\! +channel doge.png
您将需要将其输出为.png
You will need to output it as a .png
编辑:以上示例适用于ImageMagick v6.
Edit: The above example is for ImageMagick v6.
对于IMv7,请尝试:
For IMv7 try:
convert doge.jpg \( +clone -alpha extract -virtual-pixel black -gamma 2 +level 0,100 -white-threshold 99 -morphology Distance Euclidean:1,200! -sigmoidal-contrast 3,0% \) -compose CopyOpacity -composite doge_im7.png
这篇关于如何使图像魔术中的淡入淡出边缘?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文