パッケージ、リポジトリ、アプリカテゴリを検索

GitHub リポジトリflutter-package/flutter_scan

flutter_scan

ウィジェットツリーでQRコードをスキャンし、画像からQRコードをデコードする

flutter_scan のプロジェクト画像
スター
81
フォーク
152
最終プッシュ(UTC)
2023/12/06
プロジェクト状態
公開中

元の README

以下は英語原文のスナップショットです。最新版は GitHub をご覧ください。

scan

scan

scan qrcode & barcode in widget tree.

decode qrcode & barcode image from path.

if you want to generate qrcode image, you should use qr_flutter

Features
  • use ScanView in widget tree to show scan view.
  • custom identifiable area.
  • decode qrcode from image path by Scan.parse.
prepare
ios

info.list

<key>NSCameraUsageDescription</key>
<string>Your Description</string>

<key>io.flutter.embedded_views_preview</key>
<string>YES</string>
android
<uses-permission android:name="android.permission.CAMERA" />

<application>
  <meta-data
    android:name="flutterEmbedding"
    android:value="2" />
</application>
scan: ^newest
import 'package:scan/scan.dart';
Usage
  • show scan view in widget tree
ScanController controller = ScanController();
String qrcode = 'Unknown';

Container(
  width: 250, // custom wrap size
  height: 250,
  child: ScanView(
    controller: controller,
// custom scan area, if set to 1.0, will scan full area
    scanAreaScale: .7,
    scanLineColor: Colors.green.shade400,
    onCapture: (data) {
      // do something
    },
  ),
),
  • you can use controller.resume() and controller.pause() resume/pause camera
controller.resume();
controller.pause();
  • get qrcode string from image path
String result = await Scan.parse(imagePath);
  • toggle flash light
controller.toggleTorchMode();
proguard-rules
-ignorewarnings
-keepattributes *Annotation*
-keepattributes Exceptions
-keepattributes InnerClasses
-keepattributes Signature
-keepattributes SourceFile,LineNumberTable
-keep class com.huawei.hianalytics.**{*;}
-keep class com.huawei.updatesdk.**{*;}
-keep class com.huawei.hms.**{*;}

License

MIT License

flutter-package GitHub avatar
GitHub 作者

flutter-package ↗

provider some flutter plugin package

言語JavaSwiftDartRubyObjective-C

カテゴリー

このリポジトリが公開するパッケージ

使用している依存関係

依存関係一覧 2 件

  • flutter{"sdk":"flutter"}
  • flutter_test開発用{"sdk":"flutter"}

プロジェクトに合うリポジトリを選ぶには?

用途で絞り込み、開発状況を比較し、採用前に元のリポジトリで要件を確認しましょう。

  1. 名前・作者・説明で検索し、技術トピックで絞り込みます。
  2. スター、フォーク、最近のプッシュを比較します。スターは関心の目安であり、品質の保証ではありません。
  3. 利用前に GitHub で README、ライセンス、Issues を確認します。

情報源と管理

“A repository is the most basic element of GitHub.”

GitHub Docs — About repositories ↗