My FeedDiscussionsHeadless CMS
New
Sign in
Log inSign up
Learn more about Hashnode Headless CMSHashnode Headless CMS
Collaborate seamlessly with Hashnode Headless CMS for Enterprise.
Upgrade ✨Learn more
Spectrum — a cross-platform image transcoding library

Spectrum — a cross-platform image transcoding library

Fazle Rahman's photo
Fazle Rahman
·Jan 17, 2019

Github: github.com/facebookincubator/spectrum

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:

Getting started for Android
Getting started for iOS
Fork on Github
libspectrum.io