barcode-scanner

How to reliably detect a barcode's 4 corners in real time video capture

血红的双手。 提交于 2020-12-15 05:29:15
问题 I found a Stackoverflow answer for detecting barcode in an image. I am trying to apply the method in the Stackoverflow answer to realtime video capture because my current solution only detect barcodes on clean large surface. How can I apply the method to video capture Here is my code. import cv2 import numpy as np from pyzbar.pyzbar import decode cap = cv2.VideoCapture(0) cap.set(3,640) cap.set(4,480) while True: success, img = cap.read() for barcode in decode(img): myData = barcode.data

How to reliably detect a barcode's 4 corners in real time video capture

送分小仙女□ 提交于 2020-12-15 05:26:37
问题 I found a Stackoverflow answer for detecting barcode in an image. I am trying to apply the method in the Stackoverflow answer to realtime video capture because my current solution only detect barcodes on clean large surface. How can I apply the method to video capture Here is my code. import cv2 import numpy as np from pyzbar.pyzbar import decode cap = cv2.VideoCapture(0) cap.set(3,640) cap.set(4,480) while True: success, img = cap.read() for barcode in decode(img): myData = barcode.data

How do I distinguish between a scanner input and keyboard input in Javascript?

我只是一个虾纸丫 提交于 2020-12-04 18:31:24
问题 I have gone through answers and came across two ways which can help in distinguishing between scanner and keyboard inputs. It can be done through: Time Based: Scanner inputs are faster than manual keyboard inputs. Prefix Based: Append a prefix to barcodes or scanners (inbuilt in scanner devices) and use it to identify the scanner inputs. Here are the links: link 1, link 2 which I have used for the references. The problem which I have run into is that whenever the user manually types some

Android barcode, onActivityResult not calling

流过昼夜 提交于 2020-11-25 03:56:48
问题 I am using Zxing barcode scan. Like most of the issues I am facing the same one. That It's not hitting the onActivityResult . I am using this tutorial Layout <LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:gravity="center_vertical" android:orientation="horizontal" android:padding="2dp"> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="left|center_vertical" android:text="Smart MSN #" />

Read HID input while window is “out of focus” in Python

主宰稳场 提交于 2020-08-07 07:03:32
问题 I'm struggling with an issue for some days and I can't get it working. I've just started with python and I'm now already facing the biggest problem which I will face in this project. Here's the situation: I have to make a program which scans a barcode. Communicates this to a online service and prints a PDF. This all works fine, but I also want to scan the barcode when the window is "out of focus". So I want to allow people to scan with the barcode scanner while they have the window minimized.

Read HID input while window is “out of focus” in Python

我的未来我决定 提交于 2020-08-07 07:02:44
问题 I'm struggling with an issue for some days and I can't get it working. I've just started with python and I'm now already facing the biggest problem which I will face in this project. Here's the situation: I have to make a program which scans a barcode. Communicates this to a online service and prints a PDF. This all works fine, but I also want to scan the barcode when the window is "out of focus". So I want to allow people to scan with the barcode scanner while they have the window minimized.