Is there any similar function that works same as
interp2(x, y, frame(:,:,z), xd, yd, '*linear', 0)
in OpenCV?
The function cv::remap()
does almost what you're asking for, see the documentation here.
You need to precompute the (x,y) target coordinates of the points in the input array(s) called map1
and map2
in the doc (use only one if you pack (x,y) coordinate, two otherwise).
The OpenCV equivalent to '*linear'
is cv::INTER_BILINEAR
.