ngx-scanner icon indicating copy to clipboard operation
ngx-scanner copied to clipboard

Poor Perfermance with angular 6

Open smarzouki opened this issue 3 years ago • 4 comments

the place where i work have an app developed in angular 6. We use ngx-scanner to scan some Barcode: Code 128, QRCode, DataMatrix, Code39 it takes a long time to recognize the Barcode specially DataMatrix and QRCode. I tried an app developed by ZXing team from the Playstore. the app does not seem to be slow and it have a high recognition rate. Is this normal that the library ngx-scanner is slow ?? what can i do the improve it ? the option tryHarder didn't make it better.

smarzouki avatar Oct 01 '20 11:10 smarzouki

Well, a native zxing is always faster than the browser version. How long does the recognition take?

werthdavid avatar Oct 08 '20 19:10 werthdavid

Have you tried the input-parameter "timeBetweenScans"?

werthdavid avatar Oct 13 '20 13:10 werthdavid

Hallo @werthdavid the problem is that it often does not recognize the code. i use use the library to scan QR, DtaMatrix and 39 Barcodes. Often when the Picture of the Code is a litte small it does not recognize it and when i then try to scan another Codewhich is bigger, it does not recognize it. If i restart my site and scan the same big Code it recognizes it. The Lib has always Problems with small Codes, even when i gave the zxing-Component a bigger resolution in my CSS File. how can i modify "timeBetweenScans"?

smarzouki avatar Oct 13 '20 16:10 smarzouki

even when i gave the zxing-Component a bigger resolution in my CSS File.

This does not affects the scan at all. To be able to improve the video stream quality we need to apply some constraints to the MediaStreamTrack, which is an API that's not available at the moment on our libs.

how can i modify "timeBetweenScans"

The scanner has a property called timeBetweenScans where you can pass custom int values and delayBetweenScanSuccess for changing the time delay after a scan success.

odahcam avatar Oct 26 '20 19:10 odahcam