Sergey "Shnatsel" Davidoff
Sergey "Shnatsel" Davidoff
There is actually a **linear-complexity** blur already implemented in Rust, where execution time is independent of blur radius: https://github.com/fschutt/fastblur I've recently optimized the implementation by a further 2.5x, ~~but not...
`resvg` crate recently got the linear complexity algorithm linked above to production quality. It now supports alpha channel as well as all color formats that shuffle RGBA. Now it also...
More sample issues triggering this behavior can be found in https://github.com/image-rs/image/issues/1234
FWIW this is the only error triggered on the [archive.org wallhaven dataset](https://archive.org/details/WallhavenSexyWomen), which is the largest easily downloadable dataset of real-world images I could find (100,000 files, 76Gb). There are...
Yes. Here's the code used for testing: ```rust fn main() -> std::io::Result { let path = std::env::args().skip(1).next().unwrap(); let _ = image::io::Reader::open(path)? .with_guessed_format() .unwrap() .decode() .unwrap(); Ok(()) } ``` `image::io::Reader::open` does...
Initial experiments with buffering are available in the `buffered-reads` branch but do not demonstrate significantly better results so far.
`jpeg_decoder::huffman::HuffmanDecoder::read_bits` accounts for 23% of all time spent, does byte-by-byte reads and spends most of its time calling `std::io::Read::read_exact`. Plus has additional complex logic because of its inability to return...
I've done some more profiling and tinkering, and I believe my earlier assumptions are incorrect. In parallel mode most of the time is spent in `jpeg_decoder::idct::dequantize_and_idct_block_8x8_inner`. [Here's a finer-grained profile...
After looking at it some more I don't think we can do much here without parallelization and/or SIMD, since the IDCT algorithm appears to be identical to the fallback one...
After looking at IDCT some more, particularly the threaded worker, there's really no reason why it cannot be made multi-threaded by component. They are already decoded independently and 95% of...