This article was last modified on 25 November 2016.
OpenCV is the genius library capable of running everything you do on computer vision. Years ahead of everything else in robotics vision, you always have the latest version of important things like detection and tracking on whatever operating system you want – Linux, Windows, and Mac OS X.
Built on the idea to duplicate the human vision ability, a computer vision system uses electronic parts and algorithms instead eyes and brain. The Open Source Computer Vision Library (OpenCV) is the most used library in robotics to detect, track and understand the surrounding world captured by image sensors.
OpenCV is open-source for everyone who wants to add new functionalities.
Here are the installation guides to make OpenCV running on all the compatible operating systems.
New tutorials and resources:
Probably the best four books about OpenCV:
All these tutorials help you reduce the time on finding the best tutorial to detect and track objects with OpenCV. Because you can use the computer vision library on both computers and mobile devices, below are two lists of tutorials.
Let’s start with the first list:
Detect and Track Objects With OpenCV (computers)
These tutorials introduce you into the detection and tracking objects with OpenCV when you’re using computers.
- Ball Tracking / Detection using OpenCV – the author of this tutorial shows you how to detect and track a colored ball.
- Creating your own Haar Cascade OpenCV Python Tutorial – one object, two images. You can detect an object from an image into another image using what is called Haar Cascade.
- Tutorial: Real-Time Object Tracking Using OpenCV – in this tutorial, Kyle Hounslow shows you how to build a real-time application to track a ball.
- Pedestrian Detection OpenCV – how to detect and track humans in images and video streams. An application to detect and count pedestrian.
- Feature Matching with FLANN – how to perform a quick and efficient matching in OpenCV.
- SIFT: Introduction – a tutorial in seven parts. This is the first one where the author introduces you into the Scale Invariant Feature Transform (SIFT) algorithm.
- Scanning QR Codes (part 1) – one tutorial in two parts. In the first part, the author shows you what is the QR code. The second part is more technical and covers the code that identifies a QR code in any image.
- Using OpenCV and Akaze for Mobile App and Game Testing – in this tutorial, you can find how to make a mobile game testing application based on computer vision. The tutorial is based on the Accelerated-KAZE (AKAZE) algorithm and the OpenCV library.
- Light Detection OpenCV – here is how to detect the light.
- Detecting machine-readable zones in passport images – this tutorial shows you how to scan a passport using processing techniques such as thresholding, gradients, morphological operations, and contour properties.
- Skin Detection: A Step-by-Step Example using Python and OpenCV – here is how to detect skin in images using OpenCV.
- Cascade Classifier – CascadeClassifier is a library in OpenCV used to detect objects in a video stream.
- Object Detection & Tracking Using Color – in this example, the author explains how to use OpenCV to detect objects based on the differences of colors.
- Face Detection Using OpenCV – guide how to use OpenCV to detect a face in images with remarkable accuracy.
- SURF in OpenCV – tutorial how to use the SURF algorithm to detect key-points and descriptors in images.
- Introduction to Face Detection and Face Recognition – all about the face detection and recognition. This application is one of the most common in robotics and this tutorial shows you in steps how a face is detected and recognized from images.
- Find Objects with a Webcam – this tutorial shows you how to detect and track any object captured by the camera using a simple webcam mounted on a robot and the Simple Qt interface based on OpenCV.
- Features 2D + Homography to Find a Known Object – in this tutorial, the author uses two important functions from OpenCV. These two functions are ‘findHomography’ and ‘perspectiveTransform’. These two are used to find objects in images. The ‘findHomography’ is a function based on a technique called Key-point Matching. The ‘perspectiveTransform’ is an advanced class capable of mapping the points from an image.
- Back Projection – tutorial based on the ‘calcBackProject’ function to calculate the back project of the histogram.
- OpenCV Tutorials – Based on “Learning OpenCV – Computer Vision with the OpenCV Library” – these tutorials are useful for beginners as well as advanced users to start building applications in computer vision with OpenCV.
Tutorials to Detect and Track Objects (mobile devices)
Tons of robotics projects use iOS and Android devices to detect and track objects. All the below tutorials show you how to detect and track objects using mobile devices.
OpenCV Tutorial– tutorial to learn how to run the OpenCV on iPhone to process frames captured by the smartphone’s camera. A Complete iOS OpenCV Sample Project– this tutorial shows you how to use the OpenCV library on iPhone with Objective-C to process images. It can be a source of inspiration for robotic projects where an iPhone device is used for control and object detection.
- Encapsulate OpenCV 3.1 as Android AAR – do you want to solve Sudoku? Here is how to solve Sudoku using your Android smartphone, OpenCV, JavaFX and Scala.
- Using OpenCV on iPhone – face detection tutorial with OpenCV for iOS smartphone. In this tutorial, you have all the steps available to setup OpenCV as well as use the library for face detection.
Tutorial 1: Object Recognition With OpenCV and Android – Overview of Object Recognition– from this tutorial you can learn how to run the OpenCV library on an Android device and start building application for object tracking and detection.
- Developing OpenCV Computer Vision Apps for the Android Platform – resources to detect a face using Android device and OpenCV4Android. The OpenCV4Android is a custom library with support for Android devices.
- Get Started with OpenCV on Android – in this tutorial, the author shows you how to use an Android device and the OpenCV library for face detection and tracking.
- Using the EMGRobotics Robot Controller for Android – this tutorial shows you how to run the EMGRobotics and OpenCV on an Android smartphone to control a robot by face detection and tracking.
This list of resources includes OpenCV documentation, libraries, and compatible tools.