All notable changes to the Rimage library will be documented in this file.
- cli: 🚑 convert all input images to rgba8 (c980e9a)
- cli: 🐛 fixed incorect handling of file names with dots (1f3275c)
- cli: 🐛 fixed null error on avif decoding (59b6759)
- error if input width or height is 0 (b626fdc)
- cli: 🐛 ensure max length calculation returns 0 instead of panicking when no outputs are present (3d0a3a3)
- cli: 🐛 fixed handling of float32 images (66c3648)
- cli: 🐛 improved resize value parsing by trimming input and refining error handling for invalid formats (2a43c26)
- cli: 🐛 updated parsing logic for width and height to reduce number of edge cases (9bd3ea2)
- operations: 🐛 updated apply icc profile operation to work in threads (b5dee09)
- cli: ✨ update resize value format for width and height to use 'w' and 'h' suffixes instead of 'x_' and '_x' (693ea46)
- cli: 💄 updated display styles (19adcea)
- cli: 💄 added progress bar (398e504)
- cli: ✨ added quiet and no progress flags (0517908)
- codecs: ✨ added tiff support (abc78f5)
- cli: fixed encoder function (1a6bf92)
- codecs: fixed clippy errors (7f3c261)
- codecs: updated avif decoder to new api (1c8ea8e)
- codecs: updated avif encoder to new api (d07193d)
- codecs: updated mozjpeg encoder to new api (b408b31)
- codecs: updated oxipng encoder to new api (fdfcbd9)
- codecs: updated webp decoder to new api (98728e0)
- codecs: updated webp encoder to new api (ede4784)
- workflow: 👷 removed check for unique branch (0505c62)
- workflow: 💚 fixed macos version (17eeba1)
- fixed clippy issues (0045b5b)
- cli: 🚸 added warn when input is not a file (dd2fe3e)
- operations: added "apply icc profile" operation (e12b7c4)
- Another complete rewrite of the library, please use
zune-image
with this crate. - CLI has been rewritten to a new, more flexible interface
Improved performance (alot). To libvips performance, like to the moon, but still. Benchmark data was taken from sharp repository.
Options --directory /tmp --resize 500x200 --filter lanczos3 mozjpeg --quality 80 -- ./2569067123_aca715a2ee_o.jpg
One image from here:
Benchmark 1: rimage-0.11.0-next.0
Time (mean ± σ): 48.6 ms ± 1.3 ms [User: 43.9 ms, System: 8.4 ms]
Range (min … max): 46.7 ms … 53.3 ms 59 runs
Benchmark 2: rimage-0.10.3
Time (mean ± σ): 691.6 ms ± 5.2 ms [User: 709.3 ms, System: 10.1 ms]
Range (min … max): 687.1 ms … 705.0 ms 10 runs
Benchmark 3: squoosh-cli
Time (mean ± σ): 760.6 ms ± 29.7 ms [User: 2155.7 ms, System: 291.2 ms]
Range (min … max): 738.0 ms … 829.5 ms 10 runs
Summary
rimage-0.11.0-next.0 ran
14.23 ± 0.39 times faster than rimage-0.10.3
15.65 ± 0.74 times faster than squoosh-cli
Options --directory /tmp --resize 500x200 --filter lanczos3 mozjpeg --quality 80 -- ./*.jpg
Multiple images in parallel from here (only jpg):
Benchmark 1: rimage-0.11.0-next.0
Time (mean ± σ): 177.2 ms ± 4.6 ms [User: 999.5 ms, System: 38.7 ms]
Range (min … max): 169.3 ms … 184.7 ms 17 runs
Benchmark 2: rimage-0.10.3
Time (mean ± σ): 26.399 s ± 0.336 s [User: 29.653 s, System: 0.089 s]
Range (min … max): 26.045 s … 27.297 s 10 runs
Summary
rimage-0.11.0-next.0 ran
148.99 ± 4.31 times faster than rimage-0.10.3
- added avif decoder (b64b931)
- added avif encoder (18ee7e3)
- added fast resize operation (4317475)
- added features to reduce lib size (e23823f)
- added long_about to jxl codec (8a19d4b)
- added mozjpeg encoder (7f32068)
- added options to jpeg codec (ccd249c)
- added oxipng encoder (4a824dc)
- added quantization operation (25d0d78)
- added threading to resize operation (1e89b34)
- added webp decoder (3916d28)
- added webp encoder (d542749)
- cli/help: added codecs support section (8578367)
- cli: added alpha premultiply preprocessor (33abc88)
- cli: added avif codec (aa89db5)
- cli: added base cli options (a22a0aa)
- cli: added base codecs (60d9aa5)
- cli: added base preprocessors (99d6a33)
- cli: added mozjpeg codec (37359e2)
- cli: added oxipng codec (9658fce)
- cli: added webp codec (57db180)
- cli: changed general options placement (5cf1e96)
- cli: implemented main cli (a666dbf)
- encoders: added exif write support for jpeg and png (fcd4f5e)
- implemented base cli pipeline (18bcbe0)
- preprocessors: implemented quantization operation (e527d69)
- preprocessors: implemented resize operation (7aa016e)
- added binary feature (ee148f1)
- added more image formats (15aebe6)
- bin: moved binary to root folder (f637d14)
- cargo: updated cargo.toml (4fba401)
- cli/windows: fixed trailing slash cmd issue (88e6b92)
- cli: fixed clippy issue (8b5d230)
- cli: updated features compilation (0a70264)
- cli: updated preprocessors using traits (b8be3ff)
- codecs: updated qtable type (5a2c2f9)
- deps: changed dav1d dependence to lib aom (032b050)
- deps: optimized dependencies (370f5d3)
- fixed clippy errors (2ca79be)
- fixed clippy errors (b2b7f79)
- fixed clippy warnings (d98091a)
- fixed tests for image_format (454f5c8)
- lib: cleared lib (5d7b2c6)
- made options values public (7d3fa3b)
- moved cli modules to separate directory (81593d0)
- moved encoders to separate modules (7c6816f)
- Added support for all image formats that supported by
image
crate
- fixed bug when resize option doesn't do anything
- Removed unused dependencies
- Updated readme and help section
- Reduced size of the binary
- Replaced
image
module: Now re-exporting theimage
crate, which may affect existing functionalities. - Refactored Decoder and Encoder: Changes in method signatures and behavior could potentially break existing code.
- Removed support for windows-gnu targets due to full msvc support.
- Added support for musl targets
- Added support for wasm targets (emscripten and wasi)
- Added full support for all features on windows i686 (x86) and x86_64 targets
- Changed codec for jxl compression. Shifted to support only lossless compression for improved efficiency and portability.
- Integration with image crate: Refactored Decoder and Encoder modules to utilize the image crate, enhancing functionality.
- Dependencies Update: Adjusted dependencies to align with new implementations and removed outdated ones.
- Added previously removed
--threads
option when parallel feature is enabled.
- Temporarily removed from plans stdin input due to complexity.
- Library Structure Rewrite: The library structure has been entirely rewritten, resulting in no backward compatibility.
- Output directory now works differently, folder structure only preserves with
--recursive
flag. --format
flag renamed to--codec
,-f
shortcut is not affected.- Removed stdin input, no more freezes when input files is not provided.
Stdin input will be returned in latest releases.
- Removed progress bar because of issues with
indicatif
crate.Progress bar will be returned in latest releases.
- Divided crate to separate features to improve modularity.
- Divided
Config
into several parts for improved modularity. - Moved
Codec
andImageFormat
into theconfig
module. - Updated the
Decoder
andEncoder
structs with more concise interfaces. - Updated error messages and handling to align with the new library structure.
- Enhanced
from_path
inDecoder
to handle image format and orientation.
- Introduced
EncoderConfig
for configuring encoding. - Introduced
ResizeConfig
for configuring image resizing (optional). - Introduced
QuantizationConfig
for configuring image quantization (optional). - Added
fixed_orientation
toDecoder
to save image orientation according to EXIF tag. - Added
-b --backup
flag to backup input files in case of replacing.
- When glob cannot find any files, files provided by user will be processed.
- Fixed an issue where extensions were written in uppercase.
- Updated progress bar.
- Rimage now uses the rayon crate for parallel optimizations.
- Added
--quiet
flag that disables the progress bar.
Decoder
now acts as a builder forGenericDecoder
capable of decoding byte slices and files.Config
now uses a builder pattern.- Renamed
OutputFormat
toCodec
. - Errors are now more declarative.
- Removed
decoders
andencoders
. - Introduced
optimize
andoptimize_from_memory
functions. - Added
ImageFormat
for memory decoding. - Fixed jpeg decoding.
- Decoder now accepts an opened file as input.
ImageData
now stores bytes asBox<[u8]>
.- Global allocator is now Jemalloc on Unix and MiMalloc on Windows.
- Reduced peak heap usage by half.
- Output format option is now named simply
format
. - Added AVIF decoding and encoding.
- Added output directory option for saving in different locations.
- Fixed an issue where extensions were written in uppercase; now they are all normalized to lowercase.
- Decoder now accepts an opened file as input.
- Added AVIF decoding and encoding.
- Added an output directory option for saving in different locations.
- Added WebP decoding and encoding.
- Fixed a typo in logs.
- Added logging of errors and info.
- Replaced
eprintln!
witherror!
.
- Added image resize functionality.
- Introduced a resize error to
EncodingError
. - Added width and height arguments to CLI.
- Added a resize filter type argument to CLI.
Config::build
now requires 5 arguments.
- Added image quantization.
- Introduced quantization error to
EncodingError
. - Added a
data_mut
function toImageData
. - Added an
encode_quantized
function. - Added a quantization argument to CLI.
- Added a dithering argument to CLI.
- Added parallelism.
- Added a thread number option to use (Default: number of CPUs).
- Replaced strings in errors with
SimpleError
.
- Updated the Readme.
- Introduced
ImageData
for storing image data. - Introduced
Decoder
to decode images. - Introduced
Encoder
to encode images. - Introduced error struct's in
rimage::errors
. - Added image ## [v0.1.processing from stdio.
- Added an info option.
- Added a suffix option.
- Deprecated
decoders::decode_image
andencoders::encode_image
; useDecoder
andEncoder
struct's instead. - Improved documentation for almost all functions and struct's with examples.
- Added support for PNG as output (not oxipng codec).
- Fixed long processing of PNG images.
- Added a pretty progress bar.
- Fixed a hardcoded format output.
- Added support for RGBA images.