Alembic export: avoid BLI_assert() failure when object is not in depsgraph
When the object we iterate over is not part of the depsgraph, we cannot get the evaluated copy to export. This workaround is temporary to avoid a BLI_assert() failure getting the evaluated mesh of this object. This will be handled more elegantly in the new AbstractHierarchyIterator that I'm working on, but that requires a bigger change than we should allow this close to the 2.80 release candidate. This fixes a problem described in T58686.
This commit is contained in:
parent
e927ce8acb
commit
0829bd7b66
|
@ -165,6 +165,15 @@ static bool export_object(const ExportSettings *const settings,
|
|||
}
|
||||
}
|
||||
|
||||
Object *ob_eval = DEG_get_evaluated_object(settings->depsgraph, base->object);
|
||||
if ((ob_eval->id.tag & LIB_TAG_COPIED_ON_WRITE) == 0) {
|
||||
/* XXX fix after 2.80: the object was not part of the depsgraph, and thus we cannot get the
|
||||
* evaluated copy to export. This will be handled more elegantly in the new
|
||||
* AbstractHierarchyIterator that Sybren is working on. This condition is temporary, and avoids
|
||||
* a BLI_assert() failure getting the evaluated mesh of this object. */
|
||||
return false;
|
||||
}
|
||||
|
||||
// if (settings->renderable_only && (ob->restrictflag & OB_RESTRICT_RENDER)) {
|
||||
// return false;
|
||||
// }
|
||||
|
|
Loading…
Reference in New Issue