Skip to content

Instance creation fails on some Android devices #788

Closed
@protyposis

Description

@protyposis

Describe the bug

I am testing projectM 4.1.0 on a few Android devices. The projectm_create() call seems to fail on some of them, with the following errors:

device/generic/goldfish-opengl/system/GLESv2_enc/GL2Encoder.cpp:s_glBindTexture:2200 GL error 0x500
device/generic/goldfish-opengl/system/GLESv2_enc/GL2Encoder.cpp:s_glBindTexture:2200 GL error 0x500

It doesn't crash though, and following projectm_opengl_render_frame calls just don't render anything. There are no further errors.

When using the debug build, the app crashes immediately at instance creation with

device/generic/goldfish-opengl/system/GLESv2_enc/GL2Encoder.cpp:s_glBindTexture:2200 GL error 0x500
/home/runner/work/projectm/projectm/src/libprojectM/ProjectM.cpp:216: void libprojectM::ProjectM::LoadIdlePreset(): assertion "m_activePreset" failed
Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 3526 (GLThread 302), pid 3499 (rojectm_android)
device/generic/goldfish-opengl/system/GLESv2_enc/GL2Encoder.cpp:s_glBindTexture:2200 GL error 0x500
pid: 3499, tid: 3526, name: GLThread 302  >>> com.github.projectm_android <<<
      #03 pc 00000000001e45f2  /data/app/~~He_o5QPBFnnIQzGw4CPYNQ==/com.github.projectm_android-GkXKDgCEHh5O_IsDoObXLQ==/lib/x86_64/libprojectM-4d.so (BuildId: 60346e06d5bd082c351491dae3427bc599f06743)
      #04 pc 00000000001e334b  /data/app/~~He_o5QPBFnnIQzGw4CPYNQ==/com.github.projectm_android-GkXKDgCEHh5O_IsDoObXLQ==/lib/x86_64/libprojectM-4d.so (BuildId: 60346e06d5bd082c351491dae3427bc599f06743)
      #05 pc 00000000001e2d2b  /data/app/~~He_o5QPBFnnIQzGw4CPYNQ==/com.github.projectm_android-GkXKDgCEHh5O_IsDoObXLQ==/lib/x86_64/libprojectM-4d.so (BuildId: 60346e06d5bd082c351491dae3427bc599f06743)
      #06 pc 00000000001e7548  /data/app/~~He_o5QPBFnnIQzGw4CPYNQ==/com.github.projectm_android-GkXKDgCEHh5O_IsDoObXLQ==/lib/x86_64/libprojectM-4d.so (BuildId: 60346e06d5bd082c351491dae3427bc599f06743)
      #07 pc 00000000001e74ca  /data/app/~~He_o5QPBFnnIQzGw4CPYNQ==/com.github.projectm_android-GkXKDgCEHh5O_IsDoObXLQ==/lib/x86_64/libprojectM-4d.so (projectm_create+58) (BuildId: 60346e06d5bd082c351491dae3427bc599f06743)
      #08 pc 00000000000016b4  /data/app/~~He_o5QPBFnnIQzGw4CPYNQ==/com.github.projectm_android-GkXKDgCEHh5O_IsDoObXLQ==/lib/x86_64/libjniwrapper.so (Java_com_github_projectm_1android_libprojectMJNIWrapper_onSurfaceCreated+164) (BuildId: faca253343119fef270b5a7c776d885dc2cc4d52)
      #16 pc 000000000000154a  [anon:dalvik-classes3.dex extracted in memory from /data/app/~~He_o5QPBFnnIQzGw4CPYNQ==/com.github.projectm_android-GkXKDgCEHh5O_IsDoObXLQ==/base.apk!classes3.dex] (com.github.projectm_android.RendererWrapper.onSurfaceCreated+58)

Using the release build and initializing a playlist with projectm_playlist_create, a crash doesn't happen until the first projectm_opengl_render_frame call:

