mediapipe
mediapipe copied to clipboard
E/AndroidRuntime: FATAL EXCEPTION: ExternalTextureConverter
- OS Platform and Distribution Linux Ubuntu 20.04,
- Android Emulator (API 28)
- Programming Language and version: Java
When I try to run the media pipe hand tracking app from the source code using Android Studio and the emulator, I obtain this exception:
E/AndroidRuntime: FATAL EXCEPTION: ExternalTextureConverter Process: com.google.mediapipe.apps.hands, PID: 10034 java.lang.RuntimeException: glViewport: GL error: 0x501 at com.google.mediapipe.glutil.ShaderUtil.checkGlError(ShaderUtil.java:175) at com.google.mediapipe.glutil.GlThread.bindFramebuffer(GlThread.java:117) at com.google.mediapipe.components.ExternalTextureConverter$RenderThread.updateOutputFrame(ExternalTextureConverter.java:485) at com.google.mediapipe.components.ExternalTextureConverter$RenderThread.renderNext(ExternalTextureConverter.java:389) at com.google.mediapipe.components.ExternalTextureConverter$RenderThread.lambda$onFrameAvailable$0$ExternalTextureConverter$RenderThread(ExternalTextureConverter.java:338) at com.google.mediapipe.components.-$$Lambda$ExternalTextureConverter$RenderThread$IXJjtE68JMV2CMJNQcFYhTUqhj8.run(Unknown Source:4) at android.os.Handler.handleCallback(Handler.java:873) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:193) at com.google.mediapipe.glutil.GlThread.run(GlThread.java:141)
P.S. I set the RUN_ON_GPU = false as suggested from the mediapipe android documentation for the emulator. Sometimes I see the camera and hand tracking for a few seconds before crashing.
This exception happens when I start the camera, but not if I upload an image
Thank you for your support!
Hi @nicolacapece, Did you try with any physical device and able to reproduce it. Thanks!
Thank you for your answer!
Yes, I tried the on the Huawei P20 and the system works correctly using the CPU. I attached an image.

However, I need to use the system on the emulator for research purposes.
Hi @sgowroji, Do you have any solution for the Android emulator?
Try checking the above with the latest configuration on emulator.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you.
Closing as stale. Please reopen if you'd like to work on this further.
@nicolacapece @sgowroji
Do you have any solution for this issue? I got the same error when running on Android emulator with API < 30.
2022-06-16 00:13:39.384 15441-15626/com.example.kt_editorvideodemo E/AndroidRuntime: FATAL EXCEPTION: ExternalTextureConverter
Process: com.example.demo, PID: 15441
java.lang.RuntimeException: glViewport: GL error: 0x501
at com.google.mediapipe.glutil.ShaderUtil.checkGlError(ShaderUtil.java:175)
at com.google.mediapipe.glutil.GlThread.bindFramebuffer(GlThread.java:117)
@sureshdagooglecom Could you help with this issue?
Also looking for a resolution for this issue. Can we pls re-open this?
Hello,
I got same error on Emulator for facemesh, facedetection and hands on Android emulator with API 30. There is no error for load picture. Only for load video and start camera there is a below error. Also i got a same error on physical device.
2022-11-30 20:53:27.099 5718-5718/com.google.mediapipe.apps.facemesh E/libEGL: validate_display:87 error 3008 (EGL_BAD_DISPLAY) 2022-11-30 20:53:27.463 5718-5766/com.google.mediapipe.apps.facemesh E/EGL_emulation: eglQueryContext 32c0 EGL_BAD_ATTRIBUTE 2022-11-30 20:53:27.463 5718-5766/com.google.mediapipe.apps.facemesh E/EGL_emulation: tid 5766: eglQueryContext(2019): error 0x3004 (EGL_BAD_ATTRIBUTE) 2022-11-30 20:53:27.889 5718-5760/com.google.mediapipe.apps.facemesh A/libc: Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x1c in tid 5760 (Thread-8), pid 5718 (e.apps.facemesh) 2022-11-30 20:53:28.025 5718-5766/com.google.mediapipe.apps.facemesh E/AndroidRuntime: FATAL EXCEPTION: ExternalTextureConverter Process: com.google.mediapipe.apps.facemesh, PID: 5718 java.lang.RuntimeException: glViewport: GL error: 0x501 at com.google.mediapipe.glutil.ShaderUtil.checkGlError(ShaderUtil.java:175) at com.google.mediapipe.glutil.GlThread.bindFramebuffer(GlThread.java:117) at com.google.mediapipe.components.ExternalTextureConverter$RenderThread.updateOutputFrame(ExternalTextureConverter.java:541) at com.google.mediapipe.components.ExternalTextureConverter$RenderThread.renderNext(ExternalTextureConverter.java:440) at com.google.mediapipe.components.ExternalTextureConverter$RenderThread.lambda$onFrameAvailable$0$ExternalTextureConverter$RenderThread(ExternalTextureConverter.java:386) at com.google.mediapipe.components.-$$Lambda$ExternalTextureConverter$RenderThread$IXJjtE68JMV2CMJNQcFYhTUqhj8.run(Unknown Source:4) at android.os.Handler.handleCallback(Handler.java:938) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:223) at com.google.mediapipe.glutil.GlThread.run(GlThread.java:141) 2022-11-30 20:53:28.068 5718-5776/com.google.mediapipe.apps.facemesh E/BufferQueueProducer: SurfaceTexture-1-5718-0 dequeueBuffer: BufferQueue has been abandoned 2022-11-30 20:53:28.078 5718-5776/com.google.mediapipe.apps.facemesh E/BufferQueueProducer: SurfaceTexture-1-5718-0 queueBuffer: BufferQueue has been abandoned 2022-11-30 20:53:28.097 5718-5786/com.google.mediapipe.apps.facemesh E/BufferQueueProducer: SurfaceTexture-1-5718-0 queueBuffer: BufferQueue has been abandoned
Hello @nicolacapece, We are upgrading the MediaPipe Legacy Solutions to new MediaPipe solutions However, the libraries, documentation, and source code for all the MediaPipe Legacy Solutions will continue to be available in our GitHub repository and through library distribution services, such as Maven and NPM.
You can continue to use those legacy solutions in your applications if you choose. Though, we would request you to check new MediaPipe solutions which can help you more easily build and customize ML solutions for your applications. These new solutions will provide a superset of capabilities available in the legacy solutions.
This issue has been marked stale because it has no recent activity since 7 days. It will be closed if no further activity occurs. Thank you.
This issue was closed due to lack of activity after being marked stale for past 7 days.