Better interface for ResetMargin
The current interface of the
ResetMargin is not symmetric in X and Y:
threshold.xis used to define the margin size for left and right sides
threshold.y.startis used to define the top margin size
threshold.y.endis used to define the bottom margin size (which is strange because "end" usually refer to an absolute coordinate in OTB world, not a margin size).
Also, the term
threshold suggest an operation is performed based on the pixel value, which is not the case.
I propose to replace these parameters by 2 interfaces to set the region:
- as a ROI, just like in
- as margins for each side
These parameters should be made consistent by the function
To ensure API compatibility, it is possible to deprecate the
threshold... parameters, while introducing the new ones