Decorating a QR Code – Part Two

After dealing in previous post with neutral (non damaging QR code data) decorative means, we are going to look at more aggressive means and learn their possible effect. We will try to estimate their damage amount and ways to control it in order to create decorated QR codes that are still decodable.

Pattern colored QR codes

A more aggressive way (in terms of QR code readability) to color a QR code, is to use a pattern as a color. This effect can be achieved by using the bucket tool and painting the QR code with a pattern instead of a simple color (in Photoshop for example). When painting with a pattern use the Medium EC level and above. Here is an example of such a QR code created in this manner with a grass pattern (created from an image) in Photoshop. The QR code EC level in this example is Medium.

The problem with pattern coloring is the contrast between the elements in the pattern. Readers must in some point decide which module is bright and which module is dark. To simplify this we can imagine a black and white QR code somehow created from the original colored image. The contrast play in pattern elements might create white spots in dark modules in this final decision image of the reader. Here are two possible black and white interpretations that readers may face in trying to decode the image above.

As you can see the main problem is the white stripe in the upper right finder patterns. The following readers were able to read the original colored QR code on an iPhone.
NeoReader, Scanlife,MobileTag,RedLaser,Scanit,Qr scanner, Optiscan, BeeTagg, i-nigma, QuickMark,Qrafter,and Scan.

Only Qr Reader for iPhone failed to read the original code. After correcting the contrast in the upper right finding pattern in the right image below, all readers including QR Reader for iPhone were able to decode the QR code.

Original image                              Corrected image

What can we learn from this? First thing is that most scanners can handle the contrast level in the pattern at the left QR code above. Secondly – look for areas in the pattern that might be too bright in the QR code finder patterns and try to lower the contrast in these areas. The finder patterns are sensitive since readers must find them clearly as a first step in decoding. Third thing is to look at other areas in the QR code, if there is a suspect for too much brightness, consider changing the pattern or lowering the contrast in the original pattern.

Hiding the QR code

Using patterns for coloring QR codes can easily create a QR code which is hard to detect for a human eye but is easily detectable by a machine. Here are some examples – the first from Set-Japan ( a company that created really nice decorated QR codes.

To my surprise this QR code is detected by almost all QR code readers in the market when you are close enough to the image.

Using a pattern that our brain is trained to recognize like bars or circles in a QR code will make the QR code even more difficult to detect. Here are two examples I created using bars and circles.

I used for this example a QR code with high EC but I am afraid I did this only because it looks hard to detect in our human eyes. As it appears it would be totally detectable also in a low EC, since once the background is detected from the foreground the QR code data is fully available here.

So – which readers were able to read these ones? Here is the list
i-nigma, scanlife, RedLaser and ScanIt.
Almost all other readers decoded only the left QR code above. The reason for failing the right one for most readers is not the pattern or the ability to detect the QR code. The same QR code painted with red (instead of yellow) was read successfully by all readers on an iPhone that decoded the green QR code above.

Combining effects on QR codes

The QR code below is a result of applying a ripple distortion on a regular QR code. Although it is much obvious to human than the hidden QR codes above, it is harder for the machine to decode it. Actually the rippled QR code needed the Reed-Solomon error correction since two codewords were corrupted in the rippled QR code, while none of the codewords was corrupted in any of the hidden QR codes above.

Here is a combination of ripple and the green bars

Complicated as it might be seen almost all readers reads this code and the damage made to the data is very small – only 2 codewords were damaged out of 22 possible for a QR code version 3 high EC.

Applying a decorative means that damages X codewords on a QR code over a decorative means that does not hurt the data at all, will usually end by a damage of X codewords as happened above.

However applying a decorative mean that damages X codewords upon one that damages Y codewords will not always end by damaging X+Y. codewords. Here is an example.

Spherical QR code – 2 codewords corrupted

Rippled QR code – only 2 codewords were corrupted.

Spherical and rippled – only 2 codewords corrupted

About these ads

About eismann oreilly

Recently bumped into QR codes, that ignited my imagination. The more I learn about them the more potential and possibilities are unveiled. With some help from your imagination we may find ourselves in a new world...
This entry was posted in color QR codes, designed QR codes, error correction, hidden QR codes, pattern coloring QR codes, QR codes, QR codes contrast, QR codes readers and tagged , , , , , , , . Bookmark the permalink.

4 Responses to Decorating a QR Code – Part Two

  1. Matthias says:

    Opps…we must not have the same Lynkee version (tested with Lynkee 2 on iPhone 4G) since I replaced Neoreader and after Scanlife because of its better scanning and features. Thanks for your post BTW.

    • Thanks Matthias, After some trials I was able to decode the grass pattern QR code with Lynkee – so we might have the same version after all :-). I corrected the post accordingly. I know that Lynkee is a good QR code scanner, my experience shows that no matter how good is the reader there are always images that will cause this or the other to fail – although readers are really improving with time. Thanks for your feedback.

  2. Wesley Black says:

    I use Bakodo for iphone. It’s a free app that works very well. I didn’t see mention of it in your posts.
    Great posts by the way! keep up the good work!

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 )

Google+ photo

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

Connecting to %s