Imagemagick组成图像倒置 [英] Imagemagick compose image inverted

查看:79
本文介绍了Imagemagick组成图像倒置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想给图像加水印,所以我使用了组合乘法,但是由于某些原因,它不能按预期工作.

I want to watermark an image, so I used compose multiply, but for some reason it doesn't work as expected.

命令:

magick image.jpg over.png  -compose multiply -resize 2048x2048 -gravity center -quality 65 -strip  -composite out.jpg

over.png首先反转,然后应用? 如果对旧版本的Imagemagick(x32 6.7.6-1 2012-03-17 Q16)使用相同的命令,则会得到预期的结果. 这已在Windows 10下使用x64 ImageMagick 7.0.5 Q16进行了测试.

The over.png get inverted first and then applied?? If use the same command with and older version of Imagemagick (x32 6.7.6-1 2012-03-17 Q16) I get the expected results. This was tested with x64 ImageMagick 7.0.5 Q16 under Windows 10.

嗯,似乎无法发布所有图片.

Ah it seems I can't post all the images.

推荐答案

经过大量研究,结果证明这是一种图像伪像,是CMYK颜色空间中的JPEG. 很奇怪,但是你去了.

After a lot of research, turns out it's an artifact of one of the images being a JPEG in CMYK colorspace. Very weird, but there you go.

在该行中添加"-profile sRGB.icc"即可解决问题.

Adding '-profile sRGB.icc' to the line should take care of it.

这篇关于Imagemagick组成图像倒置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