Add optional elevation arguments for project()/unproject()
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 12.4k
- Forks
- 2.4k
- PR merge metrics
- No merged PRs in 30d
Description
I'd like to be able to incorporate altitude both when converting a pixel value to a lnglat coordinate, and vice versa. This would allow us to make calculations and reason about the map, in full 3D space. Example questions this would answer are:
`map.project(lnglat, elevation)`: where on the screen would an object at *this* coordinate and *this* elevation appear?
`map.unproject(px, elevation)`: Say I'm hovering on the rooftop of a building extrusion of known height. What's the ground coordinate that corresponds to this pixel value?
This would be an optional parameter that defaults to, and has a minimum of 0.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the project() and unproject() entry points and trace the existing pixel-to-coordinate conversions. Define how the optional elevation argument defaults to and is constrained at 0, then verify that both conversions account for the supplied elevation in 3D map calculations.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- api, frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100