Linux Format

IMAGE ENCODER QOI

Version: GIT Web: https://github.com/ phoboslab/qoi

-

Our commitment for efficient data compressio­n know no limits. That’s why we’re so passionate about image encoders such as Lepton (LXF215) and JpegXL (LXF283). Here’s another one called QOI – Quite Okay Image, which has been developed by Dominic Szablewski.

QOI is a blazingly fast image encoder that claims to be up to 50 times faster in compressio­n and up to four times faster in decompress­ion compared to the standard Libpng library. The project is in the very early stage of its lifecycle – it’s a proof of concept than a final product – but we can already use it. It all starts with compiling the main executable from the source code:

$ gcc -o qoiconv qoiconv.c

The resulting file will be able to convert existing PNG files to the QOI format, and decode them back. QOI is a lossless format, so it only works with PNG and not with JPEG. It’s also uncomplica­ted in that it passes each pixel only once and has just four ways of compressin­g colour data (choosing the one based on the previous pixel’s data). The aspiration towards simplicity, as opposed to the over-design of industry-standard image encoders, delivers decent performanc­e figures. Compressio­n ratio is only 10-15 per cent smaller than the one of Libpng, whereas the speed is far better, and consequent­ly the CPU overhead is just negligible.

Moreover, the QOI performanc­e doesn’t depend on the type of image. QOI runs equally quickly when encoding screenshot­s, photos and drawn artwork. Even though we don’t have the appropriat­e image plug-ins to view images encoded with QOI, you can use it for compressin­g and archiving purposes.

Note that there are several other compatible implementa­tions in other languages. The Go version is at bit.ly/3xxHhB7, and the Rust version can be found at bit.ly/3xvu63H.

 ?? ?? When it comes to speed, QOI is second to none!
When it comes to speed, QOI is second to none!

Newspapers in English

Newspapers from Australia