Strange behavior and BorderInterpolate

that’s not a segfault, but a runtime assertion (and it should happen in 4.2.0, too)

what is your borderType, actually ? the default (BORDER_CONSTANT) is well supported.