Anim: Fix legacy/layered choice in action_fcurve_ensure()
Fix the code that decides whether to create a new F-Curve in a legacy or layered style. The old code went for layered if: - The experimental feature is enabled AND the Action is already layered. The new code goes for layered if: - The experimental feature is enabled AND the Action is empty, OR - The Action is already layered. Pull Request: https://projects.blender.org/blender/blender/pulls/128036
This commit is contained in:
@@ -2229,7 +2229,9 @@ FCurve *action_fcurve_ensure(Main *bmain,
|
||||
}
|
||||
Action &action = act->wrap();
|
||||
|
||||
if (USER_EXPERIMENTAL_TEST(&U, use_animation_baklava) && action.is_action_layered()) {
|
||||
if ((USER_EXPERIMENTAL_TEST(&U, use_animation_baklava) && action.is_empty()) ||
|
||||
!action.is_action_legacy())
|
||||
{
|
||||
/* NOTE: for layered actions we require the following:
|
||||
*
|
||||
* - `ptr` is non-null.
|
||||
|
||||
Reference in New Issue
Block a user