#image #image-processing

sys image2

A simple image processing library

39 releases (15 stable)

Uses new Rust 2021

1.6.1 Sep 20, 2022
1.5.3 Aug 26, 2022
1.3.0 Jul 22, 2022
1.1.1 Sep 29, 2021
0.4.0 Nov 11, 2018

#58 in Images

Download history 218/week @ 2022-06-14 228/week @ 2022-06-21 222/week @ 2022-06-28 249/week @ 2022-07-05 273/week @ 2022-07-12 268/week @ 2022-07-19 303/week @ 2022-07-26 407/week @ 2022-08-02 316/week @ 2022-08-09 341/week @ 2022-08-16 355/week @ 2022-08-23 322/week @ 2022-08-30 422/week @ 2022-09-06 347/week @ 2022-09-13 325/week @ 2022-09-20 278/week @ 2022-09-27

1,416 downloads per month
Used in viewimg

ISC license

4.5MB
4.5K SLoC

image2 - image processing library

A Rust crate focused on generic image processing for a wide range of image formats and data types.

  • Supported image data types: u8, i8, u16, i16, u32, i32, u64, i64, f16, f32, f64
  • Supported color types: gray, rgb, rgba, hsv, cmyk, xyz
  • Read and write images of any supported type/color
  • Easy to add new colors
  • Generic image processing across data types using Pixel
  • Composable operations using Filter (with async support)

OpenImageIO is used to read/write images and supports:

  • TIFF
  • JPEG/JFIF
  • OpenEXR
  • PNG
  • HDR/RGBE
  • ICO
  • BMP
  • Targa
  • JPEG-2000
  • RMan Zfile
  • FITS
  • DDS
  • Softimage PIC
  • PNM
  • DPX
  • Cineon
  • IFF
  • Field3D
  • Ptex
  • Photoshop PSD
  • Wavefront RLA
  • SGI
  • WebP
  • GIF
  • A variety of RAW digital camera formats

ImageMagick can also be used in place of OpenImageIO.

This is not a pure Rust crate, if that's important to you then image is probably a better fit.

Features

  • oiio
    • Enables I/O using OpenImageIO (default: enabled)
  • parallel:
    • Enables parallel image iterators (default: enabled)
  • text:
    • Enables loading fonts and drawing text on images (default: enabled)
  • window:
    • Enables ability to draw images to a graphical window (default: disabled)
  • halide:
  • serialize:
    • Enables serde support for several data structures (default: disabled)

External dependencies

  • libOpenImageIO (optional)
    • oiio feature
    • Version >= 2.0
    • Debian-based distros: apt install libopenimageio-dev
  • ImageMagick (optional)
    • Only required if oiio is not being used

Dependencies

~1–8.5MB
~164K SLoC