Install pngquant – Lossy PNG Compression App on Linux

28/12/2020
Chưa phân loại

If you are looking for a simple image compression tool, check out pngquant, a command-line utility and a library for lossy compression of PNG images.

The app conversion reduces file sizes significantly (as much as 70% of original size) whilst preserving the full alpha transparency of the image. All generated images are compatible with all modern web browsers, as well as having a better fallback in IE6 than 24-bit PNGs.

Key Features

  • High-quality palette generation using a combination of vector quantizationalgorithms.
  • Unique adaptive dithering algorithm that adds less noise to images than the standard Floyd-Steinberg.
  • Easy to integrate with shell scripts, GUIs and server-side software.
  • Fast mode for processing large numbers of images.

Algorithm

  • It uses modified version of Median Cut quantization algorithm and additional techniques to mitigate deficiencies of Median Cut.
  • Instead of splitting boxes with largest volume or number of colors, boxes are selected to minimize variance from their median value.
  • Histogram is built with addition of a basic perception model, which gives less weight to noisy areas of the image.
  • To improve color further, histogram is adjusted in a process similar to gradient descent (Median Cut is repeated many times with more weight on poorly represented colors).
  • Finally, colors are corrected using Voronoi iteration (K-means), which guarantees locally optimal palette.
  • pngquant works in premultiplied alpha color space to give less weight to transparent colors.
  • When remapping, error diffusion is applied only to areas where several neighboring pixels quantize to the same value, and which are not edges. This avoids adding noise to areas which have high visual quality without dithering.

See Changelog for most recent update

How to install latest pngquant on Ubuntu 16.04

apt-get install git libpng16-dev    git clone --recursive https://github.com/pornel/pngquant.git    cd pngquant    make    sudo make install

Visit https://pngquant.org for basic steps on how to use the tool

ONET IDC thành lập vào năm 2012, là công ty chuyên nghiệp tại Việt Nam trong lĩnh vực cung cấp dịch vụ Hosting, VPS, máy chủ vật lý, dịch vụ Firewall Anti DDoS, SSL… Với 10 năm xây dựng và phát triển, ứng dụng nhiều công nghệ hiện đại, ONET IDC đã giúp hàng ngàn khách hàng tin tưởng lựa chọn, mang lại sự ổn định tuyệt đối cho website của khách hàng để thúc đẩy việc kinh doanh đạt được hiệu quả và thành công.
Bài viết liên quan

[MariaDB Replication] Hướng dẫn cấu hình MariaDB Replication

MySQL Replication là một kỹ thuật trong MySQL cho phép dữ liệu từ một Server CSDL MySQL (master) được...
30/12/2020

Ubuntu vs Linux Mint Distro Comparison

With the constantly changing system and desktop requirements, our needs for a suitable operating system change too. For...
29/12/2020

How to install RabbitMQ on Ubuntu

In this post, we will see how we can install one of the most popular asynchronous messaging tools, RabbitMQ. According...
28/12/2020
Bài Viết

Bài Viết Mới Cập Nhật

Reliable IPv4 and IPv6 Subnet Rental Services: The Perfect Solution for Global Businesses
23/12/2024

Tìm Hiểu Về Thuê Proxy US – Lợi Ích và Cách Sử Dụng Hiệu Quả
11/12/2024

Mua Proxy V6 Nuôi Facebook Spam Hiệu Quả Tại Onetcomvn
03/06/2024

Hướng dẫn cách sử dụng ProxyDroid để duyệt web ẩn danh
03/06/2024

Mua proxy Onet uy tín tại Onet.com.vn
03/06/2024