Spectrum — a cross-platform image transcoding library
Stay in the loop!
Subscribe to my newsletter and stay up-to-date with my latest blog posts. Get an email every time I post something new.
Spectrum is an open source image transcoding library from Facebook's open source incubator. It's interesting because it lets you efficiently perform common image operations on the client side for Android or iOS projects.
Under the hood, it uses Mozilla's mozjpeg to reduce the file size of JPEG images while retaining the quality. It is written in portable C/C++ which makes it easy to adapt to any environment.
Some of the operations supported by this library are:
- Encoding: converting a bitmap into an encoded image
- Transcoding: converting an encoded image into another encoded image
- Decoding: converting an encoded image into a bitmap
- Transforming: converting a bitmap into another bitmap
Some of the commonly used image transformations are also supported like: Cropping (relatively and absolutely), rotating, resizing, etc.
Read the docs for more details: