Question

I'm entirely new to Windows 8.1 and Optical Character Recognition, so I admit this is pretty much a beginner's area for me. I've been looking to implement OCR in my Win8.1 app, and have found this nifty Bing OCR Control. Unfortunately, unlike the CameraCaptureUI, this OcrControl doesn't seem to recognise my webcam; in fact one of its hardware requirements is "a built in rear facing camera that supports 1280x720 or 640x480 resolution in photo mode".

My first question is this: is there any way to circumvent this? For example, change the OcrControl's settings or Win8.1 emulator's settings.

If there's no hacky way around this (or if you haven't tried OcrControl previously), then my second question would be: would OCR be more feasible done locally or done by calling a web service? I would be going the extra mile if I were to ask to list some .NET libraries suitable for my use--I think that's going to be the easy part!

Anyhow, my requirements for OCR is simple: just read the text from a piece of paper and convert it to a string or whatnot. Thank you very much!

Was it helpful?

Solution

I have not used OcrControl control, but I have a few comments.

First, if OcrControl requires "camera that supports 1280x720 or 640x480 resolution in photo mode", I can tell from my own testing on iPhone and Android mobile cameras that images from those two resolutions are almost not usable for OCR, unless you are picturing something very small (business card or smaller) in a very good lighting. This resolution is definitely not sufficient for typical page-size pictures. Maybe will work if your pages have a very large font, such as 20 points or larger. My testing is based on 'video' frame resolution of 720p, same as as required here. If you absolutely must use these resolutions, I suggest picture post-processing and artificially increasing resolution.

You have an abundant choice of OCR libraries. Free libraries are definitely available and are mentioned in various posts many times, just look at other OCR-related posts on SO. Paid libraries will be more powerful, more feature-rich, tolerant to image distortions, and provide higher quality of text from lower quality images. Web-based API is a good option if you need access from cross-platform devices, and your volumes are low or unpredictable (usually pay per page). Also good option if you prefer not to host your own servers. Licensed software on backend server is a good choice if your volume is larger (lower cost per page), but it requires in-advance software licensing, server maintenance, etc.

Whichever system you choose, image preprocessing will be your best friend, especially if you can fine-tune cleanup for your specific camera models or image taking style of your users. Prep images for OCR, prep them for machine processing, which means the best image for machine is not necessarily the image that looks best to your human eye. For example, feeding a clean barbarized image to OCR will yield better results than some raw color image before preprocessing, even though B&W will look not as good to you and me. This is supported by "garbage in - garbage out" concept, and today we can't rely on mobile cameras yet to provide good enough quality out-of-box, so try to make your images as nice as possible. In case of mobie devices, every user will also introduce human element into each picture (shake, low lighting, distortions, etc.), which may also be corrected in post-processing. I co-wrote a few articles on image cleanup and preparation for OCR here: http://www.ocr-it.com/ocr-api-in-the-cloud-blog

Disclaimer. I speak from 15 years of OCR integration experience. I was the lead developer of the OCR-IT Cloud API, primarily for mobile-based image processing as on-device OCR was weak, and much more horsepower was available on backend servers. I also implemented numerous installations of conventional Windows-based server-based OCR systems for clients, mostly using ABBYY server-based products. I also co-developed a few iPhone/Android apps oriented around digital camera pictures. I am yet to develop on Windows Mobile platform - something that I look forward to when time permits.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top