

本文属于机器翻译版本。若本译文内容与英语原文存在差异，则一律以英文原文为准。

# 生成静态地图时如何在 radius 和 zoom 之间做出选择
<a name="choose-radius-vs-zoom"></a>

在本主题中，您将了解当使用 Amazon Location Service 生成静态地图时，如何在使用 `radius` 或 `zoom` 之间做出选择。`radius` 参数可以更精确地控制覆盖区域，因此非常适合那些已知确切覆盖范围的面向客户的应用程序。当您想要调整所显示细节的级别时，`zoom` 参数更适合用于地理空间分析。

## 使用 radius
<a name="with-radius"></a>

在本示例中，您将使用带有中心位置的 `radius` 参数来创建斯里兰卡的地图图像。

------
#### [ Request URL ]

```
https://maps.geo.eu-central-1.amazonaws.com/v2/static/map?style=Satellite&width=700&height=700&center=80.60596,7.76671&radius=235000&scale-unit=KilometersMiles&key=API_KEY
```

------
#### [ Response image ]

![\[Satellite view of Sri Lanka, showing the teardrop-shaped island nation surrounded by ocean.\]](http://docs.aws.amazon.com/zh_cn/location/latest/developerguide/images/static-radius.png)


------

## 使用 zoom
<a name="with-zoom"></a>

在本示例中，您将使用带有中心位置的 `zoom` 参数来创建斯里兰卡的地图图像。

------
#### [ Request URL ]

```
https://maps.geo.eu-central-1.amazonaws.com/v2/static/map?style=Satellite&width=700&height=700&zoom=8&center=80.60596,7.76671&scale-unit=KilometersMiles&key=API_KEY
```

------
#### [ Response image ]

![\[Satellite view of Sri Lanka, showing the teardrop-shaped island nation surrounded by ocean.\]](http://docs.aws.amazon.com/zh_cn/location/latest/developerguide/images/static-zoom.png)


------