Skip to content

New JAI Mosaic Operation

n-lagomarsini edited this page Jun 7, 2013 · 24 revisions

In this page will be described the a modified implementation of the JAI Mosaic Operation that supports noData values and does not use threshold values. In this new Mosaic class the threshold is not used because it doesn't fit our purposes.

NoData values are special values such -9999, Integer.MIN_VALUE, etc... which indicates the absence of informations in that pixel. There is no standard for these values so in every image there could be a different type of noData. In the old Mosaic operation behaviour, one way to avoid a single type of noData value was to set a specific threshold(equal to the noData value) and any value below it, was considered a background value. If there were multiple images with multiple different noData values, the above behaviour could not be correct. For example, if there are 2 images with 2 different noData value types, the threshold could be set to the biggest value between them but, in this way, even the value of the lowest noData value image that lays below the threshold are set to background value, unless you set two different threshold per image.

A simple way to avoid all of these inconvenients is to set an initial range of noData values to check when the Mosaic operation is performed.