When trying to read the credit card information with OCR engine, I came to realize that the object in the image always has perspective distortion. Therefore we must perform perspective correction to the object before trying to read the text. And it turns out that this is a difficult task, although at first it looks simple.Read more…
There is an interesting post about writing webcam intruder alarm on the Wolfram blog. Basically it uses simple motion detection for detecting the intruder. The simple algorithm is very useful for learning the basics of motion detection so I ported the Mathematica code into C++. Read more…
This tutorial will show you how to count and segment connecting or overlapping objects. We will be using the Watershed algorithm and the distance transform functions. Read more…
When it comes to recognize text in image, the Tesseract OCR comes to mind. It is free and a good OCR machine. In this post I will show you how to use cv::Mat array with Tesseract API without producing temporary files for faster processing. Read more…
There is an interesting submission on File Exchange to solve mazes with simple morphological transformation. The Matlab script provides a good opportunity to learn some image processing basics so I decided to rewrite the script using OpenCV. Read more…
This is a fast eye detection and tracking program that takes the input from webcam. The program using OpenCV’s face detector for detecting the user’s face and eye. For tracking the user’s eye, it is using thetemplate matching method. Read more…
Inpainting is the process of reconstructing damaged parts of image. Starting from version 2.4, OpenCV supports the Inpainting algorithm. The function signature is given below. Read more…
When I came to the tutorial on how to detect simple shapes with AForge.NET I wonder how we can do it in OpenCV. Luckily in the OpenCV samples directory there is a program named squares.cpp which is a rectangle detector program. Let’s see how we can extend it to detect other shapes as well. Read more…
In this tutorial I will show you a simple algorithm for detecting pupil from an eye image using its characteristics: round black circle located in the center of the eye. The idea came from CodeProject which I improve the algorithm a little bit. Read more…