이 프로그램에서는 이미지 주위에 테두리를 그립니다. openCV 라이브러리에서 copyMakeBorder() 메서드를 사용합니다. 이 함수는 이미지, 위쪽, 아래쪽, 왼쪽, 오른쪽 테두리 값과 같은 다양한 매개변수를 사용합니다.
원본 이미지

알고리즘
Step 1: Import cv2. Step 2: Read the image. Step 3: Dall the cv2.copymakeborder() method. Step 4: Display the output.
예시 코드
import cv2
image = cv2.imread('testimage.jpg')
image = cv2.copyMakeBorder(image, 10,10,10,10, cv2.BORDER_CONSTANT)
cv2.imshow('Border', image) 출력
