Problems implementing a divided image in my code

Joined
Jun 18, 2024
Messages
1
Reaction score
0
Hi! I´m doing camera calibration using a sterio vision camera and i´m having problems. My sterio vision camera has the same ID for the both images so i decided to devide the images in two and giving the names camera0 for the left image and camera0 to the right image. The problem i´m facing is implementing this in my code because i previously had a YAML file with the setting that i needed and now i cannot put this python file in my code. Can someone help me please?

This is the link for the original code that im using: https://github.com/TemugeB/python_stereo_camera_calibrate/blob/main/calib.py

And this is the code that i need to split the images in two:
cap=cv2.VideoCapture(0)
cap.set(cv2.CAP_PROP_FRAME_HEIGHT, 480)
cap.set(cv2.CAP_PROP_FRAME_WIDTH, frame_width)
poly = False
while True:
#captura de imagem
result, frame = cap.read()
if result:
camera0 = frame[:, :half]
camera1= frame[:, half:]
camera0=0
camera1=1
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,871
Messages
2,569,919
Members
46,171
Latest member
A.N.Omalum

Latest Threads

Top