ST_MakeEmptyCoverage — 用空栅格图块网格覆盖地理参考区域。
raster ST_MakeEmptyCoverage(
integer tilewidth, integer tileheight, integer width, integer height, double precision upperleftx, double precision upperlefty, double precision scalex, double precision scaley, double precision skewx, double precision skewy, integer srid=unknown)
;
使用 ST_MakeEmptyRaster 创建一组栅格瓦片。栅格维度由宽度(width
)& 高度(height
)确定,而瓦片维度则由瓦片宽度(tilewidth
)& 瓦片高度(tileheight
)确定。覆盖的地理参考区域从左上角(upperleftx
,upperlefty
)延伸到右下角(upperleftx
+ width
* scalex
,upperlefty
+ height
* scaley
)。
请注意,对于栅格,scaley 通常为负值,scalex 通常为正值。 所以右下角的 y 值会比左上角低,x 值会比左上角高。 |
可用性:2.4.0
在 4x4 网格中创建 16 个图块,以覆盖从左上角 (22, 77) 到右下角 (55, 33) 的 WGS84 区域。
SELECT (ST_MetaData(tile)).* FROM ST_MakeEmptyCoverage(1, 1, 4, 4, 22, 33, (55 - 22)/(4)::float, (33 - 77)/(4)::float, 0., 0., 4326) tile; upperleftx | upperlefty | width | height | scalex | scaley | skewx | skewy | srid | numbands ------------------------------------------------------------------------------------- 22 | 33 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 30.25 | 33 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 38.5 | 33 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 46.75 | 33 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 22 | 22 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 30.25 | 22 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 38.5 | 22 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 46.75 | 22 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 22 | 11 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 30.25 | 11 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 38.5 | 11 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 46.75 | 11 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 22 | 0 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 30.25 | 0 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 38.5 | 0 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0 46.75 | 0 | 1 | 1 | 8.25 | -11 | 0 | 0 | 4326 | 0