无缝连接 PNG 一个在另一个之上
seamless join PNGs one above the other
如何使用 ImageMagick(可能是 montage
命令)将 png 图像合并为一个新的 png,其中每个输入的 png 都成为最终图像的一部分?全部竖排?
像这样:
2 个大致相等宽度 (±2px) 和不同高度的 png 无缝连接在一起。
我真的不太介意 excess/smaller 宽度会发生什么。
这个:
convert -append img1.png img2.png out.png
例如来自
会得到
还有:
convert +append img1.png img2.png out2.png
会产生
convert 1.png 2.png -append result.png
- 要对齐左边缘,请添加
-gravity West
。
- 要对齐右边缘,请添加
-gravity East
。
- 要对齐中心,请添加
-gravity center
。
在以下之间添加透明垫片:
convert -background none 1.png -size 10x10 xc:none 2.png -append result.png
哦,你横了!将 -append
更改为 +append
。
如何使用 ImageMagick(可能是 montage
命令)将 png 图像合并为一个新的 png,其中每个输入的 png 都成为最终图像的一部分?全部竖排?
像这样:
2 个大致相等宽度 (±2px) 和不同高度的 png 无缝连接在一起。
我真的不太介意 excess/smaller 宽度会发生什么。
这个:
convert -append img1.png img2.png out.png
例如来自
会得到
还有:
convert +append img1.png img2.png out2.png
会产生
convert 1.png 2.png -append result.png
- 要对齐左边缘,请添加
-gravity West
。 - 要对齐右边缘,请添加
-gravity East
。 - 要对齐中心,请添加
-gravity center
。
在以下之间添加透明垫片:
convert -background none 1.png -size 10x10 xc:none 2.png -append result.png
哦,你横了!将 -append
更改为 +append
。