Description

https://udn.unrealengine.com/s/question/0D54z00009UJv5HCAT/lags-in-animation-when-set-leader-pose-component-is-used

From licensee:

"USkinnedMeshComponents have the option to double-buffer their bone transform data, and UE5.2 changed when the buffers are swapped. Previously it would happen during the PrePhysics tick (e.g. inside USkinnedMeshComponent::FlipEditableSpaceBases()), but now it occurs during the parallel end-of-frame render data update (downstream of USkinnedMeshComponent::SendRenderDynamicData_Concurrent()), which happens concurrently for all relevant components. This means that on some frames, some of the pose-follower components may be processed before the pose-leader, causing the follower to use the previous frame's bone data because the leader's buffers haven't yet been swapped.

We do have a tentative fix, namely separating out pose-loader components (USkinnedMeshComponents with "GetFollowerPoseComponents().Num() > 0") into their own array, instead of placing them into UWorld::ComponentsThatNeedEndOfFrameUpdate. Then inside UWorld::SendAllEndOfFrameUpdates() we fully process the pose-leader array (using an adapted version of the "ParallelWork" lambda) before processing the original array. This looks good in early tests and we're in the process of vetting it more thoroughly."

 

Also reported by another licensee: https://udn.unrealengine.com/s/question/0D54z00009RFRzOCAX/skin-cache-and-setleaderposecomponent

Steps to Reproduce

This is a race condition, I am only able to repro it by artificially staging it by messing in code.

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-191796 in the post.

6
Login to Vote

Fixed
Fix Commit30718389
Main Commit30718636
CreatedAug 2, 2023
ResolvedJan 19, 2024
UpdatedApr 5, 2024
View Jira Issue