We are about to switch to a new forum software. Until then we have removed the registration on this forum.
Hi everyone! I'm complete beginner to processing, kinect and simpleopenni. I'm sorry for asking stupid question, but please help me :(
I tried to create a usercounter for many times for my program, since I'd like to base on the amount of the tracked user to switch my sketch between two function, yet it did't work at all. ( e.g usercount is 1-20 = function A; usercount is 21-29=switch to function B; usercount is 30-50= function A; ...)
if I count it by getting the number of userID or using kinect.getNumberOfUsers() , it only gets the current detecting user, and the count will go back to 0, or even -1 when the users is out of the scene map.
I'd like to have a user countor accumulating all the users instead of the current ones, what should i do?
I'm using simpleopenni 1.96, processing 2.1 and window sdk 1.8. (OS: window 7) Thank you so much!
Answers
When you make your own counter, name it
userCounter
Every time the internal counter changes from 0 to 1 increase
userCounter
I tried, but I kinda ruined it into keep increasing :S How can I make it to only add 1 at a time?
you want to achieve this:
You have to think of an idea to check this change, so that he doesn't count
userCounter
always up, but only if there has been a change.One idea:
make a variable
previousValueForCount = kinect.getNumberOfUsers() ;
at end of draw (I think).Now say
or
if(kinect.getNumberOfUsers() > 1
anduserCounter+=kinect.getNumberOfUsers()
Thank you!! Let me try!! Sincerely thanks Chrisir!!
Hi there!
I really have a big problem with skeleton tracking using SimpleOpenNI. I’m working on Windows 10 with Kinect v1 and SimpleOpenNI. Since two days I’m searching solution in internet, but there is no skeleton tracking code that will work in Processing 2.2.1. There is no errors, just plain white box instead of program… I'm using codes from 1. the book ,,Making this see" by Greg Borenstein, 2. trying examples from http://interactivemechanics.com/news/2015/10/kinect-with-processing/ (but I think it's for v2, not sure), 3. reading what to with the problem in this site http://urbanhonking.com/ideasfordozens/2011/02/16/skeleton-tracking-with-kinect-and-processing/ 4. or that one https://fivedots.coe.psu.ac.th/~ad/kinect/installation.html
I'm pretty sure, that I have installed SimpleOpenNI properly, with NITE and SensorKinect. Do you have any advice what is wrong? I would be very grateful for any advice.
@zgapiane -- please start your own new thread with a new title for your new question.