HuaYuXiao / Fast-Planner

[RA-L 2019] A Robust and Efficient Trajectory Planner for Quadrotors
GNU General Public License v3.0
1 stars 0 forks source link

could not convert from ‘VoxelGrid::GRID_INDEX’ to ‘std::vector<long int>’ #9

Closed HuaYuXiao closed 2 months ago

HuaYuXiao commented 2 months ago
/home/hyx020222/planner_ws/src/Fast-Planner/plan_env/ThirdParty/sdf_tools/src/sdf_tools/sdf.cpp: In member function ‘std::vector<long int> sdf_tools::SignedDistanceField::LocationToGridIndex3d(const Vector3d&) const’:
/home/hyx020222/planner_ws/src/Fast-Planner/plan_env/ThirdParty/sdf_tools/src/sdf_tools/sdf.cpp:902:53: error: could not convert ‘((const sdf_tools::SignedDistanceField*)this)->sdf_tools::SignedDistanceField::distance_field_.VoxelGrid::VoxelGrid<float>::LocationToGridIndex3d((* & location))’ from ‘VoxelGrid::GRID_INDEX’ to ‘std::vector<long int>’
  902 |         return distance_field_.LocationToGridIndex3d(location);
      |                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~
      |                                                     |
      |                                                     VoxelGrid::GRID_INDEX
HuaYuXiao commented 2 months ago

After replace std::vector<int64_t> with VoxelGrid::GRID_INDEX,

/home/hyx020222/planner_ws/src/Fast-Planner/plan_env/ThirdParty/sdf_tools/src/sdf_tools/tagged_object_collision_map.cpp: At global scope:
/home/hyx020222/planner_ws/src/Fast-Planner/plan_env/ThirdParty/sdf_tools/src/sdf_tools/tagged_object_collision_map.cpp:886:27: error: no declaration matches ‘VoxelGrid::GRID_INDEX sdf_tools::TaggedObjectCollisionMapGrid::LocationToGridIndex3d(const Vector3d&) const’
  886 |     VoxelGrid::GRID_INDEX TaggedObjectCollisionMapGrid::LocationToGridIndex3d(const Eigen::Vector3d& location) const
      |                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~