reski.nicoversity.com

Simple Object Detection using OpenCV

Within this workshop in the series Creative Coding with openFrameworks, we create an application that is capable of detecting objects and their color using a web cam or any other source of video input. In order to understand and follow the coding parts, some basics about images and pixels, color models, Computer Vision and OpenCV are explained and illustrated beforehand. Furthermore, we will have a look into addons in openFrameworks, commonly referred to as ofxAddons. The addon ofxOpenCv, based on the open source Computer Vision library OpenCV, will provide crucial functionalities for this coding project.

The source code (as well as complementary slides) for this openFrameworks application is online available via GitHub:

Demo: Application developed in this workshop

Workshop content in detail

  1. Basics:
    • Images and pixels
    • Color models (RGB, HSV, additive, subtractive)
    • Decimal and hexadecimal representation of colors
    • Computer Vision
    • OpenCV
  2. Accessing, reading and drawing video input from a camera
  3. Basic image processing using ofxOpenCv
  4. Detecting objects and visualising them accordingly
  5. Extracting the color of detected objects

Prerequisites

  • Attendance at Introduction to OF workshop
  • Nice to have: Understanding of the concept behind object-oriented programming (OOP), familiar with C++
 as well as being creative and having a vast imagination of what you want to do.