Layers: get/update CollectionEngineSettings (depsgraph placeholder)

Every time:
  * A collection settings is set
  * A collection visibility changes
  * An object is added/removed/ ...

We need to recalculate the "accumulated" CollectionEngineSettings that
the render engine should use for an object.

This is to be handled by the depsgraph. Meanwhile this code should allow
us to start using those settings in the render engines.

Note: We are storing this in the objects, which means we can only have
one active calculated option every time.

This is intended to get the conversation with the Depsgraph department
going.
This commit is contained in:
Dalai Felinto
2017-02-07 16:54:09 +01:00
parent 6bf9c8ac89
commit 6432c8cc00
9 changed files with 205 additions and 33 deletions

View File

@@ -459,6 +459,11 @@ void BKE_object_free(Object *ob)
}
BKE_previewimg_free(&ob->preview);
if (ob->collection_settings) {
BKE_layer_collection_engine_settings_free(ob->collection_settings);
MEM_freeN(ob->collection_settings);
}
}
/* actual check for internal data, not context or flags */