dragonfly-ai / img   0.1

Apache License 2.0 GitHub

A Scala.js Image Processing Library

Scala versions: 3.x
Scala.js versions: 1.x
Scala Native versions: 0.5

img

A cross published Scala library for Image Processing.

Overview:

This Scala.js library brings convenient, high performance, image representation classes with low level processing capabilities to Scala.js, Scala JVM, and Scala Native.

Internals:

From the perspective of Scala on the JVM, the Img class wraps an Array[Int] for fast conversion to Java's BufferedImage type to maximize interoperability with other JVM image processing libraries.

From the perspective of Scala.js or plain JavaScript environments such as web browsers and Node.js, the Img class wraps the native Uint8ClampedArray to facilitate interoperability with Canvas, pixel data transfer to WebWorkers, and fast data serialization.