How to replicate border function in openCV without using cv2.copyMakeBorder?

Viewed 29

I'm trying to make border around an image in openCV. I have used the following function -

img_in = cv2.copyMakeBorder(img_in, bdr, bdr, bdr, bdr,cv2.BORDER_REPLICATE)

But I am not supposed to use the function cv2.copyMakeBorder. How do I do the same using just loops?

0 Answers
Related