How to read or decode QR Code in Android without the use of any 3rd party app?

What are the best ways to read or decode QR Code in Android without the use of any 3rd party app. Suggest me any best API or source code which can be used for integrating in my own app.

Upvotes: 6

Views: 8825

Answers (2)

Algar
Algar

Reputation: 5984

Google has a barcode class included in the Google Play services under the namespace com.google.android.gms.vision.barcode. I'm using it myself in a production app and its just great! Its fast, robust and handles all from blurry to damaged codes.

Check out Android QR Code Reader Made Easy. This should get you up and running in no time! You can easily continue on the code base provided or equally easily integrate it in your existing project.

Upvotes: 4

Chris623
Chris623

Reputation: 2532

I would propose to use zxing library:

https://github.com/zxing/zxing

https://github.com/zxing/zxing/wiki/Getting-Started-Developing

You have two options:

  • just use the library which calls the zxing scanner intent (needs barcode reader to be installed)
  • import the whole zxing source into your project in order not to depend on 3rd party app installed. This is always recommanded if you don't want your user to install another app but it is not quite easy to import the sources into your project. Have a look at the documentation.

Upvotes: 2

Related Questions