pngcrush 使用教程_使用PNGCRUSH缩小PNG图形大小

pngcrush 使用教程

Now that I'm knee-deep in MacBook I love working with command line applications. There's a certain beauty in the simplicity of using the console instead of a nice GUI. One task I use the console for often is reducing the size of PNG files using the powerhouse that is PNGCRUSH.

现在,我对MacBook有所了解,我喜欢使用命令行应用程序。 使用控制台而不是漂亮的GUI的简单性具有一定的美感。 我经常使用控制台的一项任务是使用强大的PNGCRUSH减小PNG文件的大小。

Shell脚本 (The Shell Script)


# directive
pngcrush -reduce -brute source.png destination.png

#result
Best pngcrush method = 113 (fm 0 zl 9 zs 0) for destination.png
     (33.38% IDAT reduction)
     (33.43% filesize reduction)

   CPU time used = 835.707 seconds (decoding 151.450,
          encoding 679.145, other 5.112 seconds)


The above directive is a basic usage of PNGCRUSH. PNGCRUSH offers a wealth of options that allow you to optimize your PNGs. If you use many PNGs on your website, optimizing them using PNGCRUSH is a must. Using the above directive, PNGCRUSH took a 11.7MB down to 7.8MB. NO QUALITY LOSS. Sure it took over 10 minutes, but think of the bandwidth your site will save.

上面的指令是PNGCRUSH的基本用法。 PNGCRUSH提供了大量选项,可让您优化PNG。 如果您在网站上使用许多PNG,则必须使用PNGCRUSH对其进行优化。 使用以上指令,PNGCRUSH从11.7MB减少到7.8MB。 没有质量损失 。 当然花费了超过10分钟,但请考虑一下您的网站将节省的带宽。

翻译自: https://davidwalsh.name/pngcrush

pngcrush 使用教程

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值