Open stewie146 opened 3 years ago
You might need to use UVC Camera and hook up its surfaceTexture and surfaceView herewith mediapipe. Take a look at - https://github.com/saki4510t/UVCCamera or https://github.com/jiangdongguo/AndroidUSBCamera
I was able to integrate all of the code from AndroidUSBCamera with the mediapipe pose detection repo. However, the display frames get stuck on the following code:
mCameraHelper?.setOnPreviewFrameListener(AbstractUVCCameraHandler.OnPreViewResultListener() { nv21Yuv ->
previewFrameTexture = mUVCCameraView!!.surfaceTexture
})
If I comment the previewFrameTexture assignment, the camera frames are displayed on the screen but I get egl_bad_surface-errors
.
we have a usb camera attached to the dev board running this git, and it give us the following error:
Unable to get ProcessCameraProvider: java.util.concurrent.ExecutionException: androidx.camera.core.InitializationException: java.lang.NumberFormatException: For input string: "/dev/video10"
it seems this error is invoked because the camera is not build-in camera but usb/external camera.
any idea how to solve this problem ? appreciated !