Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2016-11-03 14:14:47 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2016-11-07 13:04:49 +0300
commitf8d9a56aa113ff67fd0b5ba4436bef71f048a802 (patch)
treef77b76cb27f9b082eff3a4be16aff277d80d735c
parent4ef45ba7759880e88d93bfec44b57bbf8b9f1c1e (diff)
Depsgraph: Use const char for component API
-rw-r--r--source/blender/depsgraph/intern/builder/deg_builder_nodes.cc17
-rw-r--r--source/blender/depsgraph/intern/builder/deg_builder_nodes.h8
-rw-r--r--source/blender/depsgraph/intern/builder/deg_builder_relations.cc1
3 files changed, 15 insertions, 11 deletions
diff --git a/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc b/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc
index 8139cc3e1ae..ca5ee838917 100644
--- a/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc
+++ b/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc
@@ -177,7 +177,7 @@ TimeSourceDepsNode *DepsgraphNodeBuilder::add_time_source(ID *id)
ComponentDepsNode *DepsgraphNodeBuilder::add_component_node(
ID *id,
eDepsNode_Type comp_type,
- const string &comp_name)
+ const char *comp_name)
{
IDDepsNode *id_node = add_id_node(id);
ComponentDepsNode *comp_node = id_node->add_component(comp_type, comp_name);
@@ -198,7 +198,8 @@ OperationDepsNode *DepsgraphNodeBuilder::add_operation_node(
m_graph->operations.push_back(op_node);
}
else {
- fprintf(stderr, "add_operation: Operation already exists - %s has %s at %p\n",
+ fprintf(stderr,
+ "add_operation: Operation already exists - %s has %s at %p\n",
comp_node->identifier().c_str(),
op_node->identifier().c_str(),
op_node);
@@ -210,7 +211,7 @@ OperationDepsNode *DepsgraphNodeBuilder::add_operation_node(
OperationDepsNode *DepsgraphNodeBuilder::add_operation_node(
ID *id,
eDepsNode_Type comp_type,
- const string &comp_name,
+ const char *comp_name,
eDepsOperation_Type optype,
DepsEvalOperationCb op,
eDepsOperation_Code opcode,
@@ -233,17 +234,21 @@ OperationDepsNode *DepsgraphNodeBuilder::add_operation_node(
bool DepsgraphNodeBuilder::has_operation_node(ID *id,
eDepsNode_Type comp_type,
- const string &comp_name,
+ const char *comp_name,
eDepsOperation_Code opcode,
const string &description)
{
- return find_operation_node(id, comp_type, comp_name, opcode, description) != NULL;
+ return find_operation_node(id,
+ comp_type,
+ comp_name,
+ opcode,
+ description) != NULL;
}
OperationDepsNode *DepsgraphNodeBuilder::find_operation_node(
ID *id,
eDepsNode_Type comp_type,
- const string &comp_name,
+ const char *comp_name,
eDepsOperation_Code opcode,
const string &description)
{
diff --git a/source/blender/depsgraph/intern/builder/deg_builder_nodes.h b/source/blender/depsgraph/intern/builder/deg_builder_nodes.h
index 09d264c4b59..20fe6c5db92 100644
--- a/source/blender/depsgraph/intern/builder/deg_builder_nodes.h
+++ b/source/blender/depsgraph/intern/builder/deg_builder_nodes.h
@@ -76,7 +76,7 @@ struct DepsgraphNodeBuilder {
ComponentDepsNode *add_component_node(ID *id,
eDepsNode_Type comp_type,
- const string& comp_name = "");
+ const char *comp_name = "");
OperationDepsNode *add_operation_node(ComponentDepsNode *comp_node,
eDepsOperation_Type optype,
@@ -85,7 +85,7 @@ struct DepsgraphNodeBuilder {
const string& description = "");
OperationDepsNode *add_operation_node(ID *id,
eDepsNode_Type comp_type,
- const string& comp_name,
+ const char *comp_name,
eDepsOperation_Type optype,
DepsEvalOperationCb op,
eDepsOperation_Code opcode,
@@ -99,13 +99,13 @@ struct DepsgraphNodeBuilder {
bool has_operation_node(ID *id,
eDepsNode_Type comp_type,
- const string& comp_name,
+ const char *comp_name,
eDepsOperation_Code opcode,
const string& description = "");
OperationDepsNode *find_operation_node(ID *id,
eDepsNode_Type comp_type,
- const string &comp_name,
+ const char *comp_name,
eDepsOperation_Code opcode,
const string &description = "");
diff --git a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
index ba95576e790..86e222075fe 100644
--- a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
+++ b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
@@ -39,7 +39,6 @@
extern "C" {
#include "BLI_blenlib.h"
-#include "BLI_string.h"
#include "BLI_utildefines.h"
#include "DNA_action_types.h"