godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
90.82k stars 21.14k forks source link

Blend shapes glitches in the event that the node is duplicated #10402

Open DimaKiva opened 7 years ago

DimaKiva commented 7 years ago

Operating system or device - Godot version: Ubuntu16.04, Godot3.0 Alpha1

Issue description: The change in the form keys of the mesh is spoiled, in the event that the node is duplicated.

Steps to reproduce: Video Bug shape key.flv.zip

Link to minimal example project: Bug shape keys.zip

akien-mga commented 6 years ago

Is this still reproducible in Godot 3.0 RC1?

DimaKiva commented 6 years ago

On a duplicated mesh, the form change does not work

KoBeWi commented 5 years ago

The bug in video doesn't happen in 3.0.6 stable. However, there's probably another issue that changing blend shapes in the original node doesn't have any effect (works only when changing the duplicate node). Same happens in 3.1.1. Not sure if it should be like that.

KoBeWi commented 4 years ago

@DimaKiva Can you still reproduce this issue in 3.2.2?

nonunknown commented 4 years ago

@KoBeWi yes! check the last answer in this topic: #39112

nonunknown commented 4 years ago

Heres a video showcasing the problem in a depper way:

https://www.youtube.com/watch?v=_Be3nOfe0ao

Also I think in my humble opinion, since this post last since 2017, this bug should be roadmap for 4.0 and cherrypicked for 3.2

rarsp commented 4 years ago

I can confirm this bug. Blend shapes are broken!

My observation: problem is when there are many objects with the same mesh with blend shapes and they are having different key shape values meshes from other objects are drawn as triangles with background color on object.

Yukitty commented 3 years ago

I've found an at least partial workaround.

For all models which use blend shapes, add something like this before you apply the blend shapes in code: $MeshInstance.mesh.resource_local_to_scene = true

This will add severe overhead by duplicating the mesh resources themselves for each instance, but it does make blend shapes readily usable on multiple instances of the same mesh with minimal scripting effort.

lyuma commented 3 years ago

Still happens on 3.3.2 stable.

Here is a reproduction project. you can see a version called SpatialLocal where all the meshes were made local. DupMeshBlendShape.zip

Note that my project used features only available since 3.3, so it will produce wrong results on 3.2.3 or earlier engines