修正无需旋转的返回值

This commit is contained in:
2024-06-25 15:35:36 +08:00
parent e4516fc4b2
commit e00c33b5af

View File

@@ -107,7 +107,7 @@ def get_image_rotation_angle(img):
# 旋转图片 # 旋转图片
def rotate_image(img, angle): def rotate_image(img, angle):
if angle == 0: if angle == 0:
return return img
height, width, _ = img.shape height, width, _ = img.shape
if angle == 180: if angle == 180:
new_width = width new_width = width