Commit Graph

20 Commits

Author SHA1 Message Date
David Thomas 87fc82a978
Flip dither matrix when zig-zagging 2025-06-24 11:08:01 +01:00
David Thomas 9e9abfab27
Add five new types of diffusion dither and expose zig zag to user
This extends the existing dithering code to add Jarvis-Judice-Ninke,
Stucki, Atkinson, Burkes and Sierra error diffused dithers. It also
exposes the zig zag (serpentine) choice to the user. Diffusion is
tweaked to use fixed point for the error values.
2025-06-24 11:08:01 +01:00
David Capello 7fb8cfc8fa Avoid including image impl details as much as possible (image_impl/bits/iterator.h)
Including doc/image.h should be enough to access/iterate the image
pixels.
2024-12-19 09:44:37 -03:00
David Capello 09538f9a1a clang-format all files 2024-12-16 14:52:19 -03:00
David Capello 109e6fa205 Add render::Dithering() class to store all dithering parameters 2019-04-03 19:32:24 -03:00
David Capello fcf272bb69 Add amount parameter to Error Diffusion algorithm 2019-04-03 18:45:18 -03:00
David Capello 08ec3767ba Add support to scan the image in zig-zag way for error diffusion filters 2019-04-03 12:14:17 -03:00
David Capello 20b8ee0e57 Add Floyd-Steinberg dithering for RGBA -> Indexed conversion 2019-04-01 22:00:32 -03:00
David Capello 7a75751dd7 Move dithering algorithm to ordered_dither.cpp 2017-06-01 17:14:15 -03:00
David Capello ae67cab015 Add dithering options for Gradient tool (#418) 2017-05-23 20:41:30 -03:00
David Capello 5ef6aac925 Add --dithering-matrix CLI option
Now the dithering matrix used in ordered dithering algorithm is configurable.
2017-05-19 15:49:31 -03:00
David Capello 03276e0264 Fix ordered dithering issues converting transparent layers + alpha palette entries 2017-05-19 10:17:22 -03:00
David Capello 573cad4777 Add progress bar to color conversion
Unified render tasks stop/progress notifications in render::TaskDelegate
interface.
2017-05-17 15:25:40 -03:00
David Capello 16aeae0833 Add new ordered dithering algorithm 2017-05-17 13:32:34 -03:00
David Capello cbee0862f3 Add a Color Mode conversion dialog with preview 2017-05-16 17:18:55 -03:00
David Capello 372d604d93 Add support for alpha channel in RgbMap and Palette::findBestfit()
This include several changes:
- Color::getIndex() can return palette values with alpha != 255
- Fix Transparent and Blurs ink for indexed images to make better use
  of palette entries with alpha values
- Fix bilinear resize algorithm for indexed images with alpha
- New RgbMap with four parameters: R, G, B, A
- Add one extra color scale function used in the alpha channel of the
  new RgbMap
- Fix color curve, convolution matrix, invert color, and median filters
  to take care of this new alpha channel on indexed images
- Fix ordered dithering and quantization

Related to #286
2015-07-01 21:33:30 -03:00
David Capello 318bc2e2f9 Add alpha channel to palette/color bar/color selector (issue #286) 2015-06-30 17:36:37 -03:00
David Capello 8abc486c85 Use doc:: namespace to access Rgb/IndexedTraits in render::OrderedDither 2015-06-23 11:27:05 -03:00
David Capello b9e7e1b373 Replace std::array with a raw C array
The clang version we're using don't support this feature (from OS X 10.7)
2015-06-23 11:23:05 -03:00
David Capello 70ea54aa20 Re-implement ordered dither in render library 2015-06-22 20:58:33 -03:00