Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Kinect + SFML  (Read 2656 times)

0 Members and 1 Guest are viewing this topic.

lion03

  • Newbie
  • *
  • Posts: 2
    • View Profile
Kinect + SFML
« on: June 14, 2013, 08:12:46 pm »
Hey all!

I just started working on SFML Kinect integration library
for now the only thing I have is a short demo video of
skeleton tracking and rgba image stream display.

I will post the code as soon as I reorganize it and put the scaffolding I wrote for the video into proper classes

http://www.youtube.com/watch?v=FLHXISffX9c

Mario

  • SFML Team
  • Hero Member
  • *****
  • Posts: 877
    • View Profile
Re: Kinect + SFML
« Reply #1 on: June 15, 2013, 11:28:06 am »
For demoing, I'd definitely add lines between the nodes being drawn. Also, seems like you got quite a jumpy knee. :)

Is there any interpolation happening or are we seeing raw input right now?

lion03

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: Kinect + SFML
« Reply #2 on: June 15, 2013, 12:41:11 pm »
For demoing, I'd definitely add lines between the nodes being drawn. Also, seems like you got quite a jumpy knee. :)

Is there any interpolation happening or are we seeing raw input right now?

Yes,  the kinect skeletal tracking system outputs x y z
Where  z is distance from the  sensor as values between  -1 and 1 that represent meters  from center of the sensor.
In the demo those values are being scaled to proper screen pixel coordinates.

Also the picture in the background is converted from the raw data that the  RGBA sensor captures to vertexArray.

About the right knee...
Le wild office chair appears! Kinect tries to use skeletal tracking system, it's not really effective :-P
« Last Edit: June 15, 2013, 12:47:30 pm by lion03 »

Mario

  • SFML Team
  • Hero Member
  • *****
  • Posts: 877
    • View Profile
Re: Kinect + SFML
« Reply #3 on: June 16, 2013, 11:29:44 am »
No worries, just thought it looks rather funny (especially considering it's so jumpy).

As for jumping, maybe you'd like to add some simple filter. Nothing complex, just something like "new = (old + new) / 2" for a start, unless that's happening anyway (see my initial question).

Too bad I don't have (physical) room for any real Kinect experiments. :(

Haikarainen

  • Hero Member
  • *****
  • Posts: 545
    • MSN Messenger - fredrik.haikarainen@gmail.com
    • View Profile
    • Email
Re: Kinect + SFML
« Reply #4 on: June 16, 2013, 02:54:19 pm »
I agree with mario, this is really really cool work but it could use some kind of layer between the raw input and the results, as it isn't "gameready" yet, also everyone using this code wont have to code it themselves everytime they use it.

I'd do something like:

if(newPos > oldPos + 0.5meter || newPos < oldPos - 0.5meter ){
   newPos = oldPos;
}

And just replace 0.5meter with a fine calibrated value (that doesn't limit the movementspeed of a human. 0.5 meters * 60 frames (if 60fps) = it can record movements up to 30 meters per second before compensating (also instant acceleration). Just keep this level above the limits of a humans capabilities and you're good to go.