Merge branch 'master' into blender2.8
authorSergey Sharybin <sergey.vfx@gmail.com>
Thu, 1 Jun 2017 14:31:56 +0000 (16:31 +0200)
committerSergey Sharybin <sergey.vfx@gmail.com>
Thu, 1 Jun 2017 14:31:56 +0000 (16:31 +0200)
38 files changed:
1  2 
release/scripts/startup/bl_ui/properties_data_armature.py
release/scripts/startup/bl_ui/properties_data_camera.py
release/scripts/startup/bl_ui/properties_data_curve.py
release/scripts/startup/bl_ui/properties_data_lamp.py
release/scripts/startup/bl_ui/properties_data_metaball.py
release/scripts/startup/bl_ui/properties_game.py
release/scripts/startup/bl_ui/properties_material.py
release/scripts/startup/bl_ui/properties_object.py
release/scripts/startup/bl_ui/properties_particle.py
release/scripts/startup/bl_ui/properties_physics_dynamicpaint.py
release/scripts/startup/bl_ui/properties_physics_field.py
release/scripts/startup/bl_ui/properties_physics_smoke.py
release/scripts/startup/bl_ui/properties_texture.py
release/scripts/startup/bl_ui/properties_world.py
release/scripts/startup/bl_ui/space_view3d.py
release/scripts/startup/bl_ui/space_view3d_toolbar.py
source/blender/blenkernel/intern/editderivedmesh.c
source/blender/blenkernel/intern/group.c
source/blender/depsgraph/intern/builder/deg_builder_nodes.cc
source/blender/depsgraph/intern/builder/deg_builder_nodes.h
source/blender/depsgraph/intern/builder/deg_builder_nodes_layer.cc
source/blender/depsgraph/intern/builder/deg_builder_nodes_rig.cc
source/blender/depsgraph/intern/builder/deg_builder_nodes_scene.cc
source/blender/depsgraph/intern/builder/deg_builder_relations.cc
source/blender/depsgraph/intern/builder/deg_builder_relations.h
source/blender/depsgraph/intern/builder/deg_builder_relations_layer.cc
source/blender/depsgraph/intern/debug/deg_debug_graphviz.cc
source/blender/depsgraph/intern/depsgraph.cc
source/blender/depsgraph/intern/depsgraph.h
source/blender/depsgraph/intern/depsgraph_build.cc
source/blender/depsgraph/intern/depsgraph_types.h
source/blender/depsgraph/intern/eval/deg_eval.cc
source/blender/depsgraph/intern/eval/deg_eval_flush.cc
source/blender/depsgraph/intern/nodes/deg_node.cc
source/blender/depsgraph/intern/nodes/deg_node.h
source/blender/depsgraph/intern/nodes/deg_node_component.cc
source/blender/depsgraph/intern/nodes/deg_node_component.h
source/blender/editors/space_outliner/outliner_tools.c

index e4b5fd6ffecd58c9e69f92059d8eff5a45b525fb,1e51b8131e42eda8f9c33af0aa15bbb64caf03aa..eb8b175a423b4348e26bbfdd9be31eb6aadd34b1
@@@ -349,45 -317,25 +314,10 @@@ void DepsgraphNodeBuilder::build_group(
        }
  }
  
