image2cpp vs LCD Image Converter vs Online Tools 2026
There are a half-dozen tools for converting images into C/C++ byte arrays for embedded displays. Each has strengths. This post compares the five most popular options in 2026 — image2cpp, LCD Image Converter, the U8g2 bitmap tool, the LVGL online converter, and GIMP/ImageMagick scripts — and tells you which fits your workflow.
The five tools
| Tool | Type | Cost | Platform |
|---|---|---|---|
| image2cpp (this site) | Web app | Free | Browser |
| LCD Image Converter | Desktop GUI | Free / open source | Windows / macOS / Linux |
| U8g2 bitmap tool | Web app + CLI | Free | Browser / Python |
| LVGL online converter | Web app | Free | Browser |
| GIMP / ImageMagick scripts | CLI / scripted | Free | Cross-platform |
image2cpp (pixel.hjlabs.in)
What it does well:
- Browser-based — no install, your image never uploads to a server
- Live preview as you tweak threshold, dither, or invert
- Multiple output formats: Adafruit-compatible MSB, XBM (LSB), vertical, RGB565, raw bytes
- Batch mode — drop multiple PNGs, get one array per file
- Floyd–Steinberg, Atkinson, and ordered dithering
- Mobile-friendly UI (works on tablets at hackathons)
Weaknesses:
- No 4-bit grayscale or indexed palette output (yet)
- No CLI for build pipelines
- Newer LVGL formats not directly supported — export raw bytes and wrap manually
Best for: Arduino, ESP32, RP2040, MicroPython projects targeting OLED, mono e-paper, or RGB565 TFTs. Try it now.
LCD Image Converter (riuson)
Desktop application with a powerful template system. Open source on GitHub.
What it does well:
- Custom output templates — generate any text format you need
- Font conversion (not just images) — great for custom display fonts
- Built-in editor for pixel-perfect tweaks
- Batch CLI mode for build pipelines
Weaknesses:
- Heavy GUI, slower iteration than a web tool
- Linux build is community-maintained, sometimes lags
- Steeper learning curve — the template language takes effort
Best for: Production firmware projects with build pipelines, custom font work, anything needing precise per-pixel control.
U8g2 bitmap tool
The U8g2 library author maintains both an online tool and a Python script for generating XBM data optimized for U8g2's drawing model.
What it does well:
- Native U8g2 vertical-byte format (no manual flag-flipping)
- Tightly integrated with U8g2 docs and examples
- Python CLI for build automation
Weaknesses:
- U8g2-specific outputs — awkward for Adafruit_GFX or LVGL targets
- No color support (U8g2 itself is mono-focused)
- Less polished UI than image2cpp
Best for: Pure U8g2 projects (small AVR with page-mode rendering).
LVGL online converter
The official tool at lvgl.io/tools/imageconverter. Generates ready-to-use lv_img_dsc_t declarations.
What it does well:
- Zero-config struct output for LVGL
- Supports all LVGL color formats (CF_TRUE_COLOR, CF_TRUE_COLOR_ALPHA, CF_INDEXED_8BIT, etc)
- Versioned for LVGL v8 and v9
Weaknesses:
- LVGL-only output — not portable
- No dithering controls
- No batch mode
Best for: LVGL-only projects. We covered the full integration in our ESP-IDF LVGL image conversion post.
GIMP / ImageMagick CLI
For build-system integration, ImageMagick can convert any image to XBM or raw bytes:
# Mono XBM
convert input.png -resize 128x64 -monochrome output.xbm
# RGB565 raw bytes (with custom script)
convert input.png -resize 320x240 -depth 8 input.rgb
python3 rgb_to_rgb565.py input.rgb > image_data.h
GIMP can export XBM directly: File → Export As → .xbm.
What it does well:
- Scriptable — runs in any CI pipeline
- Universal — you already have ImageMagick installed
- Reproducible — check scripts into git, never click a UI again
Weaknesses:
- No live preview — iterate by re-running and checking visually
- RGB565 conversion needs a custom script (5-10 lines of Python)
- Dithering options exist but are less tuned than image2cpp's
Best for: Production teams with mature build pipelines, consistent asset processing across hundreds of images.
Side-by-side feature matrix
| Feature | image2cpp | LCD IC | U8g2 | LVGL | GIMP/ImageMagick |
|---|---|---|---|---|---|
| 1-bit mono | Yes | Yes | Yes | Yes | Yes |
| RGB565 | Yes | Yes | No | Yes | Script |
| 4-bit grayscale | No | Yes | No | Yes | Script |
| Indexed palette | No | Yes | No | Yes | Script |
| Floyd–Steinberg dither | Yes | Yes | Yes | No | Yes |
| Live preview | Yes | Yes | Yes | Yes | No |
| Batch mode | Yes | Yes | No | No | Yes |
| CLI / scriptable | No | Yes | Yes | No | Yes |
| No install needed | Yes | No | Yes | Yes | (needs MagickWand) |
| Privacy (client-side) | Yes | Local | ? | ? | Local |
Decision matrix by project type
| Your project | Recommended tool |
|---|---|
| Arduino + SSD1306 OLED, weekend project | image2cpp |
| ESP32 + ILI9341 RGB565 | image2cpp |
| U8g2 on ATtiny, page mode | U8g2 bitmap tool |
| LVGL on ESP-IDF | LVGL converter |
| Production firmware with CI build | LCD Image Converter or ImageMagick scripts |
| Custom font for OLED | LCD Image Converter |
| MicroPython framebuf | image2cpp (raw bytes mode) |
The original javl/image2cpp vs pixel.hjlabs.in
The OG javl/image2cpp on GitHub is great but ad-supported and has been minimally maintained for years. pixel.hjlabs.in is a fork with:
- Refreshed UI (mobile-friendly, dark mode)
- Zero ads
- Additional output formats (Waveshare 3-color e-paper, LVGL raw bytes)
- Faster iteration (smaller bundle, instant load)
- Active maintenance and feature requests welcome
Both are 100% client-side — your image never uploads to a server.
Privacy as a feature
For commercial projects, "your image never leaves the browser" is a real advantage. Some teams cannot legally upload product imagery to third-party servers. image2cpp, LCD Image Converter, and GIMP all process locally. The LVGL online converter and many casual web tools upload to a server — check before using.
Bottom line
For 80% of hobby projects, image2cpp is the fastest path: drop in a PNG, tweak, copy. For LVGL projects, use the LVGL converter. For production firmware with strict build pipelines, scripts win. For custom fonts, LCD Image Converter is unmatched. Try image2cpp now — if it fits your workflow, you're done.
Other hjLabs.in tools: og.hjlabs.in for project README graphics, fmt.hjlabs.in for JSON, enhance.hjlabs.in if your source PNG needs upscaling, compliance.hjlabs.in for DPDPA privacy policies, and for laser-cut enclosures.
Try image2cpp now — free, in browser
Drop in a PNG, JPG or BMP. Get a paste-ready C++ array for Arduino, ESP32 or RP2040. 100% client-side. Learn more about image2cpp or jump straight to the tool.
Open the converter →