pull/1680/head
Piero Toffanin 2025-05-19 13:42:02 -04:00
rodzic c287fa44d5
commit 5b6c412180
1 zmienionych plików z 3 dodań i 5 usunięć

Wyświetl plik

@ -152,11 +152,9 @@ def export_raster(input, output, **opts):
ci.index(ColorInterp.alpha) + 1)
# Only 2 bands (common with thermal)?
elif len(ci) <= 2 and ColorInterp.gray in ci and ColorInterp.alpha in ci:
indexes = (ci.index(ColorInterp.gray) + 1,
ci.index(ColorInterp.gray) + 1,
ci.index(ColorInterp.gray) + 1,
ci.index(ColorInterp.alpha) + 1)
elif len(ci) == 2 and ColorInterp.gray in ci and ColorInterp.alpha in ci:
indexes = (ci.index(ColorInterp.gray) + 1,) * 3 + \
(ci.index(ColorInterp.alpha) + 1, )
if ColorInterp.alpha in ci:
mask = reader.read(ci.index(ColorInterp.alpha) + 1, window=win)