Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

This is working as designed. 256-gray images are not directly displayable within Decker, since Decker's color palette does not contain 256 colors and patterns; only 48:

 

A grayscale image must be converted into a proper paletted image before it can be displayed; otherwise the grayscale values are effectively randomly mapped to entries in the above table, and any higher indices appear as white. The image.transform["dither"] function is one way to produce a 1-bit dithered image from a 256-gray image, using Bill Atkinson's algorithm. Rescaling a dithered image will considerably reduce its quality. The correct order of operations to prepare a dithered image therefore must be:

  1. obtain or otherwise create a 256-gray image.
  2. perform any desired palette adjustments to the 256-gray image, like adjusting white/black points or contrast.
  3. scale and crop the 256-gray image to the desired final size.
  4. dither the 256-gray image, resulting in an image consisting exclusively of patterns 0/1.
(4 edits)

I was talking about this on cohost and millie also told me about Decker not being able to display the 256 grays which... makes complete sense tbh, as you yourself explained the palette limitation (which I actually know but didn't connect the dots, so I'm a bit embarrassed). Funny enough people liked the result, so I think I'll rename the option and leave it there for them to use and give life to fever dreams. 

And the order for the dithered image makes sense now, I'll rewrite its import code and see if I can get it right then. Thanks a lot!

Edit: the dithering improved a lot now!