Ask Your Question

read display numbers - distortion and rotation?

asked 2014-07-18 06:04:10 -0600

Klee gravatar image

updated 2014-07-18 06:07:07 -0600

I want to read the numbers on a display using a web cam. The picture might be distorted and rotated (it would make my setup much easier if I could allow for arbitrary rotation of the display with respect to the camera). I can put some coloured marks next to the display for orientation.

My idea is, that it must be quite simple to find the red dots at the two top coners of my display and the two yellow dots at the bottom corners of my display and then distort the picture so that I get a nice rectangle.

I guess, opencv offers the right functions to do this, so that I do not have to program it from scratch. But I am new to opencv. Can anyone, who knows opencv a bit better givve me some hints what functions to look at? Is there a function that distorts my picture when the coordinates of four pixels are given?

Or am I completely on the wrong track and is there a better way to read numbers from a lcd display?

Thank you in advance!

edit retag flag offensive close merge delete



... example image, please

berak gravatar imageberak ( 2014-07-18 06:09:36 -0600 )edit

1 answer

Sort by ยป oldest newest most voted

answered 2014-07-18 06:11:57 -0600

You need to find the Homography and use perspective transformation of your camera. Have a look at this tutorial, which is using keypoints instead of a kind of manual detection.

If you want to detected colored dot in corners, see the inRange function and/or the HoughCircle transformation.

edit flag offensive delete link more

Question Tools


Asked: 2014-07-18 06:04:10 -0600

Seen: 210 times

Last updated: Jul 18 '14