Creating Glitch Graphics

I’m sure most programmers have accidentally created graphics glitches in the past – corrupt image files, incorrect texture maps, that sort of thing, and I’ve certainly encountered them many times as a games player… y’know, the sorts of things that make Lara Croft look like this:

tomb raider texture glitch

However, I’ve only just become familiar with intentional glitching of graphics data for artistic effect – so called glitch art.

You can see some great examples in the glitch art pool on Flikr, which no doubt the artists have spent some considerable time compositing and refining, but I thought I’d try out a much simply technique using nothing more than a hex editor (such as XVI32)

So, start with an image file (JPG/PNG/whatever – doesn’t really matter), load it up in a hex editor, and then search and replace some bytes with another set of random bytes. For example, try replacing the byte 5D with the byte D5:



Or, if you’re feeling a little more confident, try replacing the byte pair 97 5D with a text string, “NIGD”.



Or, try adding non-ASCII characters and replacing string of different lengths too, or add messages in to the file:



After each replacement, save as a new file and try to load it up in an image viewer. If you’re lucky, you might have generated an interesting glitch effect. If you’re unlucky, you might just have a corrupt image file, in which case revert back to the previous save and try something else.

It’s also worth noting that since PNG/BMP/JPG store byte data in different formats, you’ll get different effects from each, so try experimenting.

With a handful of random replacements, you can convert an image from:

Sucking finger DSC_0952

to the altogether more interesting…:


This entry was posted in Uncategorized and tagged . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s