Skip to content

Jarvis-judice-ninke dithering #9619

Open

Description

@jmerc77

Feature request...

I wanted to use jarvis-judice-ninke dither but it is not in Pillow nor seems planned.
jarvis-judice-ninke is a more enhanced variant of floyd-steinberg.

while floyd- steinberg uses:
*7
351

jarvis-judice-ninke uses:
*75
35753
13531

for the diffusion matrix. this does mean it is a little slower. however, Pillow is fast enough that the speed difference may be unnoticed for typical use cases.


--------------------------------------------------------------------
Pillow 12.1.1
Python 3.13.12 (tags/v3.13.12:1cbe481, Feb  3 2026, 18:22:25) [MSC v.1944 64 bit (AMD64)]
--------------------------------------------------------------------
Python executable is C:\Users\Owner\AppData\Local\Python\pythoncore-3.13-64\pythonw.exe
System Python files loaded from C:\Users\Owner\AppData\Local\Python\pythoncore-3.13-64
--------------------------------------------------------------------
Python Pillow modules loaded from C:\Users\Owner\AppData\Local\Python\pythoncore-3.13-64\Lib\site-packages\PIL
Binary Pillow modules loaded from C:\Users\Owner\AppData\Local\Python\pythoncore-3.13-64\Lib\site-packages\PIL
--------------------------------------------------------------------
--- PIL CORE support ok, compiled for 12.1.1
--- TKINTER support ok, loaded 8.6
--- FREETYPE2 support ok, loaded 2.14.1
--- LITTLECMS2 support ok, loaded 2.17
--- WEBP support ok, loaded 1.6.0
--- AVIF support ok, loaded 1.3.0
--- JPEG support ok, compiled for libjpeg-turbo 3.1.3
--- OPENJPEG (JPEG2000) support ok, loaded 2.5.4
--- ZLIB (PNG/ZIP) support ok, loaded 1.3.1.zlib-ng, compiled for zlib-ng 2.3.2
--- LIBTIFF support ok, loaded 4.7.1
*** RAQM (Bidirectional Text) support not installed
*** LIBIMAGEQUANT (Quantization method) support not installed
*** XCB (X protocol) support not installed
--------------------------------------------------------------------

Followup:
I noticed 2 to be implemented dithering options. any timeline for those?
also, hitherdither implements all of it already but is slower than Pillow. it may be a good reference though.

Activity

  1. changed the title [-]Please add jarvis-judice-ninke dithering[/-] [+]Jarvis-judice-ninke dithering[/+] on May 7, 2026
  2. radarhere commented on May 7, 2026

    @radarhere
    Member

    I noticed 2 to be implemented dithering options. any timeline for those?

    What are you referring to? #9339?

  3. jmerc77 commented on May 7, 2026

    @jmerc77
    Author
  4. akx commented on Jul 29, 2026

    @akx
    Contributor

    I've been arm-deep in the dithering code with #9829 yesterday and today -- adding Jarvis-Judice-Ninke shouldn't be too difficult.

  5. radarhere commented on Oct 21, 2026

    @radarhere
    Member

    #10265 has been created.

    Not yet implemented dithering

    Oh, right, these two options.

    Pillow/src/PIL/Image.py

    Lines 171 to 172 in a6e738c

    ORDERED = 1 # Not yet implemented
    RASTERIZE = 2 # Not yet implemented

    No, there are no current plans. Those options have been like that since Pillow was forked from PIL.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions