I am building an e-ink-based auto-refreshing "newspaper" as wall decoration for my home. The e-ink panel I'm using supports 4-bit greyscale, i.e. 16 different levels of grey.
I am preparing the contents using LaTeX and would like to rasterize it to a 4-bit greyscale format using Ghostscript. Due to the relatively low DPI of the panel (~150ppi) I'd like to use anti-aliasing using the different grey levels.
Unfortunately I can't seem to find a suitable output device in the Ghostscript docs.
I have found:
- There's a 4-bit indexed color PNG output device, but I don't see how to set the palette
- There's
pnggray
, but it's 8-bit - There's a 4-bit X11 output device, but running a headless X server just to screencap the output in the end seems super convoluted
Am I missing an option?
If I can't do this using Ghostscript, what would be the highest-quality way to turn the 8-bit greyscale PNG output into 4-bit greyscale?