{"id":15798576,"url":"https://github.com/chanced/rs-polyline-codec","last_synced_at":"2025-04-21T08:31:59.004Z","repository":{"id":62442777,"uuid":"480158314","full_name":"chanced/rs-polyline-codec","owner":"chanced","description":"Polyline encoding and decoding.","archived":false,"fork":false,"pushed_at":"2022-04-11T01:13:09.000Z","size":18,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-10-06T00:42:37.652Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/chanced.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-04-10T22:44:36.000Z","updated_at":"2023-03-15T21:16:45.000Z","dependencies_parsed_at":"2022-11-01T22:15:37.711Z","dependency_job_id":null,"html_url":"https://github.com/chanced/rs-polyline-codec","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chanced%2Frs-polyline-codec","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chanced%2Frs-polyline-codec/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chanced%2Frs-polyline-codec/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chanced%2Frs-polyline-codec/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/chanced","download_url":"https://codeload.github.com/chanced/rs-polyline-codec/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248929696,"owners_count":21184880,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-05T00:42:38.183Z","updated_at":"2025-04-21T08:31:58.788Z","avatar_url":"https://github.com/chanced.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![crates.io](https://img.shields.io/crates/v/polyline-codec?style=flat-square)](https://crates.io/crates/polyline-codec) [![docs.rs](https://img.shields.io/docsrs/polyline-codec?style=flat-square)](https://docs.rs/polyline-codec)\n![Crates.io](https://img.shields.io/crates/l/polyline-codec?style=flat-square)\n\n# Rust port of Google Maps Polyline Encoding\n\n## Description\n\nEncode and decode polyines in Rust using this package.\n\nPolyline encoding is a lossy compression algorithm that allows you to store a series of coordinates as a single string. Point coordinates are encoded using signed values.\n\nRead more at https://developers.google.com/maps/documentation/utilities/polylinealgorithm.\n\n## Note\n\nI have no affiliation with Google or Google Maps. This package was ported from https://github.com/googlemaps/js-polyline-codec.\n\n## Example\n\n```rust\n    use polyline_codec::LatLng;\n    let encoded = \"_p~iF~ps|U_ulLnnqC_mqNvxq`@\";\n    assert_eq!(\n        polyline_codec::decode(encoded, 5).unwrap(),\n        vec![\n            LatLng(38.5, -120.2,),\n            LatLng(40.7, -120.95,),\n            LatLng(43.252, -126.453,),\n        ]\n    );\n\n    let path = \u0026[(38.5, -120.2), (40.7, -120.95), (43.252, -126.453)];\n    assert_eq!(\n        polyline_codec::encode(path, 5).unwrap(),\n        \"_p~iF~ps|U_ulLnnqC_mqNvxq`@\",\n    );\n```\n\n## License\n\nMIT OR Apache v2.0\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchanced%2Frs-polyline-codec","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchanced%2Frs-polyline-codec","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchanced%2Frs-polyline-codec/lists"}