MCPcopy Create free account
hub / github.com/Robotics-STAR-Lab/SOAR / adrToIndex

Method adrToIndex

src/planner/plan_env/src/multi_map_manager.cpp:495–506  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

493}
494
495void MultiMapManager::adrToIndex(const uint32_t& adr, Eigen::Vector3i& idx)
496{
497 // x * mp_->map_voxel_num_(1) * mp_->map_voxel_num_(2) + y * mp_->map_voxel_num_(2) + z
498 uint32_t tmp_adr = adr;
499 const int a = map_->mp_->map_voxel_num_[1] * map_->mp_->map_voxel_num_[2];
500 const int b = map_->mp_->map_voxel_num_[2];
501
502 idx[0] = tmp_adr / a;
503 tmp_adr = tmp_adr % a;
504 idx[1] = tmp_adr / b;
505 idx[2] = tmp_adr % b;
506}
507
508void MultiMapManager::insertChunkToMap(const MapChunk& chunk, const int& drone_id)
509{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected