locationtech / geotrellis

GeoTrellis is a geographic data processing engine for high performance applications.
http://geotrellis.io
Other
1.34k stars 360 forks source link

Fix: Mask preserves cell type of the masked tile #3494

Closed echeipesh closed 1 year ago

echeipesh commented 1 year ago

Overview

Mask and InverseMask functions used dualCombine which used the union of cellTypes between tile and mask for result type. This mostly worked out fine but can produce bad results when either mask or tile had same byte width but different NODATA definitions. The correct behavior for mask operation is to always preserver the cell type of the input tile no matter how silly it or the mask cell type is. It's just better not to ask questions here.

Checklist

Notes

Closes #3488