This tool will create a mosaic from two input images. It is similar in operation to the Mosaic tool, however, this tool is the preferred method of mosaicing images when there is significant overlap between the images. For areas of overlap, the feathering method will calculate the output value as a weighted combination of the two input values, where the weights are derived from the squared distance of the pixel to the edge of the data in each of the input raster files. Therefore, less weight is assigned to an image's pixel value where the pixel is very near the edge of the image. Note that the distance is actually calculated to the edge of the data and not the edge of the grid, taking into account the fact that rectified images often contain areas of NoData values near grid edges if the data are rotated. The result of this feathering method is that the output mosaic image should have very little evidence of the original image edges within the overlapping area. Histogram matching can also be performed on one of the input images (i.e. the 'Append' image) to force its radiometric properties (contrast) to match that of the 'Base' image. If this option is selected, the user should specify the name of the image with the superior contrast characteristics as the 'Base' image. If histogram matching is not used, there is no difference between either of the two input images. Note that this tool will create several temporary images, which should be automatically deleted upon completion.
Unlike the Mosaic tool, which can take multiple input images, this tool only accepts two input images. Mosaic is therefore useful when there are many, adjacent or only slightly overlapping images, e.g. for data sets of interpolated LiDAR DEM tiles.
The following is an example of a Python script using this tool:
wd = pluginHost.getWorkingDirectory()
baseFile = wd + "input1.dep"
appendFile = wd + "input2.dep"
outputFile = wd + "output.dep"
resamplingMethod = "nearest neighbour"
matchHistograms = "true"
args = [baseFile, appendFile, outputFile, resamplingMethod, matchHistograms]
pluginHost.runPlugin("MosaicWithFeathering", args, False)
This is a Groovy script also using this tool:
def wd = pluginHost.getWorkingDirectory()
def baseFile = wd + "input1.dep"
def appendFile = wd + "input2.dep"
def outputFile = wd + "output.dep"
def resamplingMethod = "nearest neighbour"
def matchHistograms = "true"
String args = [baseFile, appendFile, outputFile, resamplingMethod, matchHistograms]
pluginHost.runPlugin("MosaicWithFeathering", args, false)