Is there a way to open either of the cameras with opencv? I have the phone turned off now, but I am pretty sure it had devices video0-video3. I tried them all in the following code, and was met was a basic error that it couldn’t open the v4l2 device, and couldn’t generate the window, or just that it can’t generate the window.
This is python.
import cv2 print(cv2.__version__) cam=cv2.VideoCapture(0) while True: _, frame=cam.read() cv2.imshow('cam',frame) if cv2.waitKey(1)==ord('q'): break cam.release() cv2.destroyAllWindows()
On almost any system with python, opencv, and a camera at video 0, this should open a window called “cam” and display video from camera 0. Any advice to get it working on the pinephone would be appreciated.