Zopfli

From Wikipedia, the free encyclopedia
Zopfli Archive
ZopfliPNG screenshot.png
Original author(s)Lode Vandevenne and Jyrki Alakuijala
Initial releaseFebruary 2013 (2013-02)
Stable release
1.0.3 / November 27, 2019; 21 months ago (2019-11-27)[1]
Repository
Written inC
Operating systemCross-platform
TypeFile archive, data compression
LicenseApache License 2.0
Websitegithub.com/google/zopfli Edit this on Wikidata

Zopfli is data compression software that encodes data into DEFLATE, gzip and zlib formats.[2] It achieves higher compression than other DEFLATE/zlib implementations, but takes much longer to perform the compression.[3] It was first released in February 2013 by Google as a free software programming library under the Apache License, Version 2.0.[4] The name Zöpfli is the Swiss German diminutive of “Zopf”, an unsweetened type of Hefezopf.[5]

Properties and use case[]

Zopfli can output either a raw DEFLATE data stream or DEFLATE data encapsulated into gzip or zlib formats. It can be configured to do more or fewer iterations than the default 15 to trade processing time for compression efficiency.

Under default settings, the output of Zopfli is typically 3–8% smaller than zlib's maximum compression, but takes around 80 times longer.[4][3] The speed of decompressing Zopfli's output versus zlib's output is practically unaffected.[6]

Due to its significantly slower compression speed, zopfli is less suited for on-the-fly compression and is typically used for one-time compression of static content.[7][8] This is typically true for web content that is served with DEFLATE-based HTTP compression or web content in a DEFLATE-based file format such as PNG or WOFF font files.[9] Another use case is software updates or downloads with software package files that have a zip-based format such as Android application packages (APK) or Java Archives (JAR), especially over mobile connections.[10]

Technology[]

The higher data density is achieved by using more exhaustive compression techniques. The method is based on iterating entropy modeling and a shortest path search algorithm to find a low bit cost path through the graph of all possible DEFLATE representations of the uncompressed data.[11]

Implementations[]

A reference implementation from Google was released in the form of a programming library written in C. It is available as free software under the terms of version 2.0 of the Apache License.[2]

Zopfli can be used from other programming languages as well, via native reimplementations or wrappers.

A selection of alternative implementations
Name Implementation language Implementation type
CompressSharper[12] C# Native
php_zopfli[13] PHP Wrapper
Zopfli in Rust[14] Rust Native

History[]

Zopfli is based on an algorithm from Jyrki Alakuijala.[15] A reference implementation of zopfli was written by Google employees Jyrki Alakuijala and Lode Vandevenne. It was first released to the public in February 2013. Version 1.0.0 was released on April 25, 2013.[16] After several adaptations of Zopfli for PNG compression appeared on GitHub, ZopfliPNG was committed to Google's zopfli reference implementation in May 2013.[17]

PNG optimization[]

The Zopfli algorithm can be used to compress Portable Network Graphics (PNG) files because PNG uses a DEFLATE compression layer. There is a PNG optimization tool named ZopfliPNG from the authors of Zopfli. The Zopfli algorithm has also been integrated into other PNG compression optimization tools like advpng from the AdvanceCOMP utility suite,[18] and .[19]

See also[]

References[]

  1. ^ "Releases - google/zopfli". Retrieved 24 February 2021 – via GitHub.
  2. ^ Jump up to: a b "google/zopfli · GitHub". Github.com. Retrieved 2015-09-29.
  3. ^ Jump up to: a b "A Look At Zopfli, Google's Open Source Compression Algorithm | Lifehacker Australia". Lifehacker.com.au. 2013-03-03. Retrieved 2015-09-29.
  4. ^ Jump up to: a b "Compress data more densely with Zopfli - Google Developers Blog". Googledevelopers.blogspot.com. 2013-02-28. Retrieved 2013-05-01.
  5. ^ Alexander Neumann. "Zopfli: Neue Kompressionsbibliothek von Google | heise Developer" (in German). Heise.de. Retrieved 2015-09-29.
  6. ^ Alakuijala, Jyrki; Vandevenne, Lode. "Data compression using Zopfli" (PDF). Archived from the original on 2016-03-05. Retrieved 2015-09-06.CS1 maint: unfit URL (link)
  7. ^ Dean Hume (2015-06-01). "Improved Compression Ratios Using Zopfli". Retrieved 2015-09-06.
  8. ^ Sharwood, Simon (2013). "Google open sources very slow compression algorithm". The Register.
  9. ^ Ilya Grigorik (2014-01-09). "Google Fonts recently switched to using new Zopfli compression algorithm". Google+. Retrieved 2015-06-06.
  10. ^ Sanders, James. "Google's Zopfli Compression Algorithm: Extract higher performance from your compressed files". TechRepublic. Retrieved 2021-03-31.
  11. ^ "Zopfli: Google's new data compression algorithm | Digit.in". Thinkdigit.com. 2013-03-01. Retrieved 2015-09-29.
  12. ^ "CompressSharper - Source Code". Compresssharper.codeplex.com. 2015-08-21. Retrieved 2015-09-29.
  13. ^ "clickalicious/php_zopfli · GitHub". Github.com. 2015-03-03. Retrieved 2015-09-29.
  14. ^ "Zopfli in Rust". GitHub. Retrieved 2021-03-30.
  15. ^ "zopfli/README at master · google/zopfli". GitHub.
  16. ^ "Release Zopfli-1.0.0". Github.com. 2013-04-25. Retrieved 2015-09-06.
  17. ^ "ZopfliPNG : Google/zopfli@337d27f". Github.com. Retrieved 2015-09-29.
  18. ^ Andrea Mazzoleni. "Advance Projects". Advancemame.sourceforge.net. Retrieved 2015-09-29.
  19. ^ Josh Holmer. "shssoichiro/oxipng - Github". Retrieved 2019-08-05.

External links[]

Retrieved from ""