-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Add Circle (with radius expressed in physical units) #4312
Comments
Given that there are circles defined from
We should have a solid vocabulary that helps differentiate from the beginning. |
I created this issue for parity with gmaps. There they define this circle as |
We're in a good position now to add this API. Meanwhile, we currently have three workarounds:
|
Note the differences between the three approaches: the polygon approach in #2167 (comment) is for a circle whose radius corresponds to a physical ground distance, whereas the |
Using a polygon feels like a hackish workaround. This feature should really be supported at the native level. |
Circles are supported through CircleLayer, we do not expose an annotation API for it atm. |
The problem I have with the CircleLayer right now is that the only way I found of creating a circle with dynamic in-app data is using a geoJSON source. But geojson doesn't seem to allow us to specify a circle. https://stackoverflow.com/questions/16942697/geojson-circles-supported-or-not |
For a
And then use the
If you need more control over the circle, another option you might want to look into is the |
@tobrun @zugaldia, please note that there’s a fundamental difference between the kind of circle drawn by CircleLayer (whose radius is expressed in screen units) and the kind of circle that’s tracked in this ticket (whose radius corresponds to a physical distance). Please refer to #4312 (comment). This is still a valid feature request, although there’s a tension between implementing this very useful feature while at the same time conforming to the Simple Features specification and GeoJSON. |
This issue has been automatically detected as stale because it has not had recent activity and will be archived. Thank you for your contributions. |
Now there seems to be annotation support for circles using |
Coming from Google Maps and found the same issue. Any updates on this? |
First step to implement this feature is supporting http://turfjs.org/docs/#circle in the java port of turf. This is ticketed in mapbox/mapbox-java#1002. edit: that functionality is already implemented so this should already be possible today. Will create a small example around this. |
Did you try this ?! for draw circle |
A circle on the earth's surface on a specific LatLng as center.
iOS equivalent: #2167
The text was updated successfully, but these errors were encountered: