Spectrum

Spectrum

  • About Spectrum
  • Getting Started
  • GitHub

›Concepts

Intro

  • About Spectrum

Getting Started

  • Getting Started on Android
  • Getting Started on iOS
  • Sample Apps

Concepts

  • Supported Image Flows
  • Supported Image Formats

Using Spectrum

  • Transcoding Images for Upload
  • Resizing Images
  • Cropping Images
  • Rotating Images
  • Encoding Images
  • FAQ

Contributing

  • Project Structure
  • Contributing on Android
  • Contributing on iOS

Supported Image Flows

Spectrum's API provides four main methods which cater all possible permutations of having bitmaps or encoded images as either input or output. All of them allow to apply common transformations.

Operations

Spectrum supports four main types of operations:

  • Encoding: The operation of converting a bitmap into an encoded image. This operation requires providing an encode requirement to specify the target image's encoding parameters such as format, quality & mode.
  • Transcoding: The operation of converting an encoded image into another encoded image. Just as encoding, this operation requires providing an encode requirement to specify the target image's encoding parameters such as format, quality & mode. Some image formats, such as JPEG, support lossless transcoding given certain options. For more info, check the lossless JPEG bullet point.
  • Decoding: The operation of converting an encoded image into a bitmap.
  • Transforming: The operation of converting a bitmap into another bitmap.

Transformations

Each operation supports transformations such as cropping, resizing & rotating. Applying transformations in conjunction with the decoding / transcoding steps may allow Spectrum to choose a more memory-efficient execution. For example, when uncompressing an image, Spectrum may be able to leverage sampling to avoid ever reading the entire image into memory.

← Sample AppsSupported Image Formats →
  • Operations
  • Transformations
Spectrum
Docs
About SpectrumGetting StartedContributing
Community
FacebookTwitter
Legal
Terms of UseData PolicyCookie Policy
More
GitHubStar
Facebook Open Source
Copyright © 2022 Facebook