- SubgraphDepsNode *DepsgraphNodeBuilder::build_subgraph(Group *group)
- {
-       /* sanity checks */
-       if (!group)
-               return NULL;
-       /* create new subgraph's data */
-       Depsgraph *subgraph = reinterpret_cast<Depsgraph *>(DEG_graph_new());
-       DepsgraphNodeBuilder subgraph_builder(m_bmain, subgraph);
-       /* add group objects */
-       LINKLIST_FOREACH (GroupObject *, go, &group->gobject) {
-               /*Object *ob = go->ob;*/
-               /* Each "group object" is effectively a separate instance of the
-                * underlying object data. When the group is evaluated, the transform
-                * results and/or some other attributes end up getting overridden by
-                * the group.
-                */
-       }
-       /* Create a node for representing subgraph. */
-       SubgraphDepsNode *subgraph_node = m_graph->add_subgraph_node(&group->id);
-       subgraph_node->graph = subgraph;
-       /* Make a copy of the data this node will need? */
-       /* XXX: do we do this now, or later? */
-       /* TODO: need API function which queries graph's ID's hash, and duplicates
-        * those blocks thoroughly with all outside links removed.
-        */
-       return subgraph_node;
- }
 -void DepsgraphNodeBuilder::build_object(Scene *scene, Base *base, Object *ob)
 +void DepsgraphNodeBuilder::build_object(Scene *scene, Object *ob)
  {
 -      const bool has_object = (ob->id.tag & LIB_TAG_DOIT);
 -      IDDepsNode *id_node = (has_object)
 -              ? m_graph->find_id_node(&ob->id)
 -              : add_id_node(&ob->id);
 -      /* Update node layers.
 -       * Do it for both new and existing ID nodes. This is so because several
 -       * bases might be sharing same object.
 -       */
 -      if (base != NULL) {
 -              id_node->layers |= base->lay;
 -      }
 -      if (ob == scene->camera) {
 -              /* Camera should always be updated, it used directly by viewport. */
 -              id_node->layers |= (unsigned int)(-1);
 -      }
        /* Skip rest of components if the ID node was already there. */
 -      if (has_object) {
 +      if (ob->id.tag & LIB_TAG_DOIT) {
                return;
        }
        ob->id.tag |= LIB_TAG_DOIT;
index b6279ed4217b5f1e07b3136befab22b34b69e2b0,ba8a5d01cb00df147a0a6133f95aeb44715a2592..83a4dfda8a557647e3dd483fffcc9371219ad42f
@@@ -125,9 -121,8 +121,8 @@@ struct DepsgraphNodeBuilder 
                                               int name_tag = -1);
  
        void build_scene(Main *bmain, Scene *scene);
-       SubgraphDepsNode *build_subgraph(Group *group);
 -      void build_group(Scene *scene, Base *base, Group *group);
 -      void build_object(Scene *scene, Base *base, Object *ob);
 +      void build_group(Scene *scene, Group *group);
 +      void build_object(Scene *scene, Object *ob);
        void build_object_transform(Scene *scene, Object *ob);
        void build_object_constraints(Scene *scene, Object *ob);
        void build_pose_constraints(Scene *scene, Object *ob, bPoseChannel *pchan);
index 9fd59608d9ee51e91fefc62d69a5d3f6aa17752c,0000000000000000000000000000000000000000..e419b72fee8c81313721d8d72c22b342a35a3513
mode 100644,000000..100644
--- /dev/null
@@@ -1,120 -1,0 +1,117 @@@
-       ComponentDepsNode *comp = add_component_node(&scene->id, DEPSNODE_TYPE_LAYER_COLLECTIONS);
 +/*
 + * ***** BEGIN GPL LICENSE BLOCK *****
 + *
 + * This program is free software; you can redistribute it and/or
 + * modify it under the terms of the GNU General Public License
 + * as published by the Free Software Foundation; either version 2
 + * of the License, or (at your option) any later version.
 + *
 + * This program is distributed in the hope that it will be useful,
 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 + * GNU General Public License for more details.
 + *
 + * You should have received a copy of the GNU General Public License
 + * along with this program; if not, write to the Free Software Foundation,
 + * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 + *
 + * The Original Code is Copyright (C) 2013 Blender Foundation.
 + * All rights reserved.
 + *
 + * Original Author: Joshua Leung
 + * Contributor(s): Based on original depsgraph.c code - Blender Foundation (2005-2013)
 + *
 + * ***** END GPL LICENSE BLOCK *****
 + */
 +
 +/** \file blender/depsgraph/intern/builder/deg_builder_nodes_scene.cc
 + *  \ingroup depsgraph
 + *
 + * Methods for constructing depsgraph's nodes
 + */
 +
 +#include "intern/builder/deg_builder_nodes.h"
 +
 +#include <stdio.h>
 +#include <stdlib.h>
 +
 +#include "MEM_guardedalloc.h"
 +
 +extern "C" {
 +#include "BLI_utildefines.h"
 +
 +#include "BKE_layer.h"
 +
 +#include "DNA_scene_types.h"
 +
 +#include "DEG_depsgraph.h"
 +#include "DEG_depsgraph_build.h"
 +} /* extern "C" */
 +
 +#include "intern/builder/deg_builder.h"
 +#include "intern/nodes/deg_node.h"
 +#include "intern/nodes/deg_node_component.h"
 +#include "intern/nodes/deg_node_operation.h"
 +#include "intern/depsgraph_types.h"
 +#include "intern/depsgraph_intern.h"
 +#include "util/deg_util_foreach.h"
 +
 +namespace DEG {
 +
 +void DepsgraphNodeBuilder::build_layer_collection(Scene *scene,
 +                                                  LayerCollection *layer_collection,
 +                                                  LayerCollectionState *state)
 +{
 +      /* TODO(sergey): This will attempt to create component for each collection.
 +       * Harmless but could be optimized.
 +       */
-                          DEPSOP_TYPE_EXEC,
++      ComponentDepsNode *comp = add_component_node(&scene->id, DEG_NODE_TYPE_LAYER_COLLECTIONS);
 +
 +      add_operation_node(comp,
-               ComponentDepsNode *comp = add_component_node(&scene->id, DEPSNODE_TYPE_LAYER_COLLECTIONS);
 +                         function_bind(BKE_layer_eval_layer_collection,
 +                                       _1,
 +                                       layer_collection,
 +                                       state->parent),
 +                         DEG_OPCODE_SCENE_LAYER_EVAL,
 +                         layer_collection->scene_collection->name,
 +                         state->index);
 +      ++state->index;
 +
 +      /* Recurs into nested layer collections. */
 +      LayerCollection *parent = state->parent;
 +      state->parent = layer_collection;
 +      build_layer_collections(scene, &layer_collection->layer_collections, state);
 +      state->parent = parent;
 +}
 +
 +void DepsgraphNodeBuilder::build_layer_collections(Scene *scene,
 +                                                   ListBase *layer_collections,
 +                                                   LayerCollectionState *state)
 +{
 +      LINKLIST_FOREACH (LayerCollection *, layer_collection, layer_collections) {
 +              build_layer_collection(scene, layer_collection, state);
 +      }
 +}
 +
 +void DepsgraphNodeBuilder::build_scene_layer_collections(Scene *scene)
 +{
 +      LayerCollectionState state;
 +      state.index = 0;
 +      LINKLIST_FOREACH (SceneLayer *, scene_layer, &scene->render_layers) {
-                                  DEPSOP_TYPE_EXEC,
++              ComponentDepsNode *comp = add_component_node(&scene->id, DEG_NODE_TYPE_LAYER_COLLECTIONS);
 +
 +              add_operation_node(comp,
-                                  DEPSOP_TYPE_EXEC,
 +                                 function_bind(BKE_layer_eval_layer_collection_pre, _1, scene, scene_layer),
 +                                 DEG_OPCODE_SCENE_LAYER_INIT,
 +                                 scene_layer->name);
 +              add_operation_node(comp,
 +                                 function_bind(BKE_layer_eval_layer_collection_post, _1, scene_layer),
 +                                 DEG_OPCODE_SCENE_LAYER_DONE,
 +                                 scene_layer->name);
 +
 +              state.parent = NULL;
 +              build_layer_collections(scene, &scene_layer->layer_collections, &state);
 +      }
 +}
 +
 +}  // namespace DEG
index 46bef7a0131a5dcde4bbadf827d7333f166c4da3,0000000000000000000000000000000000000000..a6c9fdfc6bc7a271bbce740f6d2c7b7225d36935
mode 100644,000000..100644
--- /dev/null
@@@ -1,134 -1,0 +1,127 @@@
-                              DEPSNODE_TYPE_LAYER_COLLECTIONS,
 +/*
 + * ***** BEGIN GPL LICENSE BLOCK *****
 + *
 + * This program is free software; you can redistribute it and/or
 + * modify it under the terms of the GNU General Public License
 + * as published by the Free Software Foundation; either version 2
 + * of the License, or (at your option) any later version.
 + *
 + * This program is distributed in the hope that it will be useful,
 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 + * GNU General Public License for more details.
 + *
 + * You should have received a copy of the GNU General Public License
 + * along with this program; if not, write to the Free Software Foundation,
 + * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 + *
 + * The Original Code is Copyright (C) 2013 Blender Foundation.
 + * All rights reserved.
 + *
 + * Original Author: Joshua Leung
 + * Contributor(s): Based on original depsgraph.c code - Blender Foundation (2005-2013)
 + *
 + * ***** END GPL LICENSE BLOCK *****
 + */
 +
 +/** \file blender/depsgraph/intern/builder/deg_builder_relations_scene.cc
 + *  \ingroup depsgraph
 + *
 + * Methods for constructing depsgraph
 + */
 +
 +#include "intern/builder/deg_builder_relations.h"
 +
 +#include <stdio.h>
 +#include <stdlib.h>
 +#include <cstring>  /* required for STREQ later on. */
 +
 +#include "MEM_guardedalloc.h"
 +
 +extern "C" {
 +#include "BLI_blenlib.h"
 +#include "BLI_utildefines.h"
 +
 +#include "DNA_node_types.h"
 +#include "DNA_object_types.h"
 +#include "DNA_scene_types.h"
 +
 +#include "BKE_layer.h"
 +#include "BKE_main.h"
 +#include "BKE_node.h"
 +
 +#include "DEG_depsgraph.h"
 +#include "DEG_depsgraph_build.h"
 +} /* extern "C" */
 +
 +#include "intern/builder/deg_builder.h"
 +#include "intern/builder/deg_builder_pchanmap.h"
 +
 +#include "intern/nodes/deg_node.h"
 +#include "intern/nodes/deg_node_component.h"
 +#include "intern/nodes/deg_node_operation.h"
 +
 +#include "intern/depsgraph_intern.h"
 +#include "intern/depsgraph_types.h"
 +
 +#include "util/deg_util_foreach.h"
 +
 +namespace DEG {
 +
 +void DepsgraphRelationBuilder::build_layer_collection(Scene *scene,
 +                                                      LayerCollection *layer_collection,
 +                                                      LayerCollectionState *state)
 +{
 +      OperationKey layer_key(&scene->id,
-       add_relation(state->prev_key,
-                    layer_key,
-                    DEPSREL_TYPE_OPERATION,
-                    "Layer collection order");
++                             DEG_NODE_TYPE_LAYER_COLLECTIONS,
 +                             DEG_OPCODE_SCENE_LAYER_EVAL,
 +                             layer_collection->scene_collection->name,
 +                             state->index);
-                                     DEPSNODE_TYPE_LAYER_COLLECTIONS,
++      add_relation(state->prev_key, layer_key, "Layer collection order");
 +
 +      ++state->index;
 +      state->prev_key = layer_key;
 +
 +      /* Recurs into nested layer collections. */
 +      build_layer_collections(scene,
 +                              &layer_collection->layer_collections,
 +                              state);
 +}
 +
 +void DepsgraphRelationBuilder::build_layer_collections(Scene *scene,
 +                                                       ListBase *layer_collections,
 +                                                       LayerCollectionState *state)
 +{
 +      LINKLIST_FOREACH (LayerCollection *, layer_collection, layer_collections) {
 +              /* Recurs into the layer. */
 +              build_layer_collection(scene, layer_collection, state);
 +      }
 +}
 +
 +void DepsgraphRelationBuilder::build_scene_layer_collections(Scene *scene)
 +{
 +      LayerCollectionState state;
 +      state.index = 0;
 +      LINKLIST_FOREACH (SceneLayer *, scene_layer, &scene->render_layers) {
 +              OperationKey init_key(&scene->id,
-                                     DEPSNODE_TYPE_LAYER_COLLECTIONS,
++                                    DEG_NODE_TYPE_LAYER_COLLECTIONS,
 +                                    DEG_OPCODE_SCENE_LAYER_INIT,
 +                                    scene_layer->name);
 +              OperationKey done_key(&scene->id,
-               add_relation(state.prev_key,
-                            done_key,
-                            DEPSREL_TYPE_OPERATION,
-                            "Layer collection order");
++                                    DEG_NODE_TYPE_LAYER_COLLECTIONS,
 +                                    DEG_OPCODE_SCENE_LAYER_DONE,
 +                                    scene_layer->name);
 +
 +              state.init_key = init_key;
 +              state.done_key = done_key;
 +              state.prev_key = init_key;
 +
 +              build_layer_collections(scene,
 +                                      &scene_layer->layer_collections,
 +                                      &state);
 +
++              add_relation(state.prev_key, done_key, "Layer collection order");
 +      }
 +}
 +
 +}  // namespace DEG
index 6e2d8759200efce63b0a3f78f92465ce5d8e3616,8da3e097d07229206ecaa2023e8695fee2b0a554..a38419e7effa91724fb758b216456d1dc75e3130
@@@ -77,22 -77,20 +77,21 @@@ static const char *deg_debug_colors_lig
  
  #ifdef COLOR_SCHEME_NODE_TYPE
  static const int deg_debug_node_type_color_map[][2] = {
-     {DEPSNODE_TYPE_ROOT,         0},
-     {DEPSNODE_TYPE_TIMESOURCE,   1},
-     {DEPSNODE_TYPE_ID_REF,       2},
-     {DEPSNODE_TYPE_SUBGRAPH,     3},
+     {DEG_NODE_TYPE_ROOT,         0},
+     {DEG_NODE_TYPE_TIMESOURCE,   1},
+     {DEG_NODE_TYPE_ID_REF,       2},
  
      /* Outer Types */
-     {DEPSNODE_TYPE_PARAMETERS,        4},
-     {DEPSNODE_TYPE_PROXY,             5},
-     {DEPSNODE_TYPE_ANIMATION,         6},
-     {DEPSNODE_TYPE_TRANSFORM,         7},
-     {DEPSNODE_TYPE_GEOMETRY,          8},
-     {DEPSNODE_TYPE_SEQUENCER,         9},
-     {DEPSNODE_TYPE_SHADING,           10},
-     {DEPSNODE_TYPE_CACHE,             11},
-     {DEPSNODE_TYPE_LAYER_COLLECTIONS, 12},
 -    {DEG_NODE_TYPE_PARAMETERS,   3},
 -    {DEG_NODE_TYPE_PROXY,        4},
 -    {DEG_NODE_TYPE_ANIMATION,    5},
 -    {DEG_NODE_TYPE_TRANSFORM,    6},
 -    {DEG_NODE_TYPE_GEOMETRY,     7},
 -    {DEG_NODE_TYPE_SEQUENCER,    8},
 -    {DEG_NODE_TYPE_SHADING,      9},
 -    {DEG_NODE_TYPE_CACHE,        10},
 -    {-1,                         0}
++    {DEG_NODE_TYPE_PARAMETERS,        3},
++    {DEG_NODE_TYPE_PROXY,             4},
++    {DEG_NODE_TYPE_ANIMATION,         5},
++    {DEG_NODE_TYPE_TRANSFORM,         6},
++    {DEG_NODE_TYPE_GEOMETRY,          7},
++    {DEG_NODE_TYPE_SEQUENCER,         8},
++    {DEG_NODE_TYPE_SHADING,           9},
++    {DEG_NODE_TYPE_CACHE,             10},
++    {DEG_NODE_TYPE_LAYER_COLLECTIONS, 11},
 +    {-1,                              0}
  };
  #endif
  
@@@ -180,7 -178,7 +179,7 @@@ static void deg_debug_graphviz_legend(c
  #ifdef COLOR_SCHEME_NODE_TYPE
        const int (*pair)[2];
        for (pair = deg_debug_node_type_color_map; (*pair)[0] >= 0; ++pair) {
--              DepsNodeFactory *nti = DEG_get_node_factory((eDepsNode_Type)(*pair)[0]);
++              DepsNodeFactory *nti = DEG_get_node_factory((eDEG_NODE_TYPE)(*pair)[0]);
                deg_debug_graphviz_legend_color(ctx,
                                                nti->tname().c_str(),
                                                deg_debug_colors_light[(*pair)[1] % deg_debug_max_colors]);
@@@ -287,7 -285,13 +286,7 @@@ static void deg_debug_graphviz_node_sin
        const char *shape = "box";
        string name = node->identifier();
        float priority = -1.0f;
-       if (ctx.show_eval_priority && node->tclass == DEPSNODE_CLASS_OPERATION) {
 -      if (node->type == DEG_NODE_TYPE_ID_REF) {
 -              IDDepsNode *id_node = (IDDepsNode *)node;
 -              char buf[256];
 -              BLI_snprintf(buf, sizeof(buf), " (Layers: %u)", id_node->layers);
 -              name += buf;
 -      }
+       if (ctx.show_eval_priority && node->tclass == DEG_NODE_CLASS_OPERATION) {
                priority = ((OperationDepsNode *)node)->eval_priority;
        }
        deg_debug_fprintf(ctx, "// %s\n", name.c_str());
@@@ -369,31 -379,17 +368,18 @@@ static void deg_debug_graphviz_node(con
                        }
                        break;
                }
-               case DEPSNODE_TYPE_SUBGRAPH:
-               {
-                       SubgraphDepsNode *sub_node = (SubgraphDepsNode *)node;
-                       if (sub_node->graph) {
-                               deg_debug_graphviz_node_cluster_begin(ctx, node);
-                               deg_debug_graphviz_graph_nodes(ctx, sub_node->graph);
-                               deg_debug_graphviz_node_cluster_end(ctx);
-                       }
-                       else {
-                               deg_debug_graphviz_node_single(ctx, node);
-                       }
-                       break;
-               }
-               case DEPSNODE_TYPE_PARAMETERS:
-               case DEPSNODE_TYPE_ANIMATION:
-               case DEPSNODE_TYPE_TRANSFORM:
-               case DEPSNODE_TYPE_PROXY:
-               case DEPSNODE_TYPE_GEOMETRY:
-               case DEPSNODE_TYPE_SEQUENCER:
-               case DEPSNODE_TYPE_EVAL_POSE:
-               case DEPSNODE_TYPE_BONE:
-               case DEPSNODE_TYPE_SHADING:
-               case DEPSNODE_TYPE_CACHE:
-               case DEPSNODE_TYPE_LAYER_COLLECTIONS:
-               case DEPSNODE_TYPE_EVAL_PARTICLES:
+               case DEG_NODE_TYPE_PARAMETERS:
+               case DEG_NODE_TYPE_ANIMATION:
+               case DEG_NODE_TYPE_TRANSFORM:
+               case DEG_NODE_TYPE_PROXY:
+               case DEG_NODE_TYPE_GEOMETRY:
+               case DEG_NODE_TYPE_SEQUENCER:
+               case DEG_NODE_TYPE_EVAL_POSE:
+               case DEG_NODE_TYPE_BONE:
+               case DEG_NODE_TYPE_SHADING:
+               case DEG_NODE_TYPE_CACHE:
++              case DEG_NODE_TYPE_LAYER_COLLECTIONS:
+               case DEG_NODE_TYPE_EVAL_PARTICLES:
                {
                        ComponentDepsNode *comp_node = (ComponentDepsNode *)node;
                        if (!comp_node->operations.empty()) {
index 6b9a6e0191ed3943a4cc4b90ce940816eb3cd335,c6960bf1351a6886839e40b3e07454bbe5b7189c..2668ff70d7f584e5c89d977f179e67f008aae8f4
@@@ -126,17 -120,15 +120,17 @@@ typedef enum eDepsNode_Type 
        /* **** Evaluation-Related Outer Types (with Subdata) **** */
  
        /* Pose Component - Owner/Container of Bones Eval */
-       DEPSNODE_TYPE_EVAL_POSE,
+       DEG_NODE_TYPE_EVAL_POSE,
        /* Bone Component - Child/Subcomponent of Pose */
-       DEPSNODE_TYPE_BONE,
+       DEG_NODE_TYPE_BONE,
        /* Particle Systems Component */
-       DEPSNODE_TYPE_EVAL_PARTICLES,
+       DEG_NODE_TYPE_EVAL_PARTICLES,
        /* Material Shading Component */
-       DEPSNODE_TYPE_SHADING,
+       DEG_NODE_TYPE_SHADING,
        /* Cache Component */
-       DEPSNODE_TYPE_CACHE,
+       DEG_NODE_TYPE_CACHE,
 +      /* Component which contains all operations needed for layer collections evaluation. */
-       DEPSNODE_TYPE_LAYER_COLLECTIONS,
++      DEG_NODE_TYPE_LAYER_COLLECTIONS,
  } eDepsNode_Type;
  
  /* Identifiers for common operations (as an enum). */
index a2bc38a7b5e8b856ad0ad1718c60d3b1a5025247,e8dbe8e84eb13b9f31956d8b565786b3dbaad353..046037d8b1d3cbfe754dd996e0b85905e8cf78b3
@@@ -142,9 -148,11 +142,9 @@@ static void calculate_pending_func(voi
        node->scheduled = false;
  
        /* count number of inputs that need updates */
 -      if ((id_node->layers & layers) != 0 &&
 -          (node->flag & DEPSOP_FLAG_NEEDS_UPDATE) != 0)
 -      {
 +      if ((node->flag & DEPSOP_FLAG_NEEDS_UPDATE) != 0) {
                foreach (DepsRelation *rel, node->inlinks) {
-                       if (rel->from->type == DEPSNODE_TYPE_OPERATION &&
+                       if (rel->from->type == DEG_NODE_TYPE_OPERATION &&
                            (rel->flag & DEPSREL_FLAG_CYCLIC) == 0)
                        {
                                OperationDepsNode *from = (OperationDepsNode *)rel->from;
index afcf699425328fc243e57cb3a73523ef43c1d7b7,963c16c3a13b6cbeddf3a2e9174836a89619fb86..34abbf46ed74f42f16e417c5f16b93e6151289d6
@@@ -165,30 -165,28 +165,29 @@@ void deg_graph_flush_updates(Main *bmai
                                         * layers visibility update has proper flags to work with.
                                         */
                                        switch (comp_node->type) {
-                                               case DEPSNODE_TYPE_UNDEFINED:
-                                               case DEPSNODE_TYPE_OPERATION:
-                                               case DEPSNODE_TYPE_ROOT:
-                                               case DEPSNODE_TYPE_TIMESOURCE:
-                                               case DEPSNODE_TYPE_ID_REF:
-                                               case DEPSNODE_TYPE_SUBGRAPH:
-                                               case DEPSNODE_TYPE_PARAMETERS:
-                                               case DEPSNODE_TYPE_SEQUENCER:
-                                               case DEPSNODE_TYPE_LAYER_COLLECTIONS:
+                                               case DEG_NODE_TYPE_UNDEFINED:
+                                               case DEG_NODE_TYPE_OPERATION:
+                                               case DEG_NODE_TYPE_ROOT:
+                                               case DEG_NODE_TYPE_TIMESOURCE:
+                                               case DEG_NODE_TYPE_ID_REF:
+                                               case DEG_NODE_TYPE_PARAMETERS:
+                                               case DEG_NODE_TYPE_SEQUENCER:
++                                              case DEG_NODE_TYPE_LAYER_COLLECTIONS:
                                                        /* Ignore, does not translate to object component. */
                                                        break;
-                                               case DEPSNODE_TYPE_ANIMATION:
+                                               case DEG_NODE_TYPE_ANIMATION:
                                                        object->recalc |= OB_RECALC_TIME;
                                                        break;
-                                               case DEPSNODE_TYPE_TRANSFORM:
+                                               case DEG_NODE_TYPE_TRANSFORM:
                                                        object->recalc |= OB_RECALC_OB;
                                                        break;
-                                               case DEPSNODE_TYPE_GEOMETRY:
-                                               case DEPSNODE_TYPE_EVAL_POSE:
-                                               case DEPSNODE_TYPE_BONE:
-                                               case DEPSNODE_TYPE_EVAL_PARTICLES:
-                                               case DEPSNODE_TYPE_SHADING:
-                                               case DEPSNODE_TYPE_CACHE:
-                                               case DEPSNODE_TYPE_PROXY:
+                                               case DEG_NODE_TYPE_GEOMETRY:
+                                               case DEG_NODE_TYPE_EVAL_POSE:
+                                               case DEG_NODE_TYPE_BONE:
+                                               case DEG_NODE_TYPE_EVAL_PARTICLES:
+                                               case DEG_NODE_TYPE_SHADING:
+                                               case DEG_NODE_TYPE_CACHE:
+                                               case DEG_NODE_TYPE_PROXY:
                                                        object->recalc |= OB_RECALC_DATA;
                                                        break;
                                        }
index cf6224a3d82157c01b0cec9225a8f4bc2735ab50,0171fd9ac2531104a06f8b6c9294832b53bd7d7a..7a8c4494230f83c5fdcbe9222a51c821d0795155
@@@ -399,13 -402,9 +398,13 @@@ static DepsNodeFactoryImpl<ShadingCompo
  
  /* Cache Component Defines ============================ */
  
- DEG_DEPSNODE_DEFINE(CacheComponentDepsNode, DEPSNODE_TYPE_CACHE, "Cache Component");
+ DEG_DEPSNODE_DEFINE(CacheComponentDepsNode, DEG_NODE_TYPE_CACHE, "Cache Component");
  static DepsNodeFactoryImpl<CacheComponentDepsNode> DNTI_CACHE;
  
- DEG_DEPSNODE_DEFINE(LayerCollectionsDepsNode, DEPSNODE_TYPE_LAYER_COLLECTIONS, "Layer Collections Component");
 +/* Layer Collections Defines ============================ */
 +
++DEG_DEPSNODE_DEFINE(LayerCollectionsDepsNode, DEG_NODE_TYPE_LAYER_COLLECTIONS, "Layer Collections Component");
 +static DepsNodeFactoryImpl<LayerCollectionsDepsNode> DNTI_LAYER_COLLECTIONS;
  
  /* Node Types Register =================================== */
  
index 3f1f6a9d12d077d7c882101e0092af39caa0bd6d,d1392b6c07efebee8a5de0b3f7b234b956c24797..0591a8674d3393c4b1d60185eb3e5d85ace3040d
@@@ -399,18 -398,21 +399,18 @@@ static void object_deselect_cb
  }
  
  static void object_delete_cb(
-         bContext *C, ReportList *reports, Scene *scene, TreeElement *UNUSED(te),
-         TreeStoreElem *UNUSED(tsep), TreeStoreElem *tselem, void *UNUSED(user_data))
+         bContext *C, ReportList *reports, Scene *scene, TreeElement *te,
+         TreeStoreElem *tsep, TreeStoreElem *tselem, void *user_data)
  {
 -      Base *base = (Base *)te->directdata;
 -      
 -      if (base == NULL)
 -              base = BKE_scene_base_find(scene, (Object *)tselem->id);
 -      if (base) {
 +      Object *ob = (Object *)tselem->id;
 +      if (ob) {
                Main *bmain = CTX_data_main(C);
 -              if (base->object->id.tag & LIB_TAG_INDIRECT) {
 -                      BKE_reportf(reports, RPT_WARNING, "Cannot delete indirectly linked object '%s'", base->object->id.name + 2);
 +              if (ob->id.tag & LIB_TAG_INDIRECT) {
 +                      BKE_reportf(reports, RPT_WARNING, "Cannot delete indirectly linked object '%s'", ob->id.name + 2);
                        return;
                }
 -              else if (BKE_library_ID_is_indirectly_used(bmain, base->object) &&
 -                       ID_REAL_USERS(base->object) <= 1 && ID_EXTRA_USERS(base->object) == 0)
 +              else if (BKE_library_ID_is_indirectly_used(bmain, ob) &&
 +                       ID_REAL_USERS(ob) <= 1 && ID_EXTRA_USERS(ob) == 0)
                {
                        BKE_reportf(reports, RPT_WARNING,
                                    "Cannot delete object '%s' from scene '%s', indirectly used objects need at least one user",