Skip to content
pubscout

google_mlkit_digital_ink_recognition

1.0.3, released 8 days ago by flutter-ml.dev

Flutter plugin for Google ML Kit Digital Ink Recognition

$ flutter pub add google_mlkit_digital_ink_recognition
Source repository

What it does

A plugin to recognize handwritten text on digital surfaces across hundreds of languages and classify sketches using Google's ML Kit. It passes calls via platform channels to native iOS and Android APIs.

AI-written summary of version 1.0.1, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You need to recognize handwritten text or shapes in a mobile Flutter app.
  • You want on-device machine learning processing for digital ink recognition.

Skip it when

  • You are building for web or desktop platforms, which are not supported.
  • You cannot meet the native requirements like iOS deployment target 15.0.

Strengths

  • Supports over 300 languages and shape/emoji classification models.
  • Runs natively on-device via Google's ML Kit APIs.

Weaknesses

  • Not supported on web or non-mobile platforms.
  • Requires manual native setup steps such as configuring iOS deployment targets and bundling model files.

Setup

Kind
Plugin (native code)
Effort
High
Code generation
No
Direct dependencies
1

Requires iOS deployment target 15.0+, Swift Package Manager setup, linker flags (-ObjC, -all_load), downloading MLKitDigitalInkRecognition_resource.bundle, and setting Android minSdkVersion 21+ and compileSdkVersion 36.

final digitalInkRecognizer = DigitalInkRecognizer(languageCode: languageCode);
final p1 = StrokePoint(x: x1, y: y1, t: DateTime.now().millisecondsSinceEpoch);
Stroke stroke1 = Stroke();
stroke1.points = [p1];
Ink ink = Ink();
ink.strokes = [stroke1];
final List<RecognitionCandidate> candidates = await digitalInkRecognizer.recognize(ink);
digitalInkRecognizer.close();

Alternatives

Packages that do the same job and could replace google_mlkit_digital_ink_recognition.

Works with

Packages commonly used together with google_mlkit_digital_ink_recognition: ones it builds on, ones built on it, and its own family.