No data support in FunctorImageFilter
FunctorImageFilter currently doesn't support no data handling, i.e. no data pixels are processed like regular pixels. It would be nice to have a method to set a no data value to the filter, and to check if pixels are no data before calling the functor.
This would add support for no data in a lot of otb applications.
However maybe the performance cost of checking no data for each pixel is too high, considering that
FunctorImageFilter is supposed to be efficient. Maybe handling of no data should be left to the functor if needed, i.e. storing the no-data value in the functor and defining how no data should be handled in the
More generally, the question is to know if we want no-data support for pixel wise operations in otb, even if it has a cost when there is no no-data in the image. What do you think ?
Note: adding support for Nodata in
FunctorImageFilter would require to define how no data pixels should be processed when using neighborhood.