HeadCountAPI.cpp 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. #include "StrategyAPI.h"
  2. #include "HeadCountStrategy.h"
  3. SDKAPI TZ_INT Initialize()
  4. {
  5. return 0;
  6. }
  7. SDKAPI TZ_INT Dispose()
  8. {
  9. return 0;
  10. }
  11. SDKAPI masd::Strategy * BuildStrategy()
  12. {
  13. masd::Strategy * stra = new masd::headcount::HeadCountStrategy();
  14. return stra;
  15. }
  16. SDKAPI void DestroyStrategy(masd::Strategy * strategy)
  17. {
  18. TZ_delete(strategy);
  19. }
  20. SDKAPI TZ_INT GetInformation(TZ_CHAR * informatrion)
  21. {
  22. masd::StrategyInfo info;
  23. info.Key = "HeadCount";
  24. info.Name = "人头计数判定策略";
  25. info.Version = "V1.0.0-T-20241007R";
  26. info.Author = "杭州晨鹰军泰";
  27. info.UpdateDate = "2024-10-07 09:30:00";
  28. info.StraDets.emplace_back(0, -1, "YoloCrowd", "人头目标检测");
  29. /*info.StraCfgs.push_back({masd::DIT_INT, "TimeThreshold",
  30. "人头计数时间阈值", "5", "1", "60", "1",
  31. "单位:秒。人头计数时间阈值,每经过设定的时间向后续业务传输人头数量。"});*/
  32. info.StraRsts.emplace_back(masd::SRT_NOT_SHOW, "人头数量");
  33. strcpy(informatrion, info.toJson().c_str());
  34. return masd::MEC_OK;
  35. }