Snake game and air drawing with Kinect
We used the Kinect and OpenCV to make two games for this project. The skeleton of the closest person is detected, we use his right hand coordinates to navigate the (very simple and intuitive) menus and to play.
The first game is Air drawing, below is the interface we created where the player can place his hand on the edge of the screen to select different colors and brush sizes, he validates his choice by holding his hand 2 seconds on the icon (a loading circle appears, selection happens when it’s full, the selected icon becomes less transparent).
The second game is Snake, like the one we played on our Nokia 3310 when we were teenagers! The interface is shown below, the main window is the game itself with the snake and the fruits or animals he has to get. The second window in the bottom right shows where the user’s hand is and what directions he has currently selected. At initialization the user sets the neural position by raising his right hand and holding it for 2 seconds, then he moves his hand relative to that position to tell the snake the direction to go.
We added four game themes, the snake color and objects will change between those.