OpenCV2 Computer Vision Application Programming Cookbook

OpenCV2 Computer Vision Application Programming Cookbook

Posted on 2011-07-22 by Jan Vantomme
Tags: opencv

3 / 5

A while ago I was contacted by the people of Packt Publishing to review the OpenCV 2 Computer Vision Application Cookbook by Robert Laganière. Now that's a long title for a book. I've used OpenCV on a few small projects so I decided to read the book and write a review for them.

The first problem I encountered was installing the OpenCV library. Apparently, you have to use CMake to do that. Since I'm a designer, I usually try to keep away from doing things like this. The book explains the process for Windows but I'm using Mac OS X. The IDE's used in the book are MS Visual Studio and Nokia QT. I installed Nokia QT, which also runs on the Mac but didn't like the environment. So I gave up.

Luckily for me, "openFrameworks": comes with OpenCV. I'm also more used to working with Xcode, so I decided to try some of the examples with the tools I know. The first chapter is really easy. You'll learn how to read an image with OpenCV and show it on the screen.

Chapter two is about manipulating pixels. You'll learn how you can access pixels and change their color values. There are some useful algorithms in this chapter. There is an algorithm to reduce colors in an image, an effect similar to the Posterize adjustment from Photoshop.

The author also gives you an insight in how histograms are created, how to detect edges, corners, circles, lines and angles. And a lot of things that are a little too technical for me. If you are an experienced programmer, you'll probably love the book. If you're only getting started with C++, this will be too difficult.

The last chapter was the most interesting for me: working with video. I usually use OpenCV with a webcam to do live tracking of blobs to create interactive installations. The book uses a video file that is read from the hard drive but the approach is basically the same. I wish the book would also cover things like face detection with OpenCV, but one can probably write a book on this feature alone.

More Information

Tweet this article