Skip to main content
gamedev.net
🔒 Locked

Using camera to determine tilt

Started by g0nzo Feb 2, 2007 at 7:01 AM 1 replies 900+ views
Original Post
g0nzo
g0nzo
Hi, Recently I've read that someone wrote a mobile game that can be controlled without using any keys, but (as you probably guessed already) using only built-in camera to determine tilt of the phone. Do you have any idea how it could be done (please remember that it should work on mobile phone, maybe pocket pc)? Is it even possible?
sevensevens
sevensevens
He may be using optical image flow. It's a algorithm that tries to determine how much each pixel (or block of pixels) has moved given only a starting image and a finished image (i.e. images taken 1 second apart). Take a look at OpenCV, its a GPL computer vision library.
g0nzo
g0nzo
Thanks!

Lucas-Kanade tracker implemented in OpenCV is exactly what I need. I'll try to create a basic app using this library (or its C# port - SharperCV) and later implement this algorithm by myself, because the libraries are just too big (~2mb).

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.