CityGrow 城市生长
可基于开始/结束时间与高度等属性,动态再现城市形态随时间逐期生长与演变的过程。
<mapgis-3d-city-grow></mapgis-3d-city-grow>
基本用法
API
属性
| 参数 | 说明 | 类型 | 默认值 | 版本 |
|---|---|---|---|---|
| dataSource | 城市生长数据源 | CityGrowDataSource | ||
| buildingColors | 城市生长颜色区间 | array | ['rgba(245,33,0,1)', 'rgba(255,121,26,1)','rgba(255,164,46,1)','rgba(255,209,82,1)'] | |
| playTime | 城市生长的进度条播放时间(秒) | number | 30 | |
| timeFormat | 城市生长的进度条日期格式(day.js) | string | YYYY.MM.DD |
方法
| 名称 | 描述 | 版本 |
|---|---|---|
| simulate | 开始城市生长 | |
| clearState | 清除城市生长效果 |
CityGrowDataSource
城市生长数据源
typescript
export interface CityGrowDataSource {
serviceUrl: string // 服务地址
tokenKey?: number // 令牌字段名
tokenValue?: string // 令牌值
tokenAttachType?: string // 令牌位置,可取值url(查询参数)、header(请求头)
}