Search code examples
c#unity-game-enginemotion-detection

Get user inputs from the webcame for the game


I'm creating a simple game using Unity Studio which uses arrow keys to move the player. Now what I want to do is, use webcam as a movement detecting device and track user's movements and move the player according to them. (For example, when user move his hand to right, webcam can track it and move the player to the right...)

So, is this possible ? If so, what are the techniques APIs I should use for this...?

Thanks!


Solution

  • Have a look at OpenCV, it is being used a lot in the field of body and head tracking, and there's a unity plugin which implements it that might be useful.

    Video Demo