jit.openni: Remove background wall from the usermap generator shape
Hi folks and hi Dale :)
I am stuck with another problem with jit.openni. Whenever I get too close to a background wall, my usermap shape starts getting pixels from the wall behind me (see attached pic)
Are there any possibilities I can remove that background wall? Is there a function I should know about so that I may do this?
Thank you for looking into this!!
The only possible solution that comes to mind is trying to mask the usermap using the depthmap, cutting at the wall’s distance.
this should work:
----------begin_max5_patcher---------- 1411.3oc6Z00jaZCE8Y6eEpL8gjLa7fP.1zooy9PenuzeA6jwiLn0V6BRTPr woYx+8pO.LXC1XudcnSalIdGt5CN5bO5pKR5aSmXshukjaA9EvCfIS91zISz lTFlT97DqD71vXbttZVg7jDBSXcmoLAYqPaOhlKvrPRN3cTFHgHHY4uupVOl sdkpV1yrqrvYhb5eSTVgN0lYEITVLQneWvcF4EhJqUUMEKB2PYqWlQBElQfq imrm.HXf5OPGj9OKlYC9bYinQZvxW8zGcsZ.EFNQCEq+fD+BQPCwVpB+9zop etafbCi7EYOe.07DULimBtW9+OXcFiemNG+UVMlDeMkXF7pWyxDrHit05Nfk U8XtChxwwUQMdtZhB4GLCEH+ma+rkSvMktVSXVuZkxUjobgZsj6QUTdyOAG0 70PxJYlRpQ1HZL4E4rFJm0XLMwBml1v7jFMQwmOw0cj+c0lnLiIXsoLxKzp1 ipshyjCVgbjVjY.51E9VlBk9voUMslIVnG7HWkO.3aaqIDO6cbgzeuNjGad6 OHmrGbWiefsqXLO7YRTiIzR+TJgQYoYjbY.FrnDv0EGQdDWDKV1RP.m0Y4Oh CI813d8LSrVmQi3LEPZ0Zk4pW4C.nNJi52cCHcMX3zNZrLtnnHeENS4DVESZ HMkpdNOtcQ09c4jGLiJ0oRHZ.riccmRSRynLQqWDggk8wl7vLdbbqtxTxKcT RjTZDR9BMRroU.ZUIxpSSqbCV0bTDcMIWz1l.uNuskVKrzTy1LpPK6Gcgl1g HB4L4TBAPvAqnLb1WAuyF7QH38fWvwEx0fdjmARv4OKmL2rCNXcnCiv.aUTW QYLyganRaFtvFMySNIwSG0vt7mZYRuql0a3G6El9SOoyw2n7luWW1HFDzyZu QVOwpmTEutb99afWJUVI.mE+0Jux5LhTMmADavLfzCQ9qBbbtxK9mT1uKSf3 15qftJt0wGdk7UU8GZn9J2QruJljm2sqBu8GfqxQQsPS9JWsoUPO6g5pPiGW UUvupLtUNkjjaq+.Yqk5N9WI+ABZ5uxUVsOo+v4+l9iKgUg1vgxpvaKq15C. ZSp+zm.1VWUxpYIG7EAVsnjN3R3bsTuZg3fSQkNiFl7CRAf83hKWDzX1t46I NFWF7+b4o3xx43mlKWLZ3xTbFNQljtNaB4.3RXU62VV02Pm1mLv47wFqZRmV tfiq2HjWUekjlX8OEw5OZH1e8SoWBS571tdT4h5HS5wGgH8FMDIkAfiJMogI Mox5r3j4HMZHxeaTpHK+72SqHQiFhTNVuLI4EmYdIW4BWXRp7ThtKbiB1s8j wTVe6FmFdpx6lDy4EYgUhfxLaAsAZDIWPY0aX6C0Xdu5sgFE0duQMamXtZyI MaE7fb3mKhQCDwNiFDCGHh8FMH1afHFMZPr+.QbvnAwyGHhWLZP7hyPGCGEH N3LzwWCDC97zcVNyyO8wXtbUmcmpnLye0wtuzbZOMOq7y4LTklnIxtUueUtd m2IqJgDVnNT0UX15ievpAyabV8k6MUeG9L55e3yIj7b7ZxAm9b0mN8yvW+Q0 C6ilFDyX3De8CP+dXF+qOy7uZYExewfkUH+anrpbeN9wIqpXFCmLGdLYE5Ve 4XHLFEbuZn.z9ZjC3d4vKsPrLhjJ1jfSkgaqLQSjT7dlxTOaW+bdHgQVJ6Kd VSqOSjLFm0gok7LZ0Iczn3hbhtmqcap0RB4Elid24UeGU7G1cTY3OMzazR4Y 23a1JFjc2BA3v0A5l29CMLxh8WBtTbbXJjsxuoubzas.8gK5d3BtGHSGJdTI giFBbf2L3bJ1YOJ7sDNNng3s7uc3webwOH2QFdFB+rGnGNdLS926lpofxd2P s8tcZGdyz56VoIeOee5+.pa3LS. -----------end_max5_patcher-----------
Wow! It works great.
Thank you so much for your help. Your patch does wonders!
The only problem that remains is the fact that I wanted to put the kinect a bit higher than the position where it would create a perfect perpendicular in relation to the wall.
I mean if I put the kinect straight in the middle of the background wall (in relation to up and down, left and right), I can cut it out of the mask easily with your patch as it is perpendicular to the wall. But if I move it a bit higher and the perspective changes, I think I need to calculate something else and I don’t know exactly what. Or is it even possible? Any pointers?
Once again, thank you so much for your help!
OpenNI user recognition…well…its not as good as the Kinect SDK. If you are on windows, I recommend you switch to dp.kinect. The recognition is better *and* you can turn on automatic realtime reorientation of all the data based on gravity; its a cool feature I added several months back.
If stuck on Mac, the usermap is poor. Now much can be done about that. The depthmap you could also rotate pixel by pixel using rotation matricies, trig formulas, etc. See wikipedia for all the fun.
"rotation matricies, trig formulas, etc." That’s what I figured. ;))
Yeap, I know you made a better object for kinect, but, unfortunately, I am stuck on Mac. Still waiting for a OSX version, though.:D
I already created another post trying to figure out another thing related to data coming out of jit.openni (http://cycling74.com/forums/topic/filter-repetition-of-numbers-from-a-matrix/). But I am asking here as well just in case.
Any idea how I can get a list of all the users present? I don’t want to use the data coming from [skeletons, floor info output], but from the [usermap generator] output. I know I get a matrix with different numbers relating to the users being detected. What I wanted was a simple list, not the matrix. Any ideas how I can get that out of the object or how may I process the matrix? (I have a few ideas but I pretty much stuck – please check the link above).
Thank you all! And a big thank you to LSKA and Dale for the much needed info!
Using the usermap matrix to get users is costly. Scanning through 307200 integers is highly discouraged. Instead, use the data coming from the /user or /skel messages. The data they present will match the data in the usermap. Check this thread for suggestions http://cycling74.com/forums/topic/jit-openni-user-id-problems/
I doubt you’ll see Microsoft supporting Kinect on Osx anytime soon. They’re focused on Windows and Xbox. However, if they do, then I can port dp.kinect like I did with jit.openni.