Closed AllenDang closed 1 year ago
@nicopap I know the core dev of bevy may not have time to fix it now, I'm wondering if you or anyone could give me a hint about where should I start to look at, I could start fixing this and contribute a PR.
It looks like the texture format is the culprit here, try saving the model textures in a different format
@nicopap This model could be normally imported and rendered in various engines including Godot/Unreal/Unity/Raylib, so I'm thinking about to fix the compatibility of bevy.
I'm not sure what is causing this. I think you might some luck looking at the code that the following PR changed https://github.com/bevyengine/bevy/pull/5527
Otherwise, it would be in the GLTF loader (bevy_gltf/src/loader.rs iirc) you'd need to make sure the image data is properly handled when the GLTF is loaded.
One of the texture in the glb file is in a format not expected by Bevy. If I manually convert it to another format, it renders:
Short term, you can use the converted glb file here: PIPIXIA-converted.glb.zip (I'm not very good at image conversion, so I also compressed it. I didn't notice any worse quality)
Longer term, Bevy could convert the texture when loading the glb file to a supported format
@mockersf Can you tell me which texture causes this issue?
I think it was the normals
@mockersf Thanks, I'll see what I can do there.
Should be fixed by #9611
Bevy version
0.9.0
What you did
Spawn a scene from a glb file and bevy crashed.
Error message is
It could be rendered normally via gltf viewer.
Here is the glb file leads to the crash. PIPIXIA.glb.zip