Display the map at an initial viewpoint representing a bounding geometry.

Use case
Setting the initial viewpoint is useful when a user wishes to first load the map at a particular area of interest.
How to use the sample
When the sample loads, note the map is opened at the initial viewpoint that is set to it.
How it works
- Instantiate a
Mapobject. - Instantiate a
Viewpointobject using anEnvelopeobject. - Set the starting location of the map with
map.initialViewpoint = Viewpoint(boundingGeometry:). - Set the map to a
MapViewobject.
Relevant API
- Envelope
- Map
- MapView
- Point
- Viewpoint
Tags
envelope, extent, initial viewpoint, zoom