Jul
19
2016

Decode QRCode with ZXing.net + Unity

Simple example to decode QRCode from texture image.

– Download XZing.net from http://zxingnet.codeplex.com/
– Unzip, Copy zxing.unity.dll from Unity/ folder into your Unity project (create Plugins/ folder and place the dll there)
– Download some QRCode image, like: http://vrbox.in/wp-content/uploads/2015/11/QR-Code1.jpg
– Create new script (see source below)
– Attach script to empty gameobject
– Assign your QRCode texture into inputTexture field
– Hit Play!
– See console output:

  QR_CODE
  goo.gl/BF4kdV

 

Your Project window structure

xzing_unity

Source: ReadBarcodeFromFile.cs


Related Posts

About the Author:

.fi

3 Comments + Add Comment

Leave a comment

@unitycoder_com

Subscribe to Blog via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.