单目鸟瞰生成显示

This commit is contained in:
2025-12-19 14:18:20 +08:00
parent 2838e1097b
commit 5283a6f54a
5 changed files with 88 additions and 24 deletions

View File

@@ -5,22 +5,20 @@ import cv2
camera_names = ["front", "back", "left", "right"]
# --------------------------------------------------------------------
# (shift_width, shift_height): how far away the birdview looks outside
# of the calibration pattern in horizontal and vertical directions
# (shift_width, shift_height): 鸟瞰图在水平和垂直方向上超出标定图案的距离
shift_w = 300
shift_h = 300
# size of the gap between the calibration pattern and the car
# in horizontal and vertical directions
# 标定图案与车辆之间在水平和垂直方向上的间隙大小
inn_shift_w = 20
inn_shift_h = 50
# total width/height of the stitched image
# 拼接图像的总宽度/高度
total_w = 600 + 2 * shift_w
total_h = 1000 + 2 * shift_h
# four corners of the rectangular region occupied by the car
# top-left (x_left, y_top), bottom-right (x_right, y_bottom)
# 车辆所占矩形区域的四个角点
# 左上角 (x_left, y_top),右下角 (x_right, y_bottom)
xl = shift_w + 180 + inn_shift_w
xr = total_w - xl
yt = shift_h + 200 + inn_shift_h