diff --git a/README.md b/README.md index ba1a2e6..c2160f6 100644 --- a/README.md +++ b/README.md @@ -2,10 +2,20 @@ An online version of this tool is live at [http://javl.github.io/image2cpp/](http://javl.github.io/image2cpp/) +image2cpp is a simple tool to convert images into byte arrays (and vice versa) for use with small (monochrome) displays such as OLEDs on your Arduino or ESP. Alternatively you can also enter a byte array as input to turn it back into an image. This can be useful for debugging to when you want to recover an image from your source code. -image2cpp is a simple tool to convert images into byte arrays (and vice versa) for use with (monochrome) displays suchs as OLEDs, like those from Adafruit or Sparkfun. While searching for a way to generate these arrays, I mostly found links to a piece of Windows software. Both the flakey results and the hassle of having to boot a virtual machine just to convert an image lead to me writing this pure html + javascript solution. +Since this is a pure HTML + Javascript tool it works in any browser on Windows, MacOS and Linux. Use the link above for an online version that's ready to go, or download the code and simply open `index.html` in your browser. All processing is done in your browser, so nothing is uploaded, read or stored on remote servers. -Alternatively you can also enter a byte array as input to turn it back into an image. This might be useful for debugging, or when you want to write the byte array yourself. I don't know. +### Features +* Import multiple images at once, all processed locally in your browser (again: nothing is uploaded). +* Draw modes: 1 bit per pixel (horizontal or vertical), 1 bit alpha map, 2 bytes per pixel (565), and 3 bytes per pixel (rgb888). +* Dithering: binary threshold, Bayer, Floyd-Steinberg, or Atkinson. +* Scaling, centering, inverting, rotating (0/90/180/270°) and flipping. +* Output formats: plain bytes, Arduino code (per image or a single combined bitmap), or an Adafruit `GFXbitmapFont`. +* Extra formatting options: comments, bit-swapping, custom byte prefix/separator, bytes-per-row wrapping, and an ascii-art preview in the output. +* Read an existing byte array back into an image, for debugging or checking your own hand-written arrays. +* Click any preview image to open it at actual size in a new tab. +* Light and dark mode. Did you find this tool useful? Feel free to support my open source software (especially when used commercially):