【发布时间】:2021-01-06 18:12:25
【问题描述】:
我已经使用 xyz 平铺系统和 geotools 实现了平铺服务器来渲染平铺图像,现在我必须缓存我的平铺图像,这是一个 256*256(总是)大小的 png 图像,我没有使用 geowebcache,因为我认为它不适合特征几何和图层样式可以每天更改的网络制图应用程序,因此我使用 xyz 系统而不是使用 bbox 或 wms 请求,我找到了一篇关于将瓷砖作为 mvt(地图框矢量瓷砖)提供的好文章来自https://medium.com/geolytix/xyz-dynamic-vector-tiles-created-on-the-fly-cached-and-updated-directly-in-postgis-37db33c31450,for 的 postgis 我的情况不是缓存 mvt,而是缓存一个光栅图块,与字节数组相同 例如:
create table if not exists tile_cache
(
z integer not null,
x integer not null,
y integer not null,
mvt tile,
bbox geometry(Polygon,4326),
constraint tile_cache_x_y_pk
primary key (z, x, y)
)
;
create index if not exists tile_cache_z_x_y_idx
on tile_cache (z, x, y)
;
它会创建一个 xyz 索引来加速思考, 所以我想知道什么是最好和更快的解决方案? 使用 xyz 索引从 postgis 表提供切片或直接从文件系统提供。
【问题讨论】: