godot: Godot 3.1 RC2 create_trimesh_collision() and create_convex_collision() lead to instant crash on Android
Godot version: 3.1 RC2
OS/device including version: Oukitel K6000 Pro, Android 6.0 Samsung Galaxy J5, Android 7
Issue description:
The methods create_convex_collision() and create_trimesh_collision() of MeshInstance (https://docs.godotengine.org/en/latest/classes/class_meshinstance.html lead to an instant crash on Android.
The last version I tested was 3.1 beta 7, there it worked, so it seems it was introduced in some of the last betas.
I think this is the relevant error description from logcat:
03-12 17:30:47.191 32301 32317 E godot : ERROR: OpenGL ES 2.0 does not allow retrieving mesh array data 03-12 17:30:47.191 32301 32317 E godot : At: drivers/gles2/rasterizer_storage_gles2.cpp:2541:mesh_surface_get_array() - OpenGL ES 2.0 does not allow retrieving mesh array data 03-12 17:30:47.191 32301 32317 E godot : ERROR: Condition ’ vertex_data.size() == 0 ’ is true. returned: Array() 03-12 17:30:47.191 32301 32317 E godot : At: servers/visual_server.cpp:1606:mesh_surface_get_arrays() - Condition ’ vertex_data.size() == 0 ’ is true. returned: Array() 03-12 17:30:47.191 32301 32317 E godot : ERROR: FATAL: Index p_index=0 out of size (((Vector<T> *)(this))->_cowdata.size()=0) 03-12 17:30:47.191 32301 32317 E godot : At: ./core/vector.h:49:operator - FATAL: Index p_index=0 out of size (((Vector<T> *)(this))->_cowdata.size()=0) 03-12 17:30:47.277 32343 32343 I AEE/AED : #00 pc 000000000164c5d8 /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.277 32343 32343 I AEE/AED : #01 pc 00000000010946ac /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.277 32343 32343 I AEE/AED : #02 pc 0000000000c1270c /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.277 32343 32343 I AEE/AED : #03 pc 0000000000c12854 /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.277 32343 32343 I AEE/AED : #04 pc 000000000034c1e4 /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.277 32343 32343 I AEE/AED : #05 pc 00000000016ce8b8 /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.277 32343 32343 I AEE/AED : #06 pc 0000000001781c80 /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.278 32343 32343 I AEE/AED : #07 pc 000000000028d6e0 /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.278 32343 32343 I AEE/AED : #08 pc 000000000024a738 /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.278 32343 32343 I AEE/AED : #09 pc 00000000008b58fc /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.278 32343 32343 I AEE/AED : #10 pc 0000000000bdd92c /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.278 32343 32343 I AEE/AED : #11 pc 0000000000c15654 /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.278 32343 32343 I AEE/AED : #12 pc 00000000016cb16c /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.278 32343 32343 I AEE/AED : #13 pc 00000000008b72dc /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.278 32343 32343 I AEE/AED : #14 pc 00000000008b726c /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.278 32343 32343 I AEE/AED : #15 pc 00000000008b726c /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.278 32343 32343 I AEE/AED : #16 pc 00000000008bc6a0 /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.278 32343 32343 I AEE/AED : #17 pc 00000000008e97b8 /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so 03-12 17:30:47.278 32343 32343 I AEE/AED : #18 pc 00000000001a5a84 /data/app/com.example.crashTest-1/lib/arm64/libgodot_android.so (Java_org_godotengine_godot_GodotLib_step+80) 03-12 17:30:47.278 32343 32343 I AEE/AED : #19 pc 000000000027d0a8 /data/app/com.example.crashTest-1/oat/arm64/base.odex (offset 0x147000) (void org.godotengine.godot.GodotLib.step()+124) 03-12 17:30:47.279 32343 32343 I AEE/AED : #20 pc 0000000000281f80 /data/app/com.example.crashTest-1/oat/arm64/base.odex (offset 0x147000) (void org.godotengine.godot.GodotView$Renderer.onDrawFrame(javax.microedition.khronos.opengles.GL10)+84) 03-12 17:30:47.594 942 32344 W ActivityManager: Force finishing activity com.example.crashTest/org.godotengine.godot.Godot 03-12 17:30:47.649 942 959 V WindowManager: Changing focus from Window{e32c239 u0 com.example.crashTest/org.godotengine.godot.Godot} to Window{3be8bb7 u0 Application Error: com.example.crashTest} Callers=com.android.server.wm.WindowManagerService.addWindow:2821 com.android.server.wm.Session.addToDisplay:171 android.view.ViewRootImpl.setView:647 android.view.WindowManagerGlobal.addView:319 03-12 17:30:47.649 942 963 I WindowManager: Focus moving from Window{e32c239 u0 com.example.crashTest/org.godotengine.godot.Godot} to Window{3be8bb7 u0 Application Error: com.example.crashTest} 03-12 17:30:47.703 942 963 I WindowManager: Losing delayed focus: Window{e32c239 u0 com.example.crashTest/org.godotengine.godot.Godot} 03-12 17:30:47.714 268 970 I BufferQueueProducer: com.example.crashTest/org.godotengine.godot.Godot disconnect(P): api 1 03-12 17:30:47.715 268 970 I BufferQueueConsumer: com.example.crashTest/org.godotengine.godot.Godot getReleasedBuffers: returning mask 0xffffffffffffffff 03-12 17:30:47.717 942 1815 I WindowState: WIN DEATH: Window{e32c239 u0 com.example.crashTest/org.godotengine.godot.Godot} 03-12 17:30:47.777 942 1678 V WindowManager: Removing focused app token:AppWindowToken{edbb8cd token=Token{df0be64 ActivityRecord{97c8ff7 u0 com.example.crashTest/org.godotengine.godot.Godot t148}}} 03-12 17:30:47.837 268 268 I BufferQueueConsumer: com.example.crashTest/org.godotengine.godot.Godot setDefaultBufferSize: width=1080 height=1920 03-12 17:30:47.838 942 1678 W WindowState: Failed to report ‘resized’ to the client of Window{e32c239 u0 com.example.crashTest/org.godotengine.godot.Godot}, removing this window. 03-12 17:30:47.841 268 384 D SurfaceFlinger: remove: com.example.crashTest/org.godotengine.godot.Godot 03-12 17:30:47.855 268 268 I BufferQueueConsumer: com.example.crashTest/org.godotengine.godot.Godot disconnect© 03-12 17:30:47.857 268 268 I BufferQueue: com.example.crashTest/org.godotengine.godot.Godot ~BufferQueueCore
Steps to reproduce:
- Create a new project
- Add a MeshInstance Object to the tree
- Execute
create_convex_collision()orcreate_trimesh_collision()
Minimal reproduction project:
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 15 (6 by maintainers)
@lawnjelly It seems I’ve successfully compiled a custom template for Linux/X11 from master and it appears to be working; the game runs and the collision meshes get generated, but it does give the error:
So it appears the error message might be redundant but I have not tested it on a system with Only support for GLES2.
I’ve just experienced the same issue on Windows 10 when using create_convex_collision or create_outline with GLES2 enabled in Godot v3.1.stable.official.
Only happened in the exported project, everything worked fine in the editor.