Getting Text from Image on iOS (Image Processing)

Getting text from image on ios (image processing)

One of the main open source libraries used to do OCR on iOS is a google-sponsored open source project called tesseract.

Here is some info on compiling tesseract for use in iOS apps:

tesseract

The same guy has a nice sample project on github demonstrating how a simple client might use the compiled library:

Pocket-OCR

Getting text from a picture in iOS

I would look into this https://github.com/nolanbrown/Tesseract-iPhone-Demo and stack overflow has some posts about this already like Getting text from image on ios (image processing)

Searching an image for specified text

Here is a broad overview of the approach I would take:

  1. Find a C/C++ based OCR library
  2. Get it to compile on the iPhone
  3. Create a UI to feed images to the OCR library
  4. Store output of OCR, including words found and their location in the image.
  5. Create a UI to allow users to enter a search.
  6. Search OCR output for matches and highlight the location of matches on the image.

I imagine step 2 is going to be the most difficult. Tesseract may work, it is C++ based but I don't know what dependencies it has.

UPDATE: Someone on GitHub has posted a demo iPhone App that uses Tesseract.

Read text from image iPhone SDK

See this for how to do something quick on iOS with Tesseract. I doubt you will get the accuracy you want though. So far I haven't found a good opensource solution because the iPhone camera is not well suited to this problem. There are a few online API options that do better.

Oh and one word of advice, don't pay for anything without trying it in your situation :)



Related Topics



Leave a reply



Submit