Barcode Scanner

The Vuforia Barcode Scanner lets you detect and read a range of barcode and QR-code types with handheld devices and eyewear devices. Scan and automatically read multiple barcodes at the same time and make product identification fast and easy. Bring together the digital and physical with Barcode Scanning.

Barcodes

The Vuforia Engine Barcode Scanner is specialized to identify and read 1D and 2D barcodes using the Vuforia Engine computer vision technology. The feature lets you detect and read a single or multiple barcodes simultaneously.

Reading serial numbers

In assembly and maintenance scenarios, a frequent requirement is to identify the exact machine being worked on for reporting purposes, or to get more information about the machine. When scanning a barcode, your app can fetch instructions for the correct configuration or connect to the machine to get real-time IoT (Internet of Things) data. This is just one example where scanning codes can accelerate the process by avoiding users having to manually type in serial numbers or product codes.

Handover from desktop to mobile devices

2D codes such as DataMatrix or QR-Code can contain rich information like full URLs or structured data. By showing a QR-Code on the screen and scanning it in a mobile app, you can easily start a particular AR experience or log in users into a system without requiring manual input. This is particularly helpful on eyewear devices where any kind of text input is tedious.

Supported barcode types

1-dimensional barcodes are frequently used to represent information that does not require a high data capacity, such as products’ identification codes or serial numbers. Vuforia Engine supports the following code types often used in retail, logistics and industrial applications:

  • UPC-A
  • UPC-E
  • EAN-8
  • EAN-13
  • Code 39
  • Code 93
  • Code 128
  • Codabar
  • ITF

2-dimensional codes capture higher amounts of data and can be used to store more complex information such as URLs or shipping instructions, while also providing better error correction capabilities. Vuforia Engine supports the following types of 2D codes:

  • QR-Code
  • DataMatrix
  • Aztec
  • PDF417
  • Micro QR Code

Limitations

Unlike other Vuforia features, Barcode coordinates are provided in 2D camera/screen space only. This is not sufficient to display spatially aligned 3D objects on top of barcodes but can be used to display 2D boxes over the codes. If both unique identification and accurate 3D alignment are required, please consider using VuMarks.

On eyewear devices, the 2D positions of barcodes are without depth in camera space and prevent drawing an outline around the barcode as a visual indicator or doing any type of interaction – like tapping. To work around this, you can filter the barcodes by their content types, regular expressions, or present the list of detected barcodes in a UI component from which users can select from.

Licensing

Unrestricted usage of barcode detection is included in all Premium plans. The Basic plan allows for developer evaluation only. See the Pricing page for more information.

Create a Barcode Scanner

To get started with Vuforia’s Barcode feature, first consider if your use case fit the requirements for successful detection, scanning, and barcode reading. Please see Best Practices for Barcode Scanning to learn more about barcodes and its capabilities.

Another great place to start is the Vuforia Core Samples for Unity where a Barcode scene is available for demonstrating the Barcode feature and can serve as a starting point of your own application. See Barcode in Unity for setup instructions.

Use the Barcode API to configure the types of barcodes that you will use. Use the API to retrieve a barcode’s instance information such as its payload and its coordinates. See Barcode Native API Overview for details.

Advanced Topics

Optimizing Barcode scanning

Barcode scanning is dependent on high quality camera images and favorable lighting conditions. To improve the detection range, we recommend choosing the highest possible camera resolution. In Vuforia Engine, this is generally achieved by choosing the MODE_OPTIMIZE_QUALITY camera mode preset.

For detection of barcodes at short distance, the camera focus mode is essential and should be set to CONTINUOUSAUTO or MACRO, depending on availability.

See Device Performance Optimization for details on setting camera resolutions and focus modes.

Disambiguating Spatial Locations

Use barcodes to aid in relocalization for Area Targets. Large Area Targets may have difficulties localizing to the correct location, especially when repetitive structures are present in the environment. Pointing the camera at a unique QR code in a space and providing its location as an external location prior to the Area Target can aid the localization process and detection reliability. See Location Prior for Large Area Targets for details.

Can this page be better?
Share your feedback via our issue tracker