[Bf-blender-cvs] [ff98b5eaa80] master: Depsgraph: Clarify comment in the component node
Sergey Sharybin
noreply at git.blender.org
Tue Jul 19 12:17:20 CEST 2022
Commit: ff98b5eaa805d411f967921eca7bea24f24ea4dc
Author: Sergey Sharybin
Date: Tue Jul 19 11:27:50 2022 +0200
Branches: master
https://developer.blender.org/rBff98b5eaa805d411f967921eca7bea24f24ea4dc
Depsgraph: Clarify comment in the component node
===================================================================
M source/blender/depsgraph/intern/node/deg_node_component.h
===================================================================
diff --git a/source/blender/depsgraph/intern/node/deg_node_component.h b/source/blender/depsgraph/intern/node/deg_node_component.h
index 6958866af3b..b31881a96c0 100644
--- a/source/blender/depsgraph/intern/node/deg_node_component.h
+++ b/source/blender/depsgraph/intern/node/deg_node_component.h
@@ -56,12 +56,14 @@ struct ComponentNode : public Node {
virtual string identifier() const override;
- /* Find an existing operation, if requested operation does not exist
- * nullptr will be returned. */
+ /* Find an existing operation, if requested operation does not exist nullptr will be returned.
+ * See #add_operation for the meaning and examples of #name and #name_tag.
+ */
OperationNode *find_operation(OperationIDKey key) const;
OperationNode *find_operation(OperationCode opcode, const char *name, int name_tag) const;
- /* Find an existing operation, will throw an assert() if it does not exist. */
+ /* Find an existing operation, will throw an assert() if it does not exist.
+ * See #add_operation for the meaning and examples of #name and #name_tag. */
OperationNode *get_operation(OperationIDKey key) const;
OperationNode *get_operation(OperationCode opcode, const char *name, int name_tag) const;
@@ -71,12 +73,19 @@ struct ComponentNode : public Node {
/**
* Create a new node for representing an operation and add this to graph
+ *
* \warning If an existing node is found, it will be modified. This helps
* when node may have been partially created earlier (e.g. parent ref before
* parent item is added)
*
* \param opcode: The operation to perform.
- * \param name: Identifier for operation - used to find/locate it again.
+ * \param name: An optional identifier for operation. It will be used to tell operation nodes
+ * with the same code apart. For example, parameter operation code will have name
+ * set to the corresponding custom property name
+ * \param name_tag: An optional integer tag for the name. Is an additional way to tell operations
+ * apart. For example, RNA path to an array property will have the same opcode
+ * of PARAMETERS, name corresponding to the property name, and name tag
+ * corresponding to the array index within the property.
*/
OperationNode *add_operation(const DepsEvalOperationCb &op,
OperationCode opcode,
More information about the Bf-blender-cvs
mailing list