Genymobile / scrcpy

Display and control your Android device
Apache License 2.0
111.58k stars 10.69k forks source link

Apps crash while scrcpy is in use. #319

Closed eku closed 6 years ago

eku commented 6 years ago

When scrcpy is in use, apps often crash.

scrpy version: HEAD host: Linux device: Android TV Box H96 stack:

 DEBUG   : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
 DEBUG   : Build fingerprint: 'Amlogic/q201_9377/q201_9377:7.1.2/NHG47L/20180710:user/test-keys'
 DEBUG   : Revision: '0'
 DEBUG   : ABI: 'arm'
 DEBUG   : pid: 12515, tid: 12585, name: RenderThread  >>> com.android.vending <<<
 DEBUG   : signal 6 (SIGABRT), code -6 (SI_TKILL), fault addr --------
 FASTGX_RC: base qp - 4:18
 DEBUG   : Abort message: 'Encountered EGL error 12291 EGL_BAD_ALLOC during rendering'
 DEBUG   :     r0 00000000  r1 00003129  r2 00000006  r3 00000008
 DEBUG   :     r4 cd37f978  r5 00000006  r6 cd37f920  r7 0000010c
 DEBUG   :     r8 cd3d7900  r9 00000000  sl e492983c  fp e4929838
 DEBUG   :     ip 00000009  sp cd37ef10  lr ee8508f7  pc ee853154  cpsr 20070010
 DEBUG   :
 DEBUG   : backtrace:
 DEBUG   :     #00 pc 0004a154  /system/lib/libc.so (tgkill+12)
 DEBUG   :     #01 pc 000478f3  /system/lib/libc.so (pthread_kill+34)
 DEBUG   :     #02 pc 0001dc15  /system/lib/libc.so (raise+10)
 DEBUG   :     #03 pc 00019761  /system/lib/libc.so (__libc_android_abort+34)
 DEBUG   :     #04 pc 00017348  /system/lib/libc.so (abort+4)
 DEBUG   :     #05 pc 0000c259  /system/lib/libcutils.so (__android_log_assert+112)
 DEBUG   :     #06 pc 000268c7  /system/lib/libhwui.so
 DEBUG   :     #07 pc 00023f01  /system/lib/libhwui.so
 DEBUG   :     #08 pc 00025a73  /system/lib/libhwui.so
 DEBUG   :     #09 pc 00029035  /system/lib/libhwui.so (_ZN7android10uirenderer12renderthread12RenderThread10threadLoopEv+80)
 DEBUG   :     #10 pc 0000e39d  /system/lib/libutils.so (_ZN7android6Thread11_threadLoopEPv+140)
 DEBUG   :     #11 pc 000666a5  /system/lib/libandroid_runtime.so (_ZN7android14AndroidRuntime15javaThreadShellEPv+80)
 DEBUG   :     #12 pc 000473c3  /system/lib/libc.so (_ZL15__pthread_startPv+22)
 DEBUG   :     #13 pc 0001a1ad  /system/lib/libc.so (__start_thread+6)
11-02 08:53:42.660  4181  4181 E DisplayDevice: [scrcpy] failed pushing new frame to HWC: -12
11-02 08:53:43.524  4236  4276 E BufferQueueProducer: [GraphicBufferSource] dequeueBuffer: attempting to exceed the max dequeued buffer count (1)
11-02 08:53:43.526  4181  4181 E SurfaceFlinger: [scrcpy] dequeueBuffer: no buffer, bailing out
11-02 08:53:43.526  4181  4181 E DisplayDevice: eglSwapBuffers(0x1, 0x7d9c04b240) failed with 0x0000300d
11-02 08:53:43.526  4181  4181 W SurfaceFlinger: [scrcpy] Unexpected advanceFrame() in GLES state on GLES/MIXED frame
11-02 08:53:43.526  4181  4181 E SurfaceFlinger: [scrcpy] advanceFrame: no buffer, bailing out

Any idea how I can avoid this?

rom1v commented 6 years ago

Encountered EGL error 12291 EGL_BAD_ALLOC during rendering

https://stackoverflow.com/questions/37568814/encountered-egl-error-12291-egl-bad-alloc-during-rendering/38779480

(no idea otherwise)

What if you reduce the definition (scrcpy -m 800)?

eku commented 6 years ago

Didn't know the option option -m. It runs more stable with reduced resolution. Thanks.