Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying OpenCV for Secret Agents
  • Table Of Contents Toc
OpenCV for Secret Agents

OpenCV for Secret Agents

By : Joseph Howse
5 (5)
close
close
OpenCV for Secret Agents

OpenCV for Secret Agents

5 (5)
By: Joseph Howse

Overview of this book

This book is for programmers who want to expand their skills by building fun, smart, and useful systems with OpenCV. The projects are ideal in helping you to think creatively about the uses of computer vision, natural user interfaces, and ubiquitous computers (in your home, car, and hand).
Table of Contents (9 chapters)
close
close
8
Index

Tracking back and forth gestures


Several common gestures consist of a repetitive, back and forth movement. Consider the following examples of this type of gesture:

  • Nodding (yes or I'm listening)

  • Shaking one's head (no or dismay)

  • Waving (a greeting)

  • Shaking hands (a greeting)

  • Shaking one's fist (a threat or a protest)

  • Wagging a finger (scolding)

  • Wiggling a finger or fingers (beckoning)

  • Tapping one's foot against the ground (impatience)

  • Tapping four fingers against a table (impatience)

  • Tapping two fingers against a table ("Thanks for the green tea")

  • Pacing (anxiety)

  • Jumping up and down (excitement, joy)

To help us recognize such gestures, let's write a class, BackAndForthGesture, which keeps track of the number of times that a value (such as an x coordinate or a y coordinate) has oscillated between a low threshold and a high threshold. A certain number of oscillations can be considered as a complete gesture.

Create a file, src/BackAndForthGesture.java. As a member variable, BackAndForthGesture will store...

CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
OpenCV for Secret Agents
notes
bookmark Notes and Bookmarks search Search in title playlist Add to playlist download Download options font-size Font size

Change the font size

margin-width Margin width

Change margin width

day-mode Day/Sepia/Night Modes

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY

Submit Your Feedback

Modal Close icon
Modal Close icon
Modal Close icon