我正在尝试使用Command将GIF文件转换为PNG文件并调整其大小:
mogrify.exe -define bmp:format=bmp3 -compress none -resize "300x200>" -antialias -format "png" -units PixelsPerInch -density 72 "img.gif"
但是它创建的许多图像的后缀为0到31(img-0.png到img-31.png)。
[当我使用'-flatten'
时,我正在获取合并单个文件,但我只想要第一个转换的文件(img-0.png)。
我们对此有什么选择?
提前感谢!
当指定img.gif[0]
而不是img.gif
时,仅保存第一帧。而且看起来您也不需要-define bmp:format=bmp3
,因为您将文件保存到png
。