diff options
Diffstat (limited to 'include/libsurvive/poser.h')
-rw-r--r-- | include/libsurvive/poser.h | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/include/libsurvive/poser.h b/include/libsurvive/poser.h index ccd36ce..b0b1a7b 100644 --- a/include/libsurvive/poser.h +++ b/include/libsurvive/poser.h @@ -8,18 +8,19 @@ extern "C" { #endif -typedef enum PoserType_t -{ +typedef enum PoserType_t { POSERDATA_NONE = 0, POSERDATA_IMU, - POSERDATA_LIGHT, //Single lighting event. - POSERDATA_FULL_SCENE, //Full, statified X, Y sweep data for both lighthouses. - POSERDATA_DISASSOCIATE, //If you get this, it doesn't contain data. It just tells you to please disassociate from the current SurviveObject and delete your poserdata. - POSERDATA_SYNC, //Sync pulse. + POSERDATA_LIGHT, // Single lighting event. + POSERDATA_FULL_SCENE, // Full, statified X, Y sweep data for both lighthouses. + POSERDATA_DISASSOCIATE, // If you get this, it doesn't contain data. It just tells you to please disassociate from + // the current SurviveObject and delete your poserdata. + POSERDATA_SYNC, // Sync pulse. } PoserType; typedef void (*poser_raw_pose_func)(SurviveObject *so, uint8_t lighthouse, SurvivePose *pose, void *user); -typedef void (*poser_lighthouse_pose_func)(SurviveObject *so, uint8_t lighthouse, SurvivePose *pose, void *user); +typedef void (*poser_lighthouse_pose_func)(SurviveObject *so, uint8_t lighthouse, SurvivePose *lighthouse_pose, + SurvivePose *object_pose, void *user); typedef struct { @@ -30,10 +31,11 @@ typedef struct } PoserData; void PoserData_poser_raw_pose_func(PoserData *poser_data, SurviveObject *so, uint8_t lighthouse, SurvivePose *pose); -void PoserData_lighthouse_pose_func(PoserData *poser_data, SurviveObject *so, uint8_t lighthouse, SurvivePose *pose); +void PoserData_lighthouse_pose_func(PoserData *poser_data, SurviveObject *so, uint8_t lighthouse, + /* OUTPARAM */ SurvivePose *objUp2world, SurvivePose *lighthouse_poses, + SurvivePose *object_pose); -typedef struct -{ +typedef struct PoserDataIMU { PoserData hdr; uint8_t datamask; //0 = accel present, 1 = gyro present, 2 = mag present. FLT accel[3]; |