Scan recognition QR codeIdea: 1. Operate the camera and get pictures.HTML5WebRTC's Navigator.getusermedia method to get camera resources in real time. 2. Use the canvas to analyze the image recognition image using the relevant algorithm toanalyze the QR code with Jquery.qrcode. (Technical point: Getimagedata)
Limitations: Mobile platform supports Getusermedia/stream API less browser, support list http://caniuse.com/#feat =stream (currently no IOS is supported)
Code implementation: Thanks to GitHub, there is a ready-made algorithm 1. Https://github.com/LazarSoft/jsqrcode2. Https://github.com/dwa012/html5-qrcode Specific implementation code: Link: http://pan.baidu.com/s/1ntH1le5 Password: 7cic
generate two-dimensional codeSpecific code thanks to Github1. Https://github.com/LIGuoxiang/QRCode Link: http://pan.baidu.com/s/1kT8HHH1 Password: 6byh test with the QR code qsa2015-08-08 CCID2212553
otheriOS Alternative notes:Call the camera to take pictures and upload the images to the H5 page. And then in parsing. IOS version 8 Safari can use camera scan to enter credit card number http://36kr.com/p/212638.html
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.
HTML5 implementation of scan recognition QR code/generate QR code