【问题标题】:Convert png to webp does not preserve transparency将 png 转换为 webp 不保留透明度
【发布时间】:2021-10-03 12:48:58
【问题描述】:

使用 Google cwebp 实用程序 (https://developers.google.com/speed/webp/docs/cwebp) 和 ImageMagick convert 实用程序,我无法在转换为 webp 时保留 png 图像的透明度。

使用convert 我尝试使用 alpha-compression=0 和 alpha-quality=100,但没有得到肯定的结果。见:https://imagemagick.org/script/webp.php

我正在使用的图像具有圆形图标图像的透明角。

正在使用的脚本(在 Fish shell 中):

for file in *.png;
  cwebp $file -o (basename $file .png).webp;
end;

和

for file in *.png;
  convert $file (basename $file .png).webp;
end;

【问题讨论】:

    标签: imagemagick transparency webp


    【解决方案1】:

    没关系。是我的图像编辑器没有正确显示透明度。透明度仍然存在。现在在https://github.com/linuxmint/pix/issues提交错误报告

    【讨论】:

    • 在您回答问题后,我使用vwebp 检查了我的结果,发现 gthumb 包含问题,而不是 cwebp
    猜你喜欢
    • 1970-01-01
    • 2018-10-19
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2012-03-22
    • 1970-01-01
    • 1970-01-01
    • 2011-06-29
    相关资源
    最近更新 更多