MCPcopy Create free account
hub / github.com/OctoMap/octomap / getNeighborIDs

Method getNeighborIDs

octomap/src/ScanGraph.cpp:272–285  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

270 }
271
272 std::vector<unsigned int> ScanGraph::getNeighborIDs(unsigned int id) {
273 std::vector<unsigned int> res;
274 ScanNode* node = getNodeByID(id);
275 if (node) {
276 // check all nodes
277 for (unsigned int i = 0; i < nodes.size(); i++) {
278 if (node->id == nodes[i]->id) continue;
279 if (edgeExists(id, nodes[i]->id)) {
280 res.push_back(nodes[i]->id);
281 }
282 }
283 }
284 return res;
285 }
286
287 std::vector<ScanEdge*> ScanGraph::getOutEdges(ScanNode* node) {
288 std::vector<ScanEdge*> res;

Callers

nothing calls this directly

Calls 2

sizeMethod · 0.45
push_backMethod · 0.45

Tested by

no test coverage detected