Search packages, repositories and app categories

Package detailsv1.1.4

zxing_lib

A Dart port of zxing that encode and decode multiple 1D/2D barcodes, Supported qrcode, pdf417, oned, maxicode, datamatrix, aztec.

AndroidiOSWebmacOSWindowsLinux
30-day downloads
34.5K
Likes
27
Pub points
160

Install package

flutter pub add zxing_lib

Package Overview

Package selection guidance compiled from public package information, community data, and project usage.

zxing_lib is a Dart implementation of the ZXing barcode library, enabling encoding and decoding of various 1D and 2D barcodes such as QR Code, PDF417, DataMatrix, Aztec, MaxiCode, and OneD. It supports multiple platforms including Android, iOS, Web, macOS, Windows, and Linux. Designed for seamless integration into Flutter apps, it provides reliable, cross-platform barcode functionality without external dependencies. The package is ideal for applications requiring scanning or generating barcodes in diverse formats.

Use cases

  • Barcode scanning in mobile apps
  • Generating QR codes for sharing data
  • Processing PDF417 in document systems
  • Integrating barcode support in web applications
  • Reading DataMatrix codes in inventory systems
  • Creating Aztec-based ticketing systems

Key features

  • Supports multiple barcode types
  • Cross-platform compatibility
  • Lightweight Dart port
  • No native dependencies
  • High accuracy in decoding
  • Easy integration with Flutter

Suitable for

  • Flutter developers building barcode-enabled apps
  • Applications needing multi-format barcode support
  • Projects requiring offline barcode processing
  • Developers targeting multiple operating systems
  • Teams seeking a pure Dart solution

Considerations

  • Limited to supported barcode formats
  • Performance may vary on low-end devices
  • No real-time camera streaming included
  • Requires manual handling of image input
  • May need additional UI components for scanning
  • Not optimized for high-speed batch processing

Original README

Original README snapshot from the linked source repository. Visit the repository for the latest content.

ZXing-Dart

pub package

A Dart port of zxing that encode and decode multiple 1D/2D barcodes, Supported qrcode, pdf417, oned, maxicode, datamatrix, aztec.

ZXing Widget pub package
ZXing Scanner pub package

Why

  • Pure Dart implementation, no need to rely on native packages, good platform compatibility
  • Provide pure Dart encoding for all platforms
  • Provide pure Dart decoding for all platforms
  • Research learning and an exploration of Dart language

... At present, this package is far inferior to other native packages in decoding speed and accuracy, and can be used as a decoding tool and some platforms (such as Web and Desktop). I will also continue to pay attention to the improvement of zxing and the improvement of the performance problems in this project. And welcome suggestions for improvement from those with experience in decoding algorithms and image algorithms.

Feature

  • ✅ Core package translate

  • ✅ Core test translate

  • ✅ Core unit test(all passed)

  • ✅ Demo Creator

  • ✅ Demo Scanner (Decode from Captured picture or CameraImage from camera stream)

  • ✅ Code optimization

  • 🚧 Keep syncing from zxing java...

Preview

Demo App
01 02

Exception Type

  • IllegalArgumentException => ArgumentError
  • FormatException => FormatsException
  • IllegalStateException => StateError

Issue

  • Because there is no float type in dart, the results of some test cases are different from zxing

Flutter

This project is a starting point for a Dart package, a library module containing code that can be shared easily across multiple Flutter or Dart projects.

For help getting started with Flutter, view our online documentation, which offers tutorials, samples, guidance on mobile development, and a full API reference.

Categories

Dependencies

Dependency list 2 items

Source repository

Projects using this package