JamieMason / ImageOptim-CLI

Make optimisation of images part of your automated build process
https://foldleft.io/image-tools
MIT License
3.45k stars 126 forks source link

pngquant binary update to 2.9.1 #144

Closed jamesstout closed 7 years ago

jamesstout commented 7 years ago

pngquant, 2.3.1 (September 2014) -> pngquant, 2.9.1 (April 2017)

Lots of fixes and perf improvements between these versions. Downloaded directly from pngquant.org.

Min OS X version is the same:

2.9.1

james@Jamess-iMac: ~/Downloads/pngquant.tar
$ class-dump -t ./pngquant
#pragma mark -

//
// File: pngquant
// UUID: 90528566-BF72-3D5A-9062-E3FAC9DC0B71
//
//                           Arch: x86_64
//       Minimum Mac OS X version: 10.6.0
//                    SDK version: 10.12.0
//

2.3.1

james@Jamess-iMac: ~/Projects/ImageOptim-CLI/bin on master[!$]
$ class-dump -t ./pngquant
#pragma mark -

//
// File: pngquant
// UUID: 51AEB553-2B4E-34AF-9BE4-C7F284519C2D
//
//                           Arch: x86_64
//       Minimum Mac OS X version: 10.6.0
//                    SDK version: 10.10.0

I ran some performance tests over all of the png images on your results page...

2.3.1

$ time for i in {1..10}; do ./pngquant --ext .xxx --speed 1 -f ~/Desktop/hhhh/*.png ; done

real    2m21.715s
user    1m53.513s
sys 0m26.577s

2.9.1

$ time for i in {1..10}; do /usr/local/bin/pngquant --ext .xxx --speed 1 -f ~/Desktop/hhhh/*.png; done

real    1m40.277s
user    1m16.149s
sys 0m23.662s

That looks to me like a 30% speed improvement.

So far I've only tested it on my box, macOS 10.12.5 (16F73). Will try to test others.

Update: works on a vanilla install of Yosemite 10.10.

JamieMason commented 7 years ago

Thanks! Released in 1.15.1 🎉