multiple user tracking returns same coordinator - issue

36 views
Skip to first unread message

Venugopal

unread,
Mar 5, 2012, 1:58:33 PM3/5/12
to OpenNI
Hi,

I tried to implement user tracking using Kinect device. Obviously I
was able to detect user tracking with hand positions and etc. But when
i try to track two user, openni always returns same coordination value
for both the user.

Here is my code.

foreach (KinectUser user in this.users)
{

this.UpdateSkeleton(user.Id);
}




private void UpdateSkeleton(int userId)
{
if (userId > 0)
{
try
{
SkeletonJointPosition headPosition =
this.UpdateJoint(userId, SkeletonJoint.Head);
this.users[userId - 1].Head.X =
headPosition.Position.X;
this.users[userId - 1].Head.Y =
headPosition.Position.Y;
this.users[userId - 1].Head.Z =
headPosition.Position.Z;
}
catch
{
}
}
}

both the head coordination are same. Am i doing anything wrong?.

Can you please someone suggest me the right way to predict two
skeleton with perfect coordination using openni with kinect device?

Thanks,
Venugopal.

Lior Cohen

unread,
Mar 6, 2012, 3:45:25 AM3/6/12
to openn...@googlegroups.com
Hi Venugopal,

You can simply have a look at the NiUserTracker OpenNI sample (or the C# equivalent: UserTracker.net) that draws on screen the joints of all the users in the scene.

Best Regards,
Lior Cohen

Hi,

Here is my code.

this.UpdateSkeleton(user.Id);
}

Thanks,
Venugopal.

--
You received this message because you are subscribed to the Google Groups "OpenNI" group.
To post to this group, send email to openn...@googlegroups.com.
To unsubscribe from this group, send email to openni-dev+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/openni-dev?hl=en.

Reply all
Reply to author
Forward
0 new messages