Hello OpenCV Community
On Android C++ I’m getting empty frames from cv::VideoCapture:read() basically im doing this:
VideoCapture camera;
camera.open(index, mode);
if (camera.isOpened())//it's ok here
return 0.0;
cv::Mat frame;
bool ret = camera.read(frame);//return true
//buff_img it's my buffer that I send to surface, but on android it's empty
std::memcpy(buff_img, frame_.data, frame_.total()*4);
This code works perfectly on Windows, iOS, MacOS and I need make it work on Android
Exactly same issue was experimented by someone else in this post: How to open camera with cv::VideoCapture in Android Native C++ - Stack Overflow
First the problem was build the custom framework and get video features and now are that frames are empty.
(I can see that the camera it’s opened, due a light that appear when the camera it’s on use)
Any idea of how handle it?
Regards