Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added PixelArtAddDitherPattern node. #12

Merged
merged 1 commit into from
Nov 3, 2023

Conversation

tsone
Copy link
Contributor

@tsone tsone commented Nov 3, 2023

Didn't hear from you right away so I implemented dithering as well, however through a new PixelArtAddDitherPattern node:

image

The node adds dither pattern to the image RGB values, so any color quantizer after the node achieves a dither look. It's modular and flexible, for example one could use the built-in Quantize node for dithering. The node also adds support for custom dither patterns (via input mask), and the classic 45-degree halftone pattern.

Here's manga'esque halftoning look using built-in Quantize node:
Elf_00039_

The amount option is a multiplier for the effect. Generally amount = 1 / num_colors is a good starting point.

Bayer pattern example:
ComfyUI_00001_

Blue noise (custom pattern):
ComfyUI_00002_

Game Boy Camera'esque look:
ComfyUI_00003_

(Blue noise mask image:)
blue-noise-16x16

(Workflows included in the images.)

@tsone tsone mentioned this pull request Nov 3, 2023
@dimtoneff dimtoneff self-assigned this Nov 3, 2023
@dimtoneff dimtoneff added the enhancement New feature or request label Nov 3, 2023
@dimtoneff
Copy link
Owner

Thanx :) it looks amazing! I will check it out and merge

@dimtoneff dimtoneff self-requested a review November 3, 2023 18:26
@dimtoneff dimtoneff merged commit 8a5eb75 into dimtoneff:main Nov 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants