I am trying to detect the National ID of the below type and get the details of it, For example the location of the signature should be found at the top right corner of the persons image, in this case "BC".
I need to do this application in iphone. I thought of using Opencv for it but how can I achieve the marked details? Do I need to train the application with similar kind Cards or OCR could help?
Is there any specific implementations for mobile applications?
I also gone through card-io which detects the credit card details, does Card-io detects the other card details also?
Update:
I have used tesseract for text detection. Tesseract works good if the image has text alone. So I cropped the red marked regions and given as input to Tesseract, it works good with the MRZ part.
There is a IOS implementation for Tesseract, with which I have tested.
What I need to do?
Now I am trying to automate the text detection part. Now I am planning to automate the following items,
1) Cropping the Face ( I have done using Viola-jones face detector ).
2) Need to take the Initial in this example "BC" from the Photo.
3) Extracting/detecting the MRZ region from the ID card.
I am trying to do 2 & 3, Any ideas or code snippets would be great.
There is now the PassportEye library available for this purpose. It's not perfect, but works quite well in my experience: https://pypi.python.org/pypi/PassportEye/
Assuming these IDs are prepared according to a standard template having specific widths, heights, offsets, spacing etc., you can try a template based approach.
MRZ would be easy to detect. Once you detect it in the image, find the transformation that maps the MRZ in your template to it. When you know this transformation you can map any region on your template (for example, the photo of the individual) to the image and extract that region.
Below is a very simple program that follows a happy path. You will have to do more processing to locate the MRZ in general (for example, if there are perspective distortions or rotations). I prepared the template just by measuring the image, and it won't work for your case. I just wanted to convey the idea. Image was taken from wiki
Result: photo and surname regions in orange. MRZ in blue.
Card.io is designed specifically for embossed credit cards. It won't work for this use case.