<html>
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">Hi Karim,<br>
<br>
</div>
<blockquote
cite="mid:CADoa0hFwYTn-v4HcTMxrtJ2SYwN=kNMLJ1bp0DZQNgUbJy+ovQ@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>1. Given an Edge ID, how to get the (lat,lon) pairs that
connect it?</div>
</div>
</blockquote>
<br>
via:<br>
<br>
graph.getEdgeProps(edgeId, Integer.MIN_VALUE)<br>
na = graph.getNodeAccess()<br>
lat1/lon1 = na.getLat/Lon(edgeIteratorState.getBaseNode)<br>
lat2/lon2 = na.getLat/Lon(edgeIteratorState.getAdjNode)<br>
<br>
<br>
<blockquote
cite="mid:CADoa0hFwYTn-v4HcTMxrtJ2SYwN=kNMLJ1bp0DZQNgUbJy+ovQ@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>2. Given a single (lat, lon) pair, how to get which edge ID
it belongs to? Because, with Map-matching, I will need atlas 2
points.</div>
</div>
</blockquote>
<br>
If you have multiple GPS points you should consider using the <a
href="https://github.com/graphhopper/map-matching">map matching
component</a>. Otherwise use the locationIndex.findClosest<br>
<br>
Regards,<br>
Peter<br>
</body>
</html>