Fix T51907: New Depsgraph - Camera constraint is not evaluated properly

This is more a workaround for until we've got proper visibility flush, which
will likely happen in blender2.8 branch.
This commit is contained in:
Sergey Sharybin 2017-08-24 14:35:48 +02:00
parent 436d1b4e90
commit a679457263
Notes: blender-bot 2024-04-11 14:26:06 +02:00
Referenced by issue #51907, New Depsgraph - Camera constraint is not evaluated properly
1 changed files with 5 additions and 2 deletions

View File

@ -320,8 +320,11 @@ void DepsgraphNodeBuilder::build_object(Scene *scene, Base *base, Object *ob)
if (base != NULL) {
id_node->layers |= base->lay;
}
if (ob == scene->camera) {
/* Camera should always be updated, it used directly by viewport. */
if (ob->type == OB_CAMERA) {
/* Camera should always be updated, it used directly by viewport.
*
* TODO(sergey): Make it only for active scene camera.
*/
id_node->layers |= (unsigned int)(-1);
}
/* Skip rest of components if the ID node was already there. */