# HCI/CprE/ComS 575: Homework #5

Your Name
`<Your Email>`

Video files are available on the class website and a tutorial on how to output videos can be found here.

If convenient, please make the video output format either H.264 (*.mp4) or Theora (*.ogg). This will allow for the videos to be embedded below, which will make the grading process easier. If you are having troubles with H.264, try downloading this DLL and placing it in the folder with the binary. Do not waste time on this. If you are unable to get these formats working within a few minutes, you are free to pick a different format or to let OpenCV pick its default.

FOURCC codes

    CV_FOURCC('H','2','6','4'); // For H.264
    CV_FOURCC('T','H','E','O'); // For Theora

## Part 1: Where is the ball?

### Part A

Write a program that tracks the position of the orange ball in the movies with two cups. Create an output video that shows the position of the ball even when it is under one of the cups. You can assume that once a ball is covered by a cup it will move in the same way as the cup. Your program must work with at least two of the sample movies.

#### Input

Your browser does not support HTML5 video. | Your browser does not support HTML5 video. | Your browser does not support HTML5 video.

#### Output

Your browser does not support HTML5 video. | Your browser does not support HTML5 video. | Your browser does not support HTML5 video.

Source File

### Part B

Do the same for the videos with three cups.

#### Input

Your browser does not support HTML5 video. | Your browser does not support HTML5 video. | Your browser does not support HTML5 video.

#### Output

Your browser does not support HTML5 video. | Your browser does not support HTML5 video. | Your browser does not support HTML5 video.

Source File

## Part 2: Color Tracking

### Part A

Use a screen capture program to record 3 videos of you playing your favorite game. Then write code that uses color tracking to track the position of some object(s) in these videos. Your code should produce 3 output videos that show the tracking information. Each video should be at least 15 seconds long.
Some screen capture software:
Camtasia (https://www.techsmith.com/camtasia.html)
Open Broadcaster Software (https://obsproject.com/ )

#### Input

Your browser does not support HTML5 video. | Your browser does not support HTML5 video. | Your browser does not support HTML5 video.

#### Output

Your browser does not support HTML5 video. | Your browser does not support HTML5 video. | Your browser does not support HTML5 video.

Source File