[Bf-blender-cvs] [e5bb970] object_nodes: Renamed 'effector' data to 'point' data.
Lukas Tönne
noreply at git.blender.org
Tue Nov 24 09:43:30 CET 2015
Commit: e5bb9709e6b0d926df06f179c677cd5e56bdfbd1
Author: Lukas Tönne
Date: Mon Oct 26 12:27:31 2015 +0100
Branches: object_nodes
https://developer.blender.org/rBe5bb9709e6b0d926df06f179c677cd5e56bdfbd1
Renamed 'effector' data to 'point' data.
===================================================================
M release/scripts/startup/bl_operators/object_nodes.py
M source/blender/blenvm/bvm/bvm_eval.cc
M source/blender/blenvm/bvm/bvm_opcode.h
M source/blender/blenvm/compile/bvm_nodegraph.cc
M source/blender/blenvm/intern/bvm_api.cc
===================================================================
diff --git a/release/scripts/startup/bl_operators/object_nodes.py b/release/scripts/startup/bl_operators/object_nodes.py
index 76a9942..4d27d2f 100644
--- a/release/scripts/startup/bl_operators/object_nodes.py
+++ b/release/scripts/startup/bl_operators/object_nodes.py
@@ -43,7 +43,7 @@ node_categories = [
NodeItem("ForceFieldNode"),
]),
ForceFieldNodeCategory("INPUT", "Input", items=[
- NodeItem("ForceEffectorDataNode"),
+ NodeItem("ForcePointDataNode"),
]),
ForceFieldNodeCategory("FORCE_OUTPUT", "Output", items=[
NodeItem("ForceOutputNode"),
@@ -153,10 +153,10 @@ class CombineVectorNode(ForceNodeBase, ObjectNode):
self.outputs.new('NodeSocketVector', "Vector")
-class EffectorDataNode(ForceNodeBase, ObjectNode):
+class PointDataNode(ForceNodeBase, ObjectNode):
'''Input data of physical points'''
- bl_idname = 'ForceEffectorDataNode'
- bl_label = 'Effector Data'
+ bl_idname = 'ForcePointDataNode'
+ bl_label = 'Point Data'
def init(self, context):
self.outputs.new('NodeSocketVector', "Position")
diff --git a/source/blender/blenvm/bvm/bvm_eval.cc b/source/blender/blenvm/bvm/bvm_eval.cc
index 4bbdc24..65d134b 100644
--- a/source/blender/blenvm/bvm/bvm_eval.cc
+++ b/source/blender/blenvm/bvm/bvm_eval.cc
@@ -127,12 +127,12 @@ static void eval_op_get_elem_float3(float *stack, int index, StackIndex offset_f
stack_store_float(stack, offset_to, f[index]);
}
-static void eval_op_effector_position(const EvalData *data, float *stack, StackIndex offset)
+static void eval_op_point_position(const EvalData *data, float *stack, StackIndex offset)
{
stack_store_float3(stack, offset, data->effector.position);
}
-static void eval_op_effector_velocity(const EvalData *data, float *stack, StackIndex offset)
+static void eval_op_point_velocity(const EvalData *data, float *stack, StackIndex offset)
{
stack_store_float3(stack, offset, data->effector.velocity);
}
@@ -403,14 +403,14 @@ void EvalContext::eval_instructions(const EvalGlobals *globals, const EvalData *
eval_op_get_elem_float3(stack, index, offset_from, offset_to);
break;
}
- case OP_EFFECTOR_POSITION: {
+ case OP_POINT_POSITION: {
StackIndex offset = expr->read_stack_index(&instr);
- eval_op_effector_position(data, stack, offset);
+ eval_op_point_position(data, stack, offset);
break;
}
- case OP_EFFECTOR_VELOCITY: {
+ case OP_POINT_VELOCITY: {
StackIndex offset = expr->read_stack_index(&instr);
- eval_op_effector_velocity(data, stack, offset);
+ eval_op_point_velocity(data, stack, offset);
break;
}
case OP_ADD_FLOAT: {
diff --git a/source/blender/blenvm/bvm/bvm_opcode.h b/source/blender/blenvm/bvm/bvm_opcode.h
index 8396f84..1587b5e 100644
--- a/source/blender/blenvm/bvm/bvm_opcode.h
+++ b/source/blender/blenvm/bvm/bvm_opcode.h
@@ -44,8 +44,8 @@ enum OpCode {
OP_SET_FLOAT3,
OP_GET_ELEM_FLOAT3,
- OP_EFFECTOR_POSITION,
- OP_EFFECTOR_VELOCITY,
+ OP_POINT_POSITION,
+ OP_POINT_VELOCITY,
OP_ADD_FLOAT,
OP_SUB_FLOAT,
diff --git a/source/blender/blenvm/compile/bvm_nodegraph.cc b/source/blender/blenvm/compile/bvm_nodegraph.cc
index 4a06e63..aee45c0 100644
--- a/source/blender/blenvm/compile/bvm_nodegraph.cc
+++ b/source/blender/blenvm/compile/bvm_nodegraph.cc
@@ -559,8 +559,8 @@ OpCode get_opcode_from_node_type(const string &node)
NODETYPE(SET_FLOAT3);
NODETYPE(GET_ELEM_FLOAT3);
- NODETYPE(EFFECTOR_POSITION);
- NODETYPE(EFFECTOR_VELOCITY);
+ NODETYPE(POINT_POSITION);
+ NODETYPE(POINT_VELOCITY);
NODETYPE(ADD_FLOAT);
NODETYPE(SUB_FLOAT);
@@ -621,10 +621,10 @@ void register_opcode_node_types()
nt->add_input("value_z", BVM_FLOAT, 0.0f);
nt->add_output("value", BVM_FLOAT3, float3(0.0f, 0.0f, 0.0f));
- nt = NodeGraph::add_node_type("EFFECTOR_POSITION");
+ nt = NodeGraph::add_node_type("POINT_POSITION");
nt->add_output("value", BVM_FLOAT3, float3(0.0f, 0.0f, 0.0f));
- nt = NodeGraph::add_node_type("EFFECTOR_VELOCITY");
+ nt = NodeGraph::add_node_type("POINT_VELOCITY");
nt->add_output("value", BVM_FLOAT3, float3(0.0f, 0.0f, 0.0f));
#define BINARY_MATH_NODE(name) \
diff --git a/source/blender/blenvm/intern/bvm_api.cc b/source/blender/blenvm/intern/bvm_api.cc
index 368c53b..afa8ec9 100644
--- a/source/blender/blenvm/intern/bvm_api.cc
+++ b/source/blender/blenvm/intern/bvm_api.cc
@@ -277,13 +277,13 @@ static void gen_forcefield_nodegraph(Object *effob, bNodeTree *btree, bvm::NodeG
map_input_socket(input_map, bnode, 2, node, "value_z");
map_output_socket(output_map, bnode, 0, node, "value");
}
- else if (type == "ForceEffectorDataNode") {
+ else if (type == "ForcePointDataNode") {
{
- bvm::NodeInstance *node = graph.add_node("EFFECTOR_POSITION", "EFFECTOR_POS" + bvm::string(bnode->name));
+ bvm::NodeInstance *node = graph.add_node("POINT_POSITION", "POINT_POS" + bvm::string(bnode->name));
map_output_socket(output_map, bnode, 0, node, "value");
}
{
- bvm::NodeInstance *node = graph.add_node("EFFECTOR_VELOCITY", "EFFECTOR_VEL" + bvm::string(bnode->name));
+ bvm::NodeInstance *node = graph.add_node("POINT_VELOCITY", "POINT_VEL" + bvm::string(bnode->name));
map_output_socket(output_map, bnode, 1, node, "value");
}
}
More information about the Bf-blender-cvs
mailing list