10-11-2017 03:38 AM
Hi to all.
I am developing an application which I use OCR.
What i do in the application is:
1- I use IMAQ match pattern 4 VI to find the text in the image inspection.
2- I get ROI where the text is in from the output boubding box of IMAQ match pattern 4.
3- Then I do OCR using IMAQ OCR read text 4.
Everything works fine if the image is not rotated but when the image is rotated IMAQ match pattern 4 works fine (it can find the text rotated in the image) but OCR does not work, it can not find any characters.
By the way I set "text detection" property OCR to true for rotated characters.
Another information is that if I put the ROI manually on the display then OCR works fine... so I think I am doing something wrong getting the ROI and passing it to OCR...
Anybody can help me?
This is the part of my code:
And this is what happens when the image inspection is not rotated:
Ant this when the image is rotated which pattern matchin can find the text but OCR does not work:
01-25-2018 03:30 AM
Any ideas?
Thanks a lot
01-25-2018 11:20 AM
While this doesn't directly answer your question, could you simply rotate the image prior to setting the ROI to ensure the text is horizontal?