Type
Tool note
Status
Active public repo note
Published
2026-05-01
Version
v0.0.1
Canonical URL
https://shanecurry.com/lab/tools/chewgum-dithering-gun/
Repository
github.com/chewgumlabs/ChewGumDitheringGun/tree/v0.0.1
Live toy
Origin toy using Chew as the source image
Related project
ChewGum Animation

ChewGumDitheringGun v0.0.1 is a dependency-free browser dithering microscope. It loads a local image, samples it down to a square resolution, applies a palette and dithering rule, and exports the interpreted result as a PNG.

ditherImageData(imageData, options)
Runs nearest-color, ordered Bayer, Floyd-Steinberg, or Atkinson dithering on ImageData-shaped input.
getPalette(name)
Returns named palettes: 1-bit monochrome, Game Boy 4-color, NES RGB 64-color, or RGB cube 216-color.
sampleCanvasToImageData(source, size)
Samples an image or canvas source into a fixed square resolution before dithering.
drawPixelated(canvas, imageData)
Draws the reduced output back to a larger canvas with crisp pixel edges.
Browser microscope
A local example page with image drop, Gum sample autoload, resolution/palette/algorithm controls, and PNG export.
  • No upload service or storage.
  • No 3D model parser in v0.0.1.
  • No npm publication claim; this page only claims the GitHub repository and tag.
  • No exact console hardware emulation claim.
  • No reuse license for the Gum demo image beyond the demo scope described in the repo.

The tool exists because Dithering Heights made the reusable part obvious. The live toy uses a 3D Chew model as the source, but the extractable contract is smaller: turn any source image into constrained pixels, compare palette choices, and export the result.

This is dependency-free ESM with no build step. The public install path for v0.0.1 is GitHub.

npm install github:chewgumlabs/ChewGumDitheringGun#v0.0.1
import {
  ditherImageData,
  getPalette
} from '@chewgum/dithering-gun';

The package name appears in the source metadata, but the public claim here is limited to the GitHub repository and tag.

The browser example includes a flat Gum image so the microscope has something to show immediately. The code is MIT; the Gum image is a demo asset for viewing, testing, local demo use, and screenshots of the demo output. It is not licensed for reuse in games, animation, tools, resale, asset packs, or extraction into other projects.

Shane Curry / ChewGum Labs, "ChewGumDitheringGun v0.0.1," https://shanecurry.com/lab/tools/chewgum-dithering-gun/, published 2026-05-01.