Skip to content

Releases: Ivordir/Okolors

v0.8.0

03 Jul 06:02
Compare
Choose a tag to compare
  • Changed some build options so that the pre-compiled binaries should be smaller and faster.
  • Okolors should now have better handling of SIGPIPE.

Full Changelog: v0.7.0...v0.8.0

v0.7.0

21 Mar 22:31
Compare
Choose a tag to compare
  • The CLI help stated that the sampling factor could be above 1.0, but this was previously not the case.
  • The --verbose flag now prints to stderr instead of stdout.
  • Updated dependencies. Notably, jpegs may load slightly faster due to image version 0.25.0.

Full Changelog: v0.6.0...v0.7.0

v0.6.0

08 Feb 17:16
Compare
Choose a tag to compare

This update is mainly for the library. See the new Changelog where future changes for the library will be posted.

For the binary/CLI application, nothing has really changed, but it has been rebuilt with newer versions of its dependencies.

Full Changelog: v0.5.1...v0.6.0

v0.5.1

28 Oct 23:49
Compare
Choose a tag to compare

This major update brings huge performance improvements, drastically overhauls the library, and more!

Highlights

Performance

Palette generation now uses better algorithms which should result in a roughly 25% to 50% decrease in palette generation time while also giving slightly more accurate palettes. These algorithms were implemented as part of the new quantette crate.

Additionally, multiple k-means trials are no longer necessary, since the new algorithm more easily recovers from local minima. As such, the corresponding CLI flag and library parameter were removed. So, the performance increase will be even greater if you were running multiple trials for your palettes before.

Ergonomics

The library crate now uses a builder struct API. Reasonable defaults are provided for the various settings, and you now only need to modify the few settings that you want to change.

Also, the library now supports sRGB output instead of only Oklab palettes. Before, one would have to convert from Oklab to sRGB using palette or another crate, but this functionality is now included for convenience.

License

In addition to the MIT license, the library and binary are now both available under the Apache 2.0 license.

All Changes

Below is the full list of changes directly affecting any users. Also, the full changelog: v0.4.0...v0.5.1

Library/Crate

  • Completely overhauled the API. Instead of the run function, use the new Okolors builder struct to create palettes.
  • The Okolors builder struct has functions to create Oklab or sRGB palettes.
  • Removed the trials, convergence threshold, and max iterations parameters. Now, there are only one or two parameters to control the accuracy. These are Okolors::sampling_factor and Okolors::batch_size (if the threads feature is enabled).
  • The threads feature now exposes additional parallel functions instead of changing the implementation of existing functions.
  • Integration with the image crate is now optional and can be turned off with the image feature.
  • The alpha threshold parameter was removed. Only RgbImages are supported for now.

Binary/CLI application

  • Like the library, the trials, convergence threshold, and max iterations flags were removed. Now, use the --sampling-factor/-f flag to control the accuracy.
  • Support for the bmp, avif, and tiff image formats was dropped. webp support is now enabled by default.
  • The --verbose flag now also prints the time taken for each step.
  • The alpha threshold flag was removed. For now, all images with transparency are converted to RGB.

v0.4.0

08 Aug 17:42
Compare
Choose a tag to compare

New Features

  • Mainly just performance improvements. Okolors should be roughly 25% faster on average.

Breaking Changes

  • KmeansResult now reports the MSE instead of variance. I.e., the variance: f32 field was replaced with an mse: f64 field.

Full Changelog: v0.3.0...v0.4.0

v0.3.0

13 Jun 15:58
Compare
Choose a tag to compare

New Features

  • Added --threads/-t flag to specify the number of threads
  • Okolors should now be 2x as fast for most images bigger than like 500 x 500 pixels

Breaking Changes

  • Functions that create an OklabCounts now properly return a Result to handle the error case when the number of pixels is above u32::MAX. As a result, these functions have been renamed with a prefix of try_.

Full Changelog: v0.2.1...v0.3.0

v0.2.1

23 May 17:09
Compare
Choose a tag to compare
  • Made KmeansResult::empty() public
  • Updated dependencies
  • Edited README and added more examples

Full Changelog: v0.2.0...v0.2.1

v0.2.0

20 May 23:13
Compare
Choose a tag to compare

New features

  • Added functions to handle images/colors with transparency (e.g., OklabCounts::from_rgbaimage and OklabCounts::from_srgba).

Breaking changes

  • This is now a single top level function, okolors::run. This was done by replacing all okolors::from_xxx with a corresponding okolors::OklabCounts::from_xxx.
  • Renamed OklabCounts::iter to pairs a529e75

Full Changelog: v0.1.1...v0.2.0

v0.1.1

18 May 21:14
Compare
Choose a tag to compare

First pre-v1.0 release!