#Animation panics with "index out of bounds" when 2 key shapes are present

3 messages · Page 1 of 1 (latest)

coral grove
#

I have recently started testing bevy for use in a personal project, I have been testing importing simple animations made in blender, but, I have found a constant crash with the animation.

index out of bounds: the len is 7 but the index is 7
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Encountered a panic in system `bevy_animation::animation_player`!
Encountered a panic in system `bevy_app::main_schedule::Main::run_main`!```

I have found that by not using key shapes it doesn't happen anymore, and then I found that by using a single key shape it doesn't happen either, the problem appears when importing a file with 2 key shape.

I have tried different blender export options with no luck, and I have made no progress in figuring out the problem or how to fix it since I lack the skill and experience to do so.

Test project containing code, exported .glb assets, blender files:
https://github.com/Parrot14/bevy_test-animation

Panic source?:
https://github.com/bevyengine/bevy/blob/release-0.13.0/crates/bevy_animation/src/lib.rs#L785

OS: Archlinux
Bevy Version: 0.13.0
Blender Version: 4.0 (Flatpak)

It's my mistake, some issue with bevy or blender export? I am lost

Thanks in advance
zinc lion
coral grove
# zinc lion If my experience with reading texture files is any indication there’s a good cha...

First of all, I made a mistake, they are called "shape keys" and not "key shapes", each shape key defines a different shape to the object by altering the position of the vertexes, and then you can transition between these states during the animation. They are also known as "morph targets" or "blend shapes" according to the blender site: https://docs.blender.org/manual/en/latest/animation/shape_keys/introduction.html

Sorry for the poor quality of the video.

Thanks.