# Image to BIN

> Image to BIN turns a picture into raw pixel bytes in a .bin file for microcontrollers, small LCD and OLED displays, e-paper panels and game projects.

Page: https://ishowpdf.com/tools/image-to-bin

## What Image to BIN does

Image to BIN turns a picture into raw pixel bytes in a .bin file for microcontrollers, small LCD and OLED displays, e-paper panels and game projects. It saves you writing a conversion script for each graphic.

Pixel formats are RGB565 (16-bit), RGB888 (24-bit), RGBA8888 (32-bit), 8-bit grey and 1-bit black and white. RGB565 is written little-endian unless you tick big-endian. The 1-bit format packs 8 pixels per byte, most significant bit first, with each row padded to a whole byte. You can set a width and the height follows the picture's shape. The file name records the size and format.

## How to use Image to BIN

1. **Add a picture**: Choose the logo, icon or screen graphic you want to show.
2. **Choose the pixel format**: Match your display driver, for example RGB565 for many small colour TFTs.
3. **Set width and byte order**: Enter your screen's width in pixels and tick big-endian if your driver expects it.
4. **Download the .bin**: Load the file onto your device or include it in your project.

## Questions

**How do I convert an image to RGB565?**

Add the picture, keep RGB565 as the pixel format, set the width your screen uses and download the .bin file.

**Does the .bin file have a header?**

No. It holds only the pixel bytes, row by row from the top-left, so your code needs to know the width and height from the file name.

**How is the 1-bit black and white threshold chosen?**

Pixels brighter than middle grey become 1 and darker ones become 0.

More free tools: https://ishowpdf.com/tools
