Fix bug #33176: Deactivating both position and rotation target from iTaSC IK-Solver crashes Blender. No constraint is created for target in that case, just needed to add a check.
This commit is contained in:
@@ -1636,7 +1636,7 @@ static void execute_scene(Scene *blscene, IK_Scene *ikscene, bItasc *ikparam, fl
|
||||
// compute constraint error
|
||||
for (i = ikscene->targets.size(); i > 0; --i) {
|
||||
IK_Target *iktarget = ikscene->targets[i - 1];
|
||||
if (!(iktarget->blenderConstraint->flag & CONSTRAINT_OFF)) {
|
||||
if (!(iktarget->blenderConstraint->flag & CONSTRAINT_OFF) && iktarget->constraint) {
|
||||
unsigned int nvalues;
|
||||
const iTaSC::ConstraintValues *values;
|
||||
values = iktarget->constraint->getControlParameters(&nvalues);
|
||||
|
||||
Reference in New Issue
Block a user