asj_pe_standingjump_warpper.h 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. #ifndef ASJ_PE_STANDINGJUMP_WARPPER
  2. #define ASJ_PE_STANDINGJUMP_WARPPER
  3. #include "PEStatus.h"
  4. #include "standingjump_dl_api.h"
  5. // #################################
  6. // ######### StandingJump Struct #########
  7. // #################################
  8. typedef struct
  9. {
  10. sampleRunJoint_POINT_S padPoint[4]; // 垫子的四个顶点(左上,右上,右下,左下)
  11. int padLength; // 垫子的长度(cm)
  12. int padWidth; // 垫子的宽度(cm)
  13. } StandingJump_ST;
  14. typedef struct
  15. {
  16. int score; // 跳远成绩(cm)
  17. int standingjump_illegal_flag; // 立定跳远违规状态码
  18. } StandingJumpResult_ST;
  19. /**
  20. * 创建实例,单例模式.
  21. * @return 实例指针
  22. */
  23. void* standingjump_create();
  24. /**
  25. * 对实例进行数据清零并赋值结构体中的参数
  26. * @param standingjump 输入参数:实例指针
  27. * @param standingjump_s 输入参数:页面设定的参数
  28. * @return 参考PEStatus.h中的StatusCode
  29. */
  30. int standingjump_examInit(void* standingjump, StandingJump_ST standingjump_s);
  31. /**
  32. * 输入推理数据进行准备状态检测
  33. * @param standingjump 输入参数:实例指针
  34. * @param mResult 输入参数:页面设定的参数
  35. * @param prepareStatus 输出参数:根据PEStatus.h中的StandingJumpPrepareCode按位或运算后的返回值
  36. * @return 参考PEStatus.h中的StatusCode
  37. */
  38. int standingjump_processPrepare(void* standingjump, sampleRunJoint_RESULT_S *mResult, int *prepareStatus);
  39. /**
  40. * 输入推理数据进行考试状态检测
  41. * @param situp 输入参数:实例指针
  42. * @param mResult 输入参数:页面设定的参数
  43. * @param result 输出参数:结果结构体(包含计数结果和PEStatus.h中的StandingJumpExamCode按位或运算后的返回值)
  44. * @return 参考PEStatus.h中的StatusCode
  45. */
  46. int standingjump_processExam(void* standingjump, sampleRunJoint_RESULT_S *mResult, StandingJumpResult_ST *result);
  47. /**
  48. * enum转换char*
  49. * @param code 输入参数:枚举变量
  50. * @return 枚举变量对应的字符串
  51. */
  52. const char *StandingJumpExamCode2String(enum StandingJumpExamCode code);
  53. #endif