LivoxHorizon.h 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. #ifndef __LIVOX_HORIZON__H
  2. #define __LIVOX_HORIZON__H
  3. #include "Laser.h"
  4. #include "livox_def.h"
  5. #include "livox_sdk.h"
  6. #include <map>
  7. #include "LivoxLaser.h"
  8. //大疆livox雷达,从Laser_base继承。
  9. class CHorizonLaser :public CLivoxLaser
  10. {
  11. public:
  12. CHorizonLaser() = delete;
  13. CHorizonLaser(const CHorizonLaser& other) = delete;
  14. //唯一的构造函数,按照设备名称和雷达参数来创建实例。
  15. //input:id: 雷达设备的id,(唯一索引)
  16. //input:laser_param:雷达的参数,
  17. //注:利用protobuf创建 laser_parameter 类,然后从文件读取参数
  18. CHorizonLaser(int id, Laser_proto::laser_parameter laser_param);
  19. ~CHorizonLaser();
  20. //雷达的启动接口函数, 让雷达进行扫描,一般需要子类重载,不同的雷达开始方式不同。
  21. virtual Error_manager start_scan();
  22. //将二进制消息转化为三维点云的功能函数,并将其存入 任务单 , 每次只转化一个CBinaryData,
  23. // 纯虚函数,必须由子类重载,
  24. virtual Buf_type transform_buf_to_points(Binary_buf* p_binary_buf, std::vector<CPoint3D>& point3D_cloud);
  25. };
  26. #endif