Page 1 of 1

QR code scanning library/external/widget?

Posted: Sat Aug 26, 2017 7:10 pm
by ClipArtGuy
Hi everyone, I was just wondering if there existed an open source solution for scanning QR codes in Android? I'm aware of some third party services, but would prefer to stay within LC if at all possible. Thanks in advance!

Re: QR code scanning library/external/widget?

Posted: Sun Aug 27, 2017 12:56 am
by [-hh]
.... Sorry, what I wrote here was wrong. I overlooked the word "scan".

Re: QR code scanning library/external/widget?

Posted: Sun Aug 27, 2017 8:36 am
by SparkOut
Hi Hermann,
This is a technique for creating QR codes, which can also be done without accessing the google api online by using the sqirt library now included with livecode.
The OP wants to scan qr codes into lc, which will still (I think) need an external app. I believe some people have made some efforts in this direction but not sure how successfully.

Re: QR code scanning library/external/widget?

Posted: Sun Sep 03, 2017 8:57 pm
by ClipArtGuy
Thanks for the replies HH and SparkOut. Just to be clear I am looking for a way to scan QR codes from within LC. If there isn't a widget,external or library that adds this functionality, I guess my only option is to use a third party API. Anybody have any recommendations to that end? Thanks in advance!

Re: QR code scanning library/external/widget?

Posted: Mon Sep 04, 2017 2:06 am
by [-hh]
I looked into that for a few hours. This will most probably work:

There is a port of the ZXing lib to javascript, see https://github.com/LazarSoft/jsqrcode
We could use that in a hidden browser widget.

The most difficult part is to use the snapshot from cam/webcam, not only from LC: One has to unskew/undistort the image --- or we have to wait until webkit/the browser widget (on Mac) can do a media access dialog and use the ZXing lib for that.
The decoding only from a 'proper' image is not this difficult.

p.s. For generating there is a very fast and high quality lib that produces also SVG:
https://www.nayuki.io/page/qr-code-generator-library