resize
resize copied to clipboard
Simple resampling library in pure Rust
A 2x2 grayscale image: ``` [1, 0, 0, 2] ``` Is incorrectly upscaled to the following 4x4 image: ``` [1, 0, 0, 0, 0, 2, 2, 2, 0, 2, 2,...
Here's the gmail logo:  And here's the logo reduced a little using triangle:  Note the border around the mail icon. I'm guessing it's sampling colours in the transparent...
Baseline JPEG and PNG can be decoded and encoded (almost) row-by-row. If resize supported iterators for reading pixels in, then the application wouldn't have to buffer the whole image before...
- spline16, spline36, spline64 from AviSynth - gauss - maybe some more, see [mpv's filters](https://github.com/mpv-player/mpv/blob/master/video/out/filter_kernels.c)
It would probably be a good idea to just copy `src` into `dst` if source and destination dimensions are equal; also some fool-proof checkings like `w, h != 0` and...
Might be interesting to implement [EWA](http://www.imagemagick.org/Usage/filter/#cylindrical) and some popular filters like LanczosSharp.
It would be good idea to check whether filter implementation is correct by comparing resizing results against some predefined test images made with IM. See: http://www.imagemagick.org/script/compare.php