全部產品
Search
文件中心

ApsaraDB RDS:ST_Slope

更新時間:Aug 26, 2026

計算坡度,返回弧度為單位的像元坡度柵格對象。

文法

raster ST_Slope(raster rast, integer pyramid_level, integer band, Box extent, BoxType type, float8 zfactor, cstring storageOption);

參數

參數名稱

描述

rast

raster對象。

pyramid_level

計算的金字塔等級。

Band

波段索引號

box

分析地區,格式為'((m inX,m inY), (m axX,m axY))'。

type

分析地區的座標類型,只能是以下一種:

  • Raster(影像座標)

  • World(全局座標)

zfactor

高程誇張值,預設為1。

storageOption

目標raster對象的儲存選項,參見ST_ClipToRast函數。

描述

坡度計算函數用於為每個像元計算值在從該像元到與其相鄰的像元方向上的最大變動率。實際上,高程隨著像元與其相鄰的八個像元之間距離的變化而產生的最大變動率,可用來識別自該像元開始的最陡坡降。

樣本

select st_slope(rast, 0, 0, '(0,0), (5,5)', 'Raster', 2.0) from t_surface where id=1;