Skip to content

Low level Tesseract C API wrapper for versions 3.05.02, 4.1.1 and 5.0.0

License

Notifications You must be signed in to change notification settings

egao1980/tesseract-capi

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tesseract-Capi - Tesseract C API wrapper

This system provides SWIG generated C API wrappers for Tesseract versions 3.05.02, 4.1.1, and 5.0.0. Using https://github.com/egao1980/swig/tree/revive-cffi as SWIG dropped CFFI support a while ago.

Usage

CL-USER> (ql:quickload :tesseract-capi)
To load "tesseract-capi":
  Load 1 ASDF system:
    tesseract-capi
; Loading "tesseract-capi"
...
(:TESSERACT-CAPI)
CL-USER> (tesseract-capi:tessversion)
"5.0.0-alpha-647-g4a00"

Installation

Preferred way of installing tesseract-capi is by using Ultralisp.org distribution.

;; install Ultralisp if you haven't done it yet
(ql-dist:install-dist "http://dist.ultralisp.org/"
                      :prompt nil)

;; install the wrapper code
(ql:quickload :tesseract-capi)

(let ((tesseract-capi:*tessdata-directory* "path/to/tessdata"))
           (tesseract-capi:image-to-text "tests/data/fox.png"))

"This is a lot of 12 point text to test the
ocr code and see if it works on all types
of fle format

The quick brown dog jumped over the
lazy fox. The quick brown dog jumped
over the lazy fox. The quick brown dog
jumped over the lazy fox. The quick
brown dog jumped over the lazy fox
"

Author

  • Nikolai Matiushev

Credits

Copyright

2020 Nikolai Matiushev 2015 Edward Geist (egeist@stanford.edu)

License

Licensed under the MIT License.

About

Low level Tesseract C API wrapper for versions 3.05.02, 4.1.1 and 5.0.0

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published