terminating with uncaught exception of type libprojectM::Playlist::PlaylistEmptyException: Playlist is empty
Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 3912 (GLThread 321), pid 3886 (rojectm_android)
pid: 3886, tid: 3912, name: GLThread 321  >>> com.github.projectm_android <<<
      #02 pc 000000000018b59b  /data/app/~~4i_HRvxSdxZQiiyMHb9iQQ==/com.github.projectm_android-TZ-Lp0o8srLa7TlgfgPtwg==/lib/x86_64/libprojectM-4.so (BuildId: d0a1c00f9f255efd5aa4eac827857e17fe9b3a42)
      #03 pc 000000000018b78e  /data/app/~~4i_HRvxSdxZQiiyMHb9iQQ==/com.github.projectm_android-TZ-Lp0o8srLa7TlgfgPtwg==/lib/x86_64/libprojectM-4.so (BuildId: d0a1c00f9f255efd5aa4eac827857e17fe9b3a42)
      #04 pc 000000000018b642  /data/app/~~4i_HRvxSdxZQiiyMHb9iQQ==/com.github.projectm_android-TZ-Lp0o8srLa7TlgfgPtwg==/lib/x86_64/libprojectM-4.so (BuildId: d0a1c00f9f255efd5aa4eac827857e17fe9b3a42)
      #05 pc 000000000018ad45  /data/app/~~4i_HRvxSdxZQiiyMHb9iQQ==/com.github.projectm_android-TZ-Lp0o8srLa7TlgfgPtwg==/lib/x86_64/libprojectM-4.so (BuildId: d0a1c00f9f255efd5aa4eac827857e17fe9b3a42)
      #06 pc 000000000018accc  /data/app/~~4i_HRvxSdxZQiiyMHb9iQQ==/com.github.projectm_android-TZ-Lp0o8srLa7TlgfgPtwg==/lib/x86_64/libprojectM-4.so (__cxa_throw+108) (BuildId: d0a1c00f9f255efd5aa4eac827857e17fe9b3a42)
      #07 pc 0000000000008a34  /data/app/~~4i_HRvxSdxZQiiyMHb9iQQ==/com.github.projectm_android-TZ-Lp0o8srLa7TlgfgPtwg==/lib/x86_64/libprojectM-4-playlist.so (BuildId: eb3fb18f084886f0e08e046c2d0fd21aae5c5e9e)
      #08 pc 000000000000b74d  /data/app/~~4i_HRvxSdxZQiiyMHb9iQQ==/com.github.projectm_android-TZ-Lp0o8srLa7TlgfgPtwg==/lib/x86_64/libprojectM-4-playlist.so (BuildId: eb3fb18f084886f0e08e046c2d0fd21aae5c5e9e)
      #09 pc 000000000012cbcf  /data/app/~~4i_HRvxSdxZQiiyMHb9iQQ==/com.github.projectm_android-TZ-Lp0o8srLa7TlgfgPtwg==/lib/x86_64/libprojectM-4.so (BuildId: d0a1c00f9f255efd5aa4eac827857e17fe9b3a42)
      #10 pc 000000000012d490  /data/app/~~4i_HRvxSdxZQiiyMHb9iQQ==/com.github.projectm_android-TZ-Lp0o8srLa7TlgfgPtwg==/lib/x86_64/libprojectM-4.so (BuildId: d0a1c00f9f255efd5aa4eac827857e17fe9b3a42)
      #11 pc 00000000000016a4  /data/app/~~4i_HRvxSdxZQiiyMHb9iQQ==/com.github.projectm_android-TZ-Lp0o8srLa7TlgfgPtwg==/lib/x86_64/libjniwrapper.so (Java_com_github_projectm_1android_libprojectMJNIWrapper_onDrawFrame+52) (BuildId: 52b09f57788ed9ccb15398abc7c21c0f61671bf6)
      #19 pc 00000000000014ce  [anon:dalvik-classes3.dex extracted in memory from /data/app/~~4i_HRvxSdxZQiiyMHb9iQQ==/com.github.projectm_android-TZ-Lp0o8srLa7TlgfgPtwg==/base.apk!classes3.dex] (com.github.projectm_android.RendererWrapper.onDrawFrame+58)

When additionally loading presets into the playlist, I receive a projectm_playlist_preset_switch_failed_event on the first render call with error message std::exception, and afterwards it seems to enter an infinite loop trying to load the idle preset idle://Geiss & Sperl - Feedback (projectM idle HDR mix).milk and again failing all the time with error message std::exception.

Tested devices:

  • affected
    • Emulator (x86_64, API 30)
    • Google Pixel 7 (arm64-v8a, API 34)
  • not affected
    • OnePlus 6 (arm64-v8a, API 30)
    • Nvidia Shield TV (arm64-v8a, API 30)
    • Emulator (x86_64, API 31)
    • Emulator (x86_64, API 32)
    • Emulator (x86_64, API 33)
    • Emulator (x86_64, API 34)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions