ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
Here are a few snippets from the code I use. I can get you the entire package if you want, but there is alot of other stuff going on that might be confusing. I call SaveCalibration after a user calibrates during the user calibrated callback function. It creates the UserCalibration.bin file:
void SaveCalibration() { XnUserID aUserIDs[20] = {0}; XnUInt16 nUsers = 20; g_UserGenerator.GetUsers(aUserIDs, nUsers); for (int i = 0; i < nUsers; ++i) { // Find a user who is already calibrated if (g_UserGenerator.GetSkeletonCap().IsCalibrated(aUserIDs[i])) { // Save user's calibration to file g_UserGenerator.GetSkeletonCap().SaveCalibrationDataToFile(aUserIDs[i], XN_CALIBRATION_FILE_NAME); printf("saved data\n"); break; } } }
2 | No.2 Revision |
Here are a few snippets from the code I use. I can get you the entire package if you want, but there is alot of other stuff going on that might be confusing. I call SaveCalibration after a user calibrates during the user calibrated callback function. It creates the UserCalibration.bin file:
'
void SaveCalibration()
{
XnUserID aUserIDs[20] = {0};
XnUInt16 nUsers = 20;
g_UserGenerator.GetUsers(aUserIDs, nUsers);
for (int i = 0; i < nUsers; ++i)
{
// Find a user who is already calibrated
if (g_UserGenerator.GetSkeletonCap().IsCalibrated(aUserIDs[i]))
{
// Save user's calibration to file
g_UserGenerator.GetSkeletonCap().SaveCalibrationDataToFile(aUserIDs[i], XN_CALIBRATION_FILE_NAME);
printf("saved data\n");
break;
}
}
}}'
3 | No.3 Revision |
Here are a few snippets from the code I use. I can get you the entire package if you want, but there is alot of other stuff going on that might be confusing. I call SaveCalibration after a user calibrates during the user calibrated callback function. It creates the UserCalibration.bin file:
''#define XN_CALIBRATION_FILE_NAME "UserCalibration.bin"'
void SaveCalibration() { XnUserID aUserIDs[20] = {0}; XnUInt16 nUsers = 20; g_UserGenerator.GetUsers(aUserIDs, nUsers); for (int i = 0; i < nUsers; ++i) { // Find a user who is already calibrated if (g_UserGenerator.GetSkeletonCap().IsCalibrated(aUserIDs[i])) { // Save user's calibration to file g_UserGenerator.GetSkeletonCap().SaveCalibrationDataToFile(aUserIDs[i], XN_CALIBRATION_FILE_NAME); printf("saved data\n"); break; } } }'
4 | No.4 Revision |
Here are a few snippets from the code I use. I can get you the entire package if you want, but there is alot of other stuff going on that might be confusing. I call SaveCalibration after a user calibrates during the user calibrated callback function. It creates the UserCalibration.bin file:
'#define
#define
XN_CALIBRATION_FILE_NAME 5 | No.5 Revision |
Here are a few snippets from is an example of the code I use. I can get function you the entire package if you want, but there is alot should find inside of other stuff going on that might be confusing. I call SaveCalibration after a user calibrates during the user calibrated callback function. recent unstable NiUserTracker demo code. It creates the UserCalibration.bin file:
#define XN_CALIBRATION_FILE_NAME "UserCalibration.bin"
void SaveCalibration()
{
XnUserID aUserIDs[20] = {0};
XnUInt16 nUsers = 20;
g_UserGenerator.GetUsers(aUserIDs, nUsers);
for (int i = 0; i < nUsers; ++i)
{
// Find a user who is already calibrated
if (g_UserGenerator.GetSkeletonCap().IsCalibrated(aUserIDs[i]))
{
// Save user's calibration to file
g_UserGenerator.GetSkeletonCap().SaveCalibrationDataToFile(aUserIDs[i], XN_CALIBRATION_FILE_NAME);
printf("saved data\n");
break;
}
}
}