[Bf-blender-cvs] [0f9757b12dd] master: Depsgraph: Cleanup, use anonymous nsamespace
Sergey Sharybin
noreply at git.blender.org
Wed Oct 30 15:18:11 CET 2019
Commit: 0f9757b12dd92c8beb684fb6d469ec9ded2a5010
Author: Sergey Sharybin
Date: Wed Oct 30 15:02:43 2019 +0100
Branches: master
https://developer.blender.org/rB0f9757b12dd92c8beb684fb6d469ec9ded2a5010
Depsgraph: Cleanup, use anonymous nsamespace
Jeeps overall line lengths with function definition shorter.
===================================================================
M source/blender/depsgraph/intern/builder/deg_builder_relations.cc
===================================================================
diff --git a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
index f1e7278ffdb..116cd07e6a5 100644
--- a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
+++ b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
@@ -120,10 +120,12 @@ namespace DEG {
/* ***************** */
/* Relations Builder */
+namespace {
+
/* TODO(sergey): This is somewhat weak, but we don't want neither false-positive
* time dependencies nor special exceptions in the depsgraph evaluation.
*/
-static bool python_driver_depends_on_time(ChannelDriver *driver)
+bool python_driver_depends_on_time(ChannelDriver *driver)
{
if (driver->expression[0] == '\0') {
/* Empty expression depends on nothing. */
@@ -144,7 +146,7 @@ static bool python_driver_depends_on_time(ChannelDriver *driver)
return false;
}
-static bool particle_system_depends_on_time(ParticleSystem *psys)
+bool particle_system_depends_on_time(ParticleSystem *psys)
{
ParticleSettings *part = psys->part;
/* Non-hair particles we always consider dependent on time. */
@@ -159,7 +161,7 @@ static bool particle_system_depends_on_time(ParticleSystem *psys)
return false;
}
-static bool object_particles_depends_on_time(Object *object)
+bool object_particles_depends_on_time(Object *object)
{
if (object->type != OB_MESH) {
return false;
@@ -172,7 +174,7 @@ static bool object_particles_depends_on_time(Object *object)
return false;
}
-static bool check_id_has_anim_component(ID *id)
+bool check_id_has_anim_component(ID *id)
{
AnimData *adt = BKE_animdata_from_id(id);
if (adt == NULL) {
@@ -181,11 +183,11 @@ static bool check_id_has_anim_component(ID *id)
return (adt->action != NULL) || (!BLI_listbase_is_empty(&adt->nla_tracks));
}
-static OperationCode bone_target_opcode(ID *target,
- const char *subtarget,
- ID *id,
- const char *component_subdata,
- RootPChanMap *root_map)
+OperationCode bone_target_opcode(ID *target,
+ const char *subtarget,
+ ID *id,
+ const char *component_subdata,
+ RootPChanMap *root_map)
{
/* Same armature. */
if (target == id) {
@@ -200,11 +202,13 @@ static OperationCode bone_target_opcode(ID *target,
return OperationCode::BONE_DONE;
}
-static bool object_have_geometry_component(const Object *object)
+bool object_have_geometry_component(const Object *object)
{
return ELEM(object->type, OB_MESH, OB_CURVE, OB_FONT, OB_SURF, OB_MBALL, OB_LATTICE, OB_GPENCIL);
}
+} // namespace
+
/* **** General purpose functions **** */
DepsgraphRelationBuilder::DepsgraphRelationBuilder(Main *bmain,
More information about the Bf-blender-cvs
mailing list