How to get Trackable Name from NatNet client sample?

NatNet, VRPN, TrackD, and Plugins
Post Reply
pcdol
Posts: 7
Joined: Tue Feb 17, 2009 7:56 pm

How to get Trackable Name from NatNet client sample?

Post by pcdol » Mon Jun 22, 2009 1:42 am

below, code snippet from NatNet client sample

// Rigid Bodies
printf("Rigid Bodies [Count=%d]\n", data->nRigidBodies);
for(i=0; i nRigidBodies; i++)
{
printf("Rigid Body [ID=%d]\n", data->RigidBodies.ID);
printf("\tx\ty\tz\tqx\tqy\tqz\tqw\n");
printf("\t%3.2f\t%3.2f\t%3.2f\t%3.2f\t%3.2f\t%3.2f\t%3.2f\n",
data->RigidBodies.x,
data->RigidBodies.y,
data->RigidBodies.z,
data->RigidBodies.qx,
data->RigidBodies.qy,
data->RigidBodies.qz,
data->RigidBodies.qw);

printf("\tRigid body markers [Count=%d]\n", data->RigidBodies.nMarkers);
printf("\tx\ty\tz\n");
for(int iMarker=0; iMarker RigidBodies.nMarkers; iMarker++)
{
printf("\t%3.2f\t%3.2f\t%3.2f\n",
data->RigidBodies[i].Markers[iMarker][0],
data->RigidBodies[i].Markers[iMarker][1],
data->RigidBodies[i].Markers[iMarker][2]);
}
}

but, I can only get Rigid body(Trackable) ID(defined in Tracking Tools -> Trackable Settings).

I need also Rigid body Name(defined in Tracking Tools -> -> Trackable Settings)

How to get Rigid body Name from NatNet client sample?

morgan
NaturalPoint Employee
NaturalPoint Employee
Posts: 200
Joined: Tue Jun 24, 2008 2:01 pm
Location: Corvallis, OR, USA
Contact:

Re: How to get Trackable Name from NatNet client sample?

Post by morgan » Tue Jan 05, 2010 6:44 pm

NatNet version 2.0 and later now contain RigidBody names. Please refer to that latest code samples for more information.

Post Reply