pdf_ocr_ondevice 1.4.0
pdf_ocr_ondevice: ^1.4.0 copied to clipboard
On-device OCR engine for dart_pdf_editor that adds a selectable, searchable text layer to scanned PDFs with a downloadable PP-OCR ONNX model.
Changelog #
1.4.0 #
- Version bump to align with
dart_pdf_editor1.4.0. Runtime maintenance keeps the on-device OCR package compatible with the 1.4.0 editor/app release.
1.3.2 #
- Version bump to align with
dart_pdf_editor1.3.2. No API changes since 1.3.1.
1.3.1 #
- Version bump to align with
dart_pdf_editor1.3.1. No API changes since 1.2.3.
1.2.3 #
- Added
PdfOcrDownloadCancelTokenso hosts can wire a Cancel button to in-flight model downloads; cancellation removes partial files and throwsPdfOcrModelDownloadCanceled. - Expanded the README download example to display file/overall progress and
show where to call
cancel(). - Fix on-device OCR failing on Windows with a garbled "Load model from … File
doesn't exist" error. The ONNX Runtime session is now created from the model
bytes (
OrtSession.fromBuffer) instead of a file path: on Windows the binding passed the path as a narrow UTF-8 string where ONNX Runtime expects a widewchar_t*, mangling every path - even pure-ASCII ones - into CJK mojibake. This supersedes the 1.2.2 ASCII path-staging workaround, which could not help because the corruption happened regardless of the path's contents.
1.2.2 #
- Fix on-device OCR model path staging on Windows so the downloaded PP-OCR ONNX model resolves correctly.
1.2.1 #
- Add a package example and shorten the pubspec description for pub.dev scoring.
1.2.0 #
- Downloadable on-device OCR package for the DartPDF app, with model-manager integration and native-platform OCR engine wiring.
- Version bump to align with
dart_pdf_editor1.2.0.
0.1.0 #
- Initial release. On-device, downloadable OCR for
dart_pdf_editor. PdfOcrModelManagerdownloads, caches (under the app-support directory), integrity-checks (SHA-256), and removes OCR model bundles, reporting progress as bytes arrive. Native platforms only (isSupportedis false on the web).OnDeviceOcrEngineimplementsPdfOcrEngine, mapping a backend's pixel-space text lines into PDF user space.PdfEditor.applyOcrwrites an invisible, selectable layer with no per-page network call.OnnxOcrModelRunnerruns a PP-OCR detect+recognize pipeline on ONNX Runtime (det resize/normalize, DB box extraction, CRNN/CTC decode), all of the pre/post-processing in pure, unit-tested Dart.PdfOcrModels.ppOcrV5Mobiledescribes the recommended lightweight model; point its file URLs at a bundle you host (see the README).