updated to 1E6 based polyline format
This commit is contained in:
parent
4d73f98050
commit
782fba2ce7
@ -119,8 +119,8 @@ std::vector<FixedPointCoordinate> PolylineCompressor::decode_string(const std::s
|
||||
lng += dlng;
|
||||
|
||||
FixedPointCoordinate p;
|
||||
p.lat = COORDINATE_PRECISION * (((double) lat / 1E5));
|
||||
p.lon = COORDINATE_PRECISION * (((double) lng / 1E5));
|
||||
p.lat = COORDINATE_PRECISION * (((double) lat / 1E6));
|
||||
p.lon = COORDINATE_PRECISION * (((double) lng / 1E6));
|
||||
new_coordinates.push_back(p);
|
||||
}
|
||||
|
||||
|
@ -39,7 +39,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
BOOST_AUTO_TEST_CASE(geometry_string)
|
||||
{
|
||||
// Polyline string for the 5 coordinates
|
||||
const std::string polyline = "_c`|@_c`|@o}@_pRo}@}oRm}@apRo}@_pR";
|
||||
const std::string polyline = "_gjaR_gjaR_pR_ibE_pR_ibE_pR_ibE_pR_ibE";
|
||||
PolylineCompressor pc;
|
||||
std::vector<FixedPointCoordinate> coords = pc.decode_string(polyline);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user