2.5
Small fixes for animsys: - Blender 2.4x allowed drivers to exist without object target, these got converted resulting in error prints. Now they get skipped. - Animdata struct was not created for objects with poses, but without action/nla linked. - An action-channel-constraint-ipo gets inserted in drivers differently than a pose-bone-constraint-ipo. Not sure yet how... but it makes a different depsgraph relation. Error is of course in depsgraph, that'll get tackled. For correct driver eval I've made 'object update ob' also been called for the 'object update data' tag.
This commit is contained in:
@@ -1190,8 +1190,13 @@ static void ipo_to_animato (Ipo *ipo, char actname[], char constname[], ListBase
|
||||
/* Since an IPO-Curve may end up being made into many F-Curves (i.e. bitflag curves),
|
||||
* we figure out the best place to put the channel, then tell the curve-converter to just dump there
|
||||
*/
|
||||
if (icu->driver)
|
||||
icu_to_fcurves(drivers, icu, actname, constname);
|
||||
if (icu->driver) {
|
||||
/* Blender 2.4x allowed empty drivers */
|
||||
if(icu->driver->ob || icu->driver->type == IPO_DRIVER_TYPE_PYTHON)
|
||||
icu_to_fcurves(drivers, icu, actname, constname);
|
||||
else
|
||||
MEM_freeN(icu->driver);
|
||||
}
|
||||
else
|
||||
icu_to_fcurves(anim, icu, actname, constname);
|
||||
|
||||
@@ -1401,6 +1406,10 @@ void do_versions_ipos_to_animato(Main *main)
|
||||
|
||||
/* check PoseChannels for constraints with local data */
|
||||
if (ob->pose) {
|
||||
|
||||
/* Verify if there's AnimData block */
|
||||
BKE_id_add_animdata(id);
|
||||
|
||||
for (pchan= ob->pose->chanbase.first; pchan; pchan= pchan->next) {
|
||||
for (con= pchan->constraints.first; con; con= con->next) {
|
||||
/* if constraint has own IPO, convert add these to Object
|
||||
|
||||
@@ -2268,7 +2268,9 @@ void object_handle_update(Scene *scene, Object *ob)
|
||||
{
|
||||
if(ob->recalc & OB_RECALC) {
|
||||
|
||||
if(ob->recalc & OB_RECALC_OB) {
|
||||
/* XXX new animsys warning: depsgraph tag OB_RECALC_DATA should not skip drivers,
|
||||
which is only in where_is_object now */
|
||||
if(ob->recalc & OB_RECALC) {
|
||||
|
||||
if (G.f & G_DEBUG)
|
||||
printf("recalcob %s\n", ob->id.name+2);
|
||||
|
||||
Reference in New Issue
Block a user