Cimg Rust version

Cimg ( https://cimg.eu/ see also The CImg Library is a small and open-source C++ toolkit for image processing)
is a well-developed, download-able C++ image processing library created by David Tschumperlé.

Cimg renders 2-D and 3-D graphic images on MS Windows and Linux systems.
It allows users to encode/decode images in Cimg graphics format and several other commonly used image formats using built-in functions, but
PNG and JPEG formats requires users must add their own code to en/decode these images.

I've used it for several years now, and found it quite useful for integrating complex image processing with complex C++ code.
And also for processing apps involving advanced math apps.

Cimg :

  • only requires one (very large) C++ header file which is very well-organized as a collection of individual template functions.
  • has built-in capabity to handle pixels coded as RGA, RGBA, Gray, Gray-Alpha, u32 values, u16, f32 values etc.
  • easily handles images based on user-defined pallettes
  • has numerous built-in image processing algorithms
  • has lots of built-in math algorithms (including Linear Algebra algorithms)

Converting Cimg to RUST IMHO would greatly enhance RUST IMHO, but I think too-risky for a Rust newbie to tackle.

I'd appreciate any input from more-experienced Rust users regarding to how feasible /difficult it would be to convert Cimg C++ code to Rust.

The image crate handles much of this in Rust and is widely used and well-supported. The imageproc crate by the same developers adds additional processing algorithms. show-image adds the ability to display an image in a window.

1 Like

many thanks...will try both

crate image is very primitive compared to Cimg...crate image appears to be crate lodepng augmented with a few basic image basic processing functions like blur, horiz/vert image flips etc ..