[Commits] [wesnoth/wesnoth] b3fe98: add woptipng png compression script

GitHub noreply at github.com
Sun Jan 15 20:53:18 UTC 2017


  Branch: refs/heads/master
  Home:   https://github.com/wesnoth/wesnoth
  Commit: b3fe980d709add4fb8b3fb88faad946bfe55e477
      https://github.com/wesnoth/wesnoth/commit/b3fe980d709add4fb8b3fb88faad946bfe55e477
  Author: Matthias Krüger <matthias.krueger at famsik.de>
  Date:   2016-12-22 (Thu, 22 Dec 2016)

  Changed paths:
    A utils/woptipng.py

  Log Message:
  -----------
  add woptipng png compression script

An improved version of the wesnoth-optipng shell script.

Supports multiple jobs at a time. ( -j )
Accepts a threshold for discarding images which were only reduced by a few bytes. ( -t 15 will only save images that were reduced in size by at least 15 %).
Niceness can be set using the -n switch.

Usage:
cd <directory>
woptipng . ../some/dir  ../some/some_file.png

The script should achive better compression ratios than the previous script.
The previous script was running optimizations in an unconditional loop and, at the end, did not save the image if pixel colors changed.
This implies if *one* of the crushers did a bad job and changed the images content in a bad way, *none* of the possibly good optimizations by the other crushed would be saved.
Woptipng checks the image every time after a crusher touched it and only reverts a single optimization if it was bad leaving possibility for the other tools to still perform a good job and reduce size of the image.


  Commit: 759c3414f3619e91f8ed8d88dd14ed2f8889226b
      https://github.com/wesnoth/wesnoth/commit/759c3414f3619e91f8ed8d88dd14ed2f8889226b
  Author: Elvish_Hunter <elvish.hunter2010 at gmail.com>
  Date:   2017-01-15 (Sun, 15 Jan 2017)

  Changed paths:
    A utils/woptipng.py

  Log Message:
  -----------
  Merge pull request #804 from matthiaskrgr/woptipng-script

add woptipng png compression script


Compare: https://github.com/wesnoth/wesnoth/compare/887fc584c24e...759c3414f361


More information about the Commits mailing list