Merge two pngs via command line tool in windows?

这一生的挚爱 提交于 2019-12-10 10:23:36

问题


I'm looking for a tool I can use via command line (windows 7) to merge two equally sized pngs. I'm not having much luck with search so far as most tools I've seen are pretty heavy applications which don't seem to target simple manipulations.

I want to overwrite the bits in the opaque base image with the non-transparent pixels in the overlay image. I have photoshop CS4 as well, but haven't had much luck in finding the relevant command line arguments.


回答1:


ImageMagick has a command line tool called composite which will do what you want. Distributions available for Windows, Mac, Linux etc. I've just tested it with two transparent PNGs and works as expected.

composite foreground.png background.png newimage.png


来源:https://stackoverflow.com/questions/10608487/merge-two-pngs-via-command-line-tool-in-windows

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!