Convert PNG to XBM

Turn PNG images into XBM. An X11 bitmap in black and white only, written as C source text.

Converted in an isolated sandbox on our serversDeleted after 24 hours

Drop PNG files on the dialor turn it to pick what to do

A PNG as black and white C source.The result is an X11 bitmap, written as text in C.

  1. What you get

    One XBM file. It is an X11 bitmap in black and white only, written as C source text, so you can open it in a text editor as well as in programs that read XBM.

    XBM is a monochrome format. Every pixel in the result is either black or white.

  2. What it leaves behind

    Color does not carry over, because the bitmap holds only black and white. The result has no shades in between.

    PNG supports an alpha channel, and the XBM does not mention one. Do not expect transparency in the output.

  3. When it fails

    If the PNG cannot be parsed, the conversion stops with input_corrupted. No XBM is written in that case.

    To go the other way, use XBM to PNG.

PNG and XBM.What each format is.

The formats

From · PNG

PNG

Lossless raster images with an alpha channel. Screenshots, icons and graphics with sharp edges.

Extensions
.png
MIME type
image/png
Kind
Images
To · XBM

X BitMap

X BitMap, monochrome images as C source.

Extensions
.xbm
MIME type
image/x-xbitmap
Kind
Images

In your code.The same PNG to XBM conversion through the API, for your app or your agent.

terminal
$ cv convert photo.png photo.xbm
$ cv convert photo.png photo.xbm

Questions.What people ask about PNG to XBM.

01OF 04

XBM is X BitMap, a monochrome image format written as C source. The file is text, not binary data.

No. The output is black and white only.

The file could not be parsed. The conversion stops and produces no XBM.

Yes. XBM to PNG converts it back, though the result is black and white.

More conversions.Other ways in and out of PNG and XBM.