Morph Target flicker default target on visibility toggle

Hi Andrew!

No this is not what I meant, the included project is - rather stupid - example how to make the bug appear. I need to clarify a bit.

I make one assumption of ue : if I set morph target to some ratio and after I toggle visibility of the skeletal mesh, it remembers the ratio set before when it comes back to being visible.

Now the scenario :

  1. Set the morph target via timeline to blend it smoothly
  2. When done, switch the skeletal mesh to corresponding static mesh for performance. Done by hiding the skeletal mesh, and showing the static mesh via set visibility.
  3. New target is received, switch back to the skeletal mesh and begin morphing to a new target. Done by hiding the static mesh and making the skeletal mesh appear with set visibility. Continue at 2.

Now the problem comes with the part 3. When making the skeletal mesh become visible again, for a brief moment (frame or two) it shows the ORIGINAL skeletal mesh before “remembering” where it left off. This does not happen always only some times, it’s like vertex buffers are in wrong state when toggling visibility.

It is really easy to reproduce:

  1. Make a skeletal mesh that is for example a cube and that has one morph target which is a sphere.
  2. At game start set that morph target of that skeletal mesh to full showing the sphere.
  3. Make a timer or similar that just toggles between visible and hidden.

Now between the toggles You can see the mesh “flicker” the cube shape for couple of frames before showing the sphere shape what it should show. And note it does not always happen, only some times.

I don’t know if its my hardware or my model but i can easily produce this is in less complex scenarios than our game. Im fairly condifent we have the logic right as sometimes it does not flicker and works perfectly.

I can record a video or make a new project that shows this.

This is causing our game to show the annoying “flicker” to a point we needed to remove this.