Kinect UI for 3D Pacman
3D Pacman
Attempt at the classic arcade game Pacman in a 3D, immersive virtual environment. Player plays as a first-person view navigating the maze while under hot pursuit from the Ghost. Models modelled in external 3D modeling software and loaded into the code as a .obj file, along with textures.
Project is incomplete:
Collision detection still buggy. It uses a simple 2D line intersection collision algorithm to test collision against walls. The program saves the vertices of the maze obj file and applies the same transformations to them, rids their z-values to create a 2D line map. Player's navigation history is stored as a x,y location and the vector between the current direction and the future direction creates a line segment that is used to test against the line map; if collision returns true the player's movement is prohibited.
So far the ghost also simply comes towards the player's current location, also disregarding walls. Texturing on the ghost also has a slight bug (eyes dont show).
Kinect UI
The main research was aimed to be gathering Kinect data and being able to implement a gesture controlled, device free user interface. Data from the Kinect is retrieved and managed by use of the open source library libfreenect by OpenNI / OpenKinect, which in turn uses libusb-1.0.
Currently the program uses a simple algorithm:
Using only the depth data retrieved form the Kinect's depth camera, we cut off all depth according to a tested threshold, so that anything beyond that distance is disregarded. The distance should correspond to just in front of the person so that basically only a raised arm would be seen.