标签: background imagemagick image-manipulation
我有几张照片需要删除背景(替换为#ffffff)
我尝试了几种方法,但没有一种方法可以提供良好的效果。
例如。 convert "$i" -fuzz 10% -fill '#ffffff' -opaque white $i-new.png
convert "$i" -fuzz 10% -fill '#ffffff' -opaque white $i-new.png
这会使结果更白,并在白色和阴影之间产生相当粗糙的线条。
更多样本图片
答案 0 :(得分:0)
我想你想要使用左上角的颜色填充洪水:
convert cauli.jpg -fuzz 10% -fill red -draw 'color 0,0 floodfill' result.png
可能使用白色填充物: - )