Fix #114948: Parenting crash blender since ObjectRuntime refactor
Caused by 4bcdc57fc8
This commit is contained in:
@@ -49,6 +49,7 @@
|
||||
#include "BKE_lib_query.h"
|
||||
#include "BKE_main.h"
|
||||
#include "BKE_object.hh"
|
||||
#include "BKE_object_types.hh"
|
||||
#include "BKE_preview_image.hh"
|
||||
|
||||
#include "DEG_depsgraph.hh"
|
||||
@@ -1708,7 +1709,9 @@ void what_does_obaction(Object *ob,
|
||||
bActionGroup *agrp = BKE_action_group_find_name(act, groupname);
|
||||
|
||||
/* clear workob */
|
||||
blender::bke::ObjectRuntime workob_runtime;
|
||||
BKE_object_workob_clear(workob);
|
||||
workob->runtime = &workob_runtime;
|
||||
|
||||
/* init workob */
|
||||
copy_m4_m4(workob->object_to_world, ob->object_to_world);
|
||||
|
||||
@@ -3383,7 +3383,9 @@ void BKE_object_where_is_calc(Depsgraph *depsgraph, Scene *scene, Object *ob)
|
||||
|
||||
void BKE_object_workob_calc_parent(Depsgraph *depsgraph, Scene *scene, Object *ob, Object *workob)
|
||||
{
|
||||
blender::bke::ObjectRuntime workob_runtime;
|
||||
BKE_object_workob_clear(workob);
|
||||
workob->runtime = &workob_runtime;
|
||||
|
||||
unit_m4(workob->object_to_world);
|
||||
unit_m4(workob->parentinv);
|
||||
|
||||
Reference in New Issue
Block a user