Reputation: 23
I have 2 xiaomi smartphones: Xiaomi Redmi 3 (lineageOS, Android 11) and Xiaomi Mi9 lite (MIUI, Android 10). (The goal is to use Redmi 3 on my pet project). I tried to run the same piece of code on both devices, but its work only with Mi9 lite.
import cv2
cam = cv2.VideoCapture(0)
s, img = cam.read()
cv2.imwrite('qqq.jpg', img)
On redmi 3 I've got the error:
looks like some premission issue, cause opencv cant get the image from camera. And idk how to solve that, i already got Pydroid permission plugin but that doesnt work.
Upvotes: 0
Views: 583
Reputation: 23
Looks like pydroid can work properly only with Camera 2 API.
But redmi 3 camera has not that technology:
Upvotes: 0