Fix #126632: Pose Breakdowner not interpolating all curves
Caused by 0f5dd1c55c
The refactor commit changed the arguments to receive a `Listbase` reference
instead of a pointer because in all use cases it was always passed.
As such the check for a `ListBase` null pointer went away.
However by removing JUST the nullptr check in this line
`if ((curves) || (flags & ACT_TRANS_LOC) == 0)`
to
`if ((flags & ACT_TRANS_LOC) == 0)`
I effectively changed the behavior.
Since `curves` was ALWAYS passed, the second condition never triggered.
With the change, this condition would always trigger, effectively only
adding the first FCurve of either location rotation or scale.
Pull Request: https://projects.blender.org/blender/blender/pulls/126642
This commit is contained in:
committed by
Christoph Lendenfeld
parent
529c720457
commit
69d50b2f4d
@@ -120,61 +120,47 @@ static eAction_TransformFlags get_item_transform_flags(Object &ob,
|
||||
bPtr += strlen(basePath->c_str());
|
||||
|
||||
/* Step 2: check for some property with transforms
|
||||
* - to speed things up, only check for the ones not yet found
|
||||
* unless we're getting the curves too
|
||||
* - if we're getting the curves, the BLI_genericNodeN() creates a LinkData
|
||||
* node wrapping the F-Curve, which then gets added to the list
|
||||
* - once a match has been found, the curve cannot possibly be any other one
|
||||
*/
|
||||
if ((flags & ACT_TRANS_LOC) == 0) {
|
||||
pPtr = strstr(bPtr, "location");
|
||||
if (pPtr) {
|
||||
flags |= ACT_TRANS_LOC;
|
||||
pPtr = strstr(bPtr, "location");
|
||||
if (pPtr) {
|
||||
flags |= ACT_TRANS_LOC;
|
||||
|
||||
BLI_addtail(&curves, BLI_genericNodeN(&fcurve));
|
||||
return;
|
||||
}
|
||||
BLI_addtail(&curves, BLI_genericNodeN(&fcurve));
|
||||
return;
|
||||
}
|
||||
|
||||
if ((flags & ACT_TRANS_SCALE) == 0) {
|
||||
pPtr = strstr(bPtr, "scale");
|
||||
if (pPtr) {
|
||||
flags |= ACT_TRANS_SCALE;
|
||||
pPtr = strstr(bPtr, "scale");
|
||||
if (pPtr) {
|
||||
flags |= ACT_TRANS_SCALE;
|
||||
|
||||
BLI_addtail(&curves, BLI_genericNodeN(&fcurve));
|
||||
return;
|
||||
}
|
||||
BLI_addtail(&curves, BLI_genericNodeN(&fcurve));
|
||||
return;
|
||||
}
|
||||
|
||||
if ((flags & ACT_TRANS_ROT) == 0) {
|
||||
pPtr = strstr(bPtr, "rotation");
|
||||
if (pPtr) {
|
||||
flags |= ACT_TRANS_ROT;
|
||||
pPtr = strstr(bPtr, "rotation");
|
||||
if (pPtr) {
|
||||
flags |= ACT_TRANS_ROT;
|
||||
|
||||
BLI_addtail(&curves, BLI_genericNodeN(&fcurve));
|
||||
return;
|
||||
}
|
||||
BLI_addtail(&curves, BLI_genericNodeN(&fcurve));
|
||||
return;
|
||||
}
|
||||
|
||||
if ((flags & ACT_TRANS_BBONE) == 0) {
|
||||
pPtr = strstr(bPtr, "bbone_");
|
||||
if (pPtr) {
|
||||
flags |= ACT_TRANS_BBONE;
|
||||
pPtr = strstr(bPtr, "bbone_");
|
||||
if (pPtr) {
|
||||
flags |= ACT_TRANS_BBONE;
|
||||
|
||||
BLI_addtail(&curves, BLI_genericNodeN(&fcurve));
|
||||
return;
|
||||
}
|
||||
BLI_addtail(&curves, BLI_genericNodeN(&fcurve));
|
||||
return;
|
||||
}
|
||||
|
||||
if ((flags & ACT_TRANS_PROP) == 0) {
|
||||
/* Custom properties only. */
|
||||
pPtr = strstr(bPtr, "[\"");
|
||||
if (pPtr) {
|
||||
flags |= ACT_TRANS_PROP;
|
||||
/* Custom properties only. */
|
||||
pPtr = strstr(bPtr, "[\"");
|
||||
if (pPtr) {
|
||||
flags |= ACT_TRANS_PROP;
|
||||
|
||||
BLI_addtail(&curves, BLI_genericNodeN(&fcurve));
|
||||
return;
|
||||
}
|
||||
BLI_addtail(&curves, BLI_genericNodeN(&fcurve));
|
||||
return;
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user