How to Use WebGL to Accelerate Web Barcode Decoding Speed

Generally, while doing barcode detection, we pass color images encoded in RGB or YUV to some barcode decoding APIs, in which the image data will be converted from color to grayscale and then from grayscale to binary. Operating pixels takes much CPU time. To accelerate image processing, we can utilize GPU. Dynamsoft JavaScript barcode SDK is powerful for developing web barcode scanning apps, but it is designed for CPU only so far. In this article, I will show you how to use WebGL to convert color image to grayscale image in order to reduce the total CPU time cost when reading barcodes from camera video stream in web apps.

Read more