Назва

reclassarg — Композитний тип, що використовується як вхідні дані для функції ST_Reclass, яка визначає поведінку перекласифікації.

Description

Композитний тип, що використовується як вхідні дані для функції ST_Reclass, яка визначає поведінку перекласифікації.

Field Type Description
nband integer Номер каналу, який потрібно перекласифікувати.
reclassexpr text Comma-delimited range:map_range mappings that define how old band values map to new band values.
pixeltype text One of defined pixel types as described in ST_BandPixelType.
nodataval double precision Значення, яке слід розглядати як відсутність даних. Для зображень, що підтримують прозорість, ці поля будуть порожніми.

The reclassexpr range delimiters mean: ( greater than, ) less than, ] less than or equal, and [ greater than or equal.

  • [a-b] means a <= x <= b.

  • (a-b] means a < x <= b.

  • [a-b) means a <= x < b.

  • (a-b) means a < x < b.

Opening-parenthesis notation is optional, so a-b means the same as (a-b).

Приклади

Reclassify band 2 as an 8BUI where 255 is nodata value.

Code
SELECT ROW(2, '0-100:1-10, 101-500:11-150,501 - 10000: 151-254', '8BUI', 255)::reclassarg;

Reclassify band 1 as an 1BB and no nodata value defined.

Code
SELECT ROW(1, '0-100]:0, (100-255:1', '1BB', NULL)::reclassarg;

Див. також

ST_Reclass