Mediapipe: How to use mediapipe with camera1.0 or 2.0

Created on 4 Mar 2020  路  5Comments  路  Source: google/mediapipe

In android demo, mediapipe wrapped the camera and render functions in own way. It set cameraX as default choice. But there existed some projects used camera1.0 or 2.0, we want integrate mediapipe with these ones, for example: handtrackingGpu. What should we do for implementing this with codes?
Thanks~

android camera

Most helpful comment

I faced with same issue #472 . Unfortunately for this moment we have only one option with
androidx.camera:camera-core:1.0.0-alpha06 because mediapipe requires camera's surface texture instance.

All 5 comments

i have the same question,do you have any camera2.0 or camer1.0 demo for MediaPipe Android platform

I faced with same issue #472 . Unfortunately for this moment we have only one option with
androidx.camera:camera-core:1.0.0-alpha06 because mediapipe requires camera's surface texture instance.

FYI looking into fixing CameraX issues ASAP.

In the mean time, you can use a custom Camera2 utility and hook up a SurfaceTexture object to the ExternalTextureConverter as explained here: https://mediapipe.readthedocs.io/en/latest/hello_world_android.html#externaltextureconverter-setup.

@eknight7 Is there any plan to add support for Camera2 in the future? CameraX is unstable and has many functionalities missing (e.g. unable to select between multiple back or front cameras)!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

HebaMohamed picture HebaMohamed  路  5Comments

PrinceP picture PrinceP  路  5Comments

Choons picture Choons  路  4Comments

shraiwi picture shraiwi  路  5Comments

SwatiModi picture SwatiModi  路  5Comments