diff options
Diffstat (limited to 'source/blender/nodes')
18 files changed, 0 insertions, 623 deletions
diff --git a/source/blender/nodes/CMakeLists.txt b/source/blender/nodes/CMakeLists.txt index 4172dc06a9f..78b3e6236f0 100644 --- a/source/blender/nodes/CMakeLists.txt +++ b/source/blender/nodes/CMakeLists.txt @@ -230,21 +230,7 @@ set(SRC shader/node_shader_tree.c shader/node_shader_util.c - simulation/nodes/node_sim_age_reached_event.cc simulation/nodes/node_sim_common.cc - simulation/nodes/node_sim_emit_particles.cc - simulation/nodes/node_sim_execute_condition.cc - simulation/nodes/node_sim_force.cc - simulation/nodes/node_sim_kill_particle.cc - simulation/nodes/node_sim_multi_execute.cc - simulation/nodes/node_sim_particle_attribute.cc - simulation/nodes/node_sim_particle_birth_event.cc - simulation/nodes/node_sim_particle_mesh_collision_event.cc - simulation/nodes/node_sim_particle_mesh_emitter.cc - simulation/nodes/node_sim_particle_simulation.cc - simulation/nodes/node_sim_particle_time_step_event.cc - simulation/nodes/node_sim_set_particle_attribute.cc - simulation/nodes/node_sim_simulation_time.cc simulation/node_simulation_tree.cc simulation/node_simulation_util.cc diff --git a/source/blender/nodes/NOD_simulation.h b/source/blender/nodes/NOD_simulation.h index 266ded997c6..6b3d51b46a9 100644 --- a/source/blender/nodes/NOD_simulation.h +++ b/source/blender/nodes/NOD_simulation.h @@ -26,21 +26,6 @@ void register_node_tree_type_sim(void); void register_node_type_sim_group(void); -void register_node_type_sim_particle_simulation(void); -void register_node_type_sim_force(void); -void register_node_type_sim_set_particle_attribute(void); -void register_node_type_sim_particle_birth_event(void); -void register_node_type_sim_particle_time_step_event(void); -void register_node_type_sim_execute_condition(void); -void register_node_type_sim_multi_execute(void); -void register_node_type_sim_particle_mesh_emitter(void); -void register_node_type_sim_particle_mesh_collision_event(void); -void register_node_type_sim_emit_particles(void); -void register_node_type_sim_time(void); -void register_node_type_sim_particle_attribute(void); -void register_node_type_sim_age_reached_event(void); -void register_node_type_sim_kill_particle(void); - #ifdef __cplusplus } #endif diff --git a/source/blender/nodes/NOD_static_types.h b/source/blender/nodes/NOD_static_types.h index 7922a73902c..0173706b570 100644 --- a/source/blender/nodes/NOD_static_types.h +++ b/source/blender/nodes/NOD_static_types.h @@ -258,21 +258,6 @@ DefNode(TextureNode, TEX_NODE_PROC+TEX_NOISE, 0, "TEX_NO DefNode(TextureNode, TEX_NODE_PROC+TEX_STUCCI, 0, "TEX_STUCCI", TexStucci, "Stucci", "" ) DefNode(TextureNode, TEX_NODE_PROC+TEX_DISTNOISE, 0, "TEX_DISTNOISE", TexDistNoise, "Distorted Noise", "" ) -DefNode(SimulationNode, SIM_NODE_PARTICLE_SIMULATION, 0, "PARTICLE_SIMULATION", ParticleSimulation, "Particle Simulation", "") -DefNode(SimulationNode, SIM_NODE_FORCE, 0, "FORCE", Force, "Force", "") -DefNode(SimulationNode, SIM_NODE_SET_PARTICLE_ATTRIBUTE, def_sim_set_particle_attribute, "SET_PARTICLE_ATTRIBUTE", SetParticleAttribute, "Set Particle Attribute", "") -DefNode(SimulationNode, SIM_NODE_PARTICLE_BIRTH_EVENT, 0, "PARTICLE_BIRTH_EVENT", ParticleBirthEvent, "Particle Birth Event", "") -DefNode(SimulationNode, SIM_NODE_PARTICLE_TIME_STEP_EVENT, def_sim_particle_time_step_event, "PARTICLE_TIME_STEP_EVENT", ParticleTimeStepEvent, "Particle Time Step Event", "") -DefNode(SimulationNode, SIM_NODE_EXECUTE_CONDITION, 0, "EXECUTE_CONDITION", ExecuteCondition, "Execute Condition", "") -DefNode(SimulationNode, SIM_NODE_MULTI_EXECUTE, 0, "MULTI_EXECUTE", MultiExecute, "Multi Execute", "") -DefNode(SimulationNode, SIM_NODE_PARTICLE_MESH_EMITTER, 0, "PARTICLE_MESH_EMITTER", ParticleMeshEmitter, "Particle Mesh Emitter", "") -DefNode(SimulationNode, SIM_NODE_PARTICLE_MESH_COLLISION_EVENT, 0, "PARTICLE_MESH_COLLISION_EVENT", ParticleMeshCollisionEvent, "Particle Mesh Collision Event", "") -DefNode(SimulationNode, SIM_NODE_EMIT_PARTICLES, 0, "EMIT_PARTICLES", EmitParticles, "Emit Particles", "") -DefNode(SimulationNode, SIM_NODE_TIME, def_sim_time, "TIME", Time, "Time", "") -DefNode(SimulationNode, SIM_NODE_PARTICLE_ATTRIBUTE, def_sim_particle_attribute, "PARTICLE_ATTRIBUTE", ParticleAttribute, "Particle Attribute", "") -DefNode(SimulationNode, SIM_NODE_AGE_REACHED_EVENT, 0, "AGE_REACHED_EVENT", AgeReachedEvent, "Age Reached Event", "") -DefNode(SimulationNode, SIM_NODE_KILL_PARTICLE, 0, "KILL_PARTICLE", KillParticle, "Kill Particle", "") - DefNode(FunctionNode, FN_NODE_BOOLEAN_MATH, def_boolean_math, "BOOLEAN_MATH", BooleanMath, "Boolean Math", "") DefNode(FunctionNode, FN_NODE_FLOAT_COMPARE, def_float_compare, "FLOAT_COMPARE", FloatCompare, "Float Compare", "") DefNode(FunctionNode, FN_NODE_SWITCH, def_fn_switch, "SWITCH", Switch, "Switch", "") diff --git a/source/blender/nodes/intern/node_socket.cc b/source/blender/nodes/intern/node_socket.cc index 0dfae7424cb..0cedc6597c8 100644 --- a/source/blender/nodes/intern/node_socket.cc +++ b/source/blender/nodes/intern/node_socket.cc @@ -549,19 +549,6 @@ static bNodeSocketType *make_socket_type_virtual(void) return stype; } -static bNodeSocketType *make_socket_type_effector(int type) -{ - bNodeSocketType *stype = make_standard_socket_type(type, PROP_NONE); - stype->input_link_limit = 0xFFF; - return stype; -} - -static bNodeSocketType *make_socket_type_control_flow(int type) -{ - bNodeSocketType *stype = make_standard_socket_type(type, PROP_NONE); - return stype; -} - static bNodeSocketType *make_socket_type_bool() { bNodeSocketType *socktype = make_standard_socket_type(SOCK_BOOLEAN, PROP_NONE); @@ -721,11 +708,5 @@ void register_standard_node_socket_types(void) nodeRegisterSocketType(make_standard_socket_type(SOCK_IMAGE, PROP_NONE)); - nodeRegisterSocketType(make_socket_type_effector(SOCK_EMITTERS)); - nodeRegisterSocketType(make_socket_type_effector(SOCK_EVENTS)); - nodeRegisterSocketType(make_socket_type_effector(SOCK_FORCES)); - - nodeRegisterSocketType(make_socket_type_control_flow(SOCK_CONTROL_FLOW)); - nodeRegisterSocketType(make_socket_type_virtual()); } diff --git a/source/blender/nodes/simulation/nodes/node_sim_age_reached_event.cc b/source/blender/nodes/simulation/nodes/node_sim_age_reached_event.cc deleted file mode 100644 index add8c4eba4d..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_age_reached_event.cc +++ /dev/null @@ -1,38 +0,0 @@ -/* - * 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. - */ - -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_age_reached_event_in[] = { - {SOCK_FLOAT, N_("Age"), 3, 0, 0, 0, 0, 10000000}, - {SOCK_CONTROL_FLOW, N_("Execute")}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_age_reached_event_out[] = { - {SOCK_EVENTS, N_("Event")}, - {-1, ""}, -}; - -void register_node_type_sim_age_reached_event() -{ - static bNodeType ntype; - - sim_node_type_base(&ntype, SIM_NODE_AGE_REACHED_EVENT, "Age Reached Event", 0, 0); - node_type_socket_templates( - &ntype, sim_node_age_reached_event_in, sim_node_age_reached_event_out); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_emit_particles.cc b/source/blender/nodes/simulation/nodes/node_sim_emit_particles.cc deleted file mode 100644 index e23984dbf34..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_emit_particles.cc +++ /dev/null @@ -1,38 +0,0 @@ -/* - * 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. - */ - -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_emit_particle_in[] = { - {SOCK_INT, N_("Amount"), 10, 0, 0, 0, 0, 10000000}, - {SOCK_CONTROL_FLOW, N_("Execute")}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_emit_particle_out[] = { - {SOCK_CONTROL_FLOW, N_("Execute")}, - {SOCK_EMITTERS, N_("Emitter")}, - {-1, ""}, -}; - -void register_node_type_sim_emit_particles() -{ - static bNodeType ntype; - - sim_node_type_base(&ntype, SIM_NODE_EMIT_PARTICLES, "Emit Particles", 0, 0); - node_type_socket_templates(&ntype, sim_node_emit_particle_in, sim_node_emit_particle_out); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_execute_condition.cc b/source/blender/nodes/simulation/nodes/node_sim_execute_condition.cc deleted file mode 100644 index 69f30d1ad0d..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_execute_condition.cc +++ /dev/null @@ -1,39 +0,0 @@ -/* - * 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. - */ - -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_execute_condition_in[] = { - {SOCK_BOOLEAN, N_("Condition")}, - {SOCK_CONTROL_FLOW, N_("If True")}, - {SOCK_CONTROL_FLOW, N_("If False")}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_execute_condition_out[] = { - {SOCK_CONTROL_FLOW, N_("Execute")}, - {-1, ""}, -}; - -void register_node_type_sim_execute_condition() -{ - static bNodeType ntype; - - sim_node_type_base(&ntype, SIM_NODE_EXECUTE_CONDITION, "Execute Condition", 0, 0); - node_type_socket_templates( - &ntype, sim_node_execute_condition_in, sim_node_execute_condition_out); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_force.cc b/source/blender/nodes/simulation/nodes/node_sim_force.cc deleted file mode 100644 index eccd2e4e2ab..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_force.cc +++ /dev/null @@ -1,36 +0,0 @@ -/* - * 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. - */ - -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_force_in[] = { - {SOCK_VECTOR, N_("Force"), 0.0f, 0.0f, 0.0f, 0.0f, -10000.0f, 10000.0f}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_force_out[] = { - {SOCK_FORCES, N_("Force")}, - {-1, ""}, -}; - -void register_node_type_sim_force() -{ - static bNodeType ntype; - - sim_node_type_base(&ntype, SIM_NODE_FORCE, "Force", 0, 0); - node_type_socket_templates(&ntype, sim_node_force_in, sim_node_force_out); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_kill_particle.cc b/source/blender/nodes/simulation/nodes/node_sim_kill_particle.cc deleted file mode 100644 index 793b40d9365..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_kill_particle.cc +++ /dev/null @@ -1,36 +0,0 @@ -/* - * 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. - */ - -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_kill_particle_in[] = { - {SOCK_CONTROL_FLOW, N_("Execute")}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_kill_particle_out[] = { - {SOCK_CONTROL_FLOW, N_("Execute")}, - {-1, ""}, -}; - -void register_node_type_sim_kill_particle() -{ - static bNodeType ntype; - - sim_node_type_base(&ntype, SIM_NODE_KILL_PARTICLE, "Kill Particle", 0, 0); - node_type_socket_templates(&ntype, sim_node_kill_particle_in, sim_node_kill_particle_out); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_multi_execute.cc b/source/blender/nodes/simulation/nodes/node_sim_multi_execute.cc deleted file mode 100644 index 5944db7e2bc..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_multi_execute.cc +++ /dev/null @@ -1,38 +0,0 @@ -/* - * 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. - */ - -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_multi_execute_in[] = { - {SOCK_CONTROL_FLOW, "1"}, - {SOCK_CONTROL_FLOW, "2"}, - {SOCK_CONTROL_FLOW, "3"}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_multi_execute_out[] = { - {SOCK_CONTROL_FLOW, N_("Execute")}, - {-1, ""}, -}; - -void register_node_type_sim_multi_execute() -{ - static bNodeType ntype; - - sim_node_type_base(&ntype, SIM_NODE_MULTI_EXECUTE, "Multi Execute", 0, 0); - node_type_socket_templates(&ntype, sim_node_multi_execute_in, sim_node_multi_execute_out); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_particle_attribute.cc b/source/blender/nodes/simulation/nodes/node_sim_particle_attribute.cc deleted file mode 100644 index b6b67ee334e..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_particle_attribute.cc +++ /dev/null @@ -1,52 +0,0 @@ -/* - * 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. - */ - -#include "BLI_listbase.h" -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_particle_attribute_in[] = { - {SOCK_STRING, N_("Name")}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_particle_attribute_out[] = { - {SOCK_FLOAT, N_("Float")}, - {SOCK_INT, N_("Int")}, - {SOCK_BOOLEAN, N_("Boolean")}, - {SOCK_VECTOR, N_("Vector")}, - {SOCK_RGBA, N_("Color")}, - {SOCK_OBJECT, N_("Object")}, - {SOCK_IMAGE, N_("Image")}, - {-1, ""}, -}; - -static void sim_node_particle_attribute_update(bNodeTree *UNUSED(ntree), bNode *node) -{ - LISTBASE_FOREACH (bNodeSocket *, sock, &node->outputs) { - nodeSetSocketAvailability(sock, sock->type == node->custom1); - } -} - -void register_node_type_sim_particle_attribute() -{ - static bNodeType ntype; - - sim_node_type_base(&ntype, SIM_NODE_PARTICLE_ATTRIBUTE, "Particle Attribute", 0, 0); - node_type_socket_templates( - &ntype, sim_node_particle_attribute_in, sim_node_particle_attribute_out); - node_type_update(&ntype, sim_node_particle_attribute_update); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_particle_birth_event.cc b/source/blender/nodes/simulation/nodes/node_sim_particle_birth_event.cc deleted file mode 100644 index 8332a3ecd9f..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_particle_birth_event.cc +++ /dev/null @@ -1,37 +0,0 @@ -/* - * 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. - */ - -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_particle_birth_event_in[] = { - {SOCK_CONTROL_FLOW, N_("Execute")}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_particle_birth_event_out[] = { - {SOCK_EVENTS, N_("Event")}, - {-1, ""}, -}; - -void register_node_type_sim_particle_birth_event() -{ - static bNodeType ntype; - - sim_node_type_base(&ntype, SIM_NODE_PARTICLE_BIRTH_EVENT, "Particle Birth Event", 0, 0); - node_type_socket_templates( - &ntype, sim_node_particle_birth_event_in, sim_node_particle_birth_event_out); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_particle_mesh_collision_event.cc b/source/blender/nodes/simulation/nodes/node_sim_particle_mesh_collision_event.cc deleted file mode 100644 index 48671172136..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_particle_mesh_collision_event.cc +++ /dev/null @@ -1,40 +0,0 @@ -/* - * 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. - */ - -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_particle_mesh_collision_event_in[] = { - {SOCK_OBJECT, N_("Object")}, - {SOCK_CONTROL_FLOW, N_("Execute")}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_particle_mesh_collision_event_out[] = { - {SOCK_EVENTS, N_("Event")}, - {-1, ""}, -}; - -void register_node_type_sim_particle_mesh_collision_event() -{ - static bNodeType ntype; - - sim_node_type_base( - &ntype, SIM_NODE_PARTICLE_MESH_COLLISION_EVENT, "Particle Mesh Collision Event", 0, 0); - node_type_socket_templates(&ntype, - sim_node_particle_mesh_collision_event_in, - sim_node_particle_mesh_collision_event_out); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_particle_mesh_emitter.cc b/source/blender/nodes/simulation/nodes/node_sim_particle_mesh_emitter.cc deleted file mode 100644 index 5e1a6c35d52..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_particle_mesh_emitter.cc +++ /dev/null @@ -1,41 +0,0 @@ -/* - * 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. - */ - -#include "node_simulation_util.h" - -#include "float.h" - -static bNodeSocketTemplate sim_node_particle_mesh_emitter_in[] = { - {SOCK_OBJECT, N_("Object")}, - {SOCK_FLOAT, N_("Rate"), 100.0f, 0.0f, 0.0f, 0.0f, 0.0f, FLT_MAX}, - {SOCK_CONTROL_FLOW, N_("Execute")}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_particle_mesh_emitter_out[] = { - {SOCK_EMITTERS, N_("Emitter")}, - {-1, ""}, -}; - -void register_node_type_sim_particle_mesh_emitter() -{ - static bNodeType ntype; - - sim_node_type_base(&ntype, SIM_NODE_PARTICLE_MESH_EMITTER, "Mesh Emitter", 0, 0); - node_type_socket_templates( - &ntype, sim_node_particle_mesh_emitter_in, sim_node_particle_mesh_emitter_out); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_particle_simulation.cc b/source/blender/nodes/simulation/nodes/node_sim_particle_simulation.cc deleted file mode 100644 index 159c9b23da1..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_particle_simulation.cc +++ /dev/null @@ -1,39 +0,0 @@ -/* - * 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. - */ - -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_particle_simulation_in[] = { - {SOCK_EMITTERS, N_("Emitters")}, - {SOCK_EVENTS, N_("Events")}, - {SOCK_FORCES, N_("Forces")}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_particle_simulation_out[] = { - {-1, ""}, -}; - -void register_node_type_sim_particle_simulation() -{ - static bNodeType ntype; - - sim_node_type_base( - &ntype, SIM_NODE_PARTICLE_SIMULATION, "Particle Simulation", NODE_CLASS_OUTPUT, 0); - node_type_socket_templates( - &ntype, sim_node_particle_simulation_in, sim_node_particle_simulation_out); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_particle_time_step_event.cc b/source/blender/nodes/simulation/nodes/node_sim_particle_time_step_event.cc deleted file mode 100644 index cda8ddeb644..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_particle_time_step_event.cc +++ /dev/null @@ -1,37 +0,0 @@ -/* - * 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. - */ - -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_particle_time_step_event_in[] = { - {SOCK_CONTROL_FLOW, N_("Execute")}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_particle_time_step_event_out[] = { - {SOCK_EVENTS, N_("Event")}, - {-1, ""}, -}; - -void register_node_type_sim_particle_time_step_event() -{ - static bNodeType ntype; - - sim_node_type_base(&ntype, SIM_NODE_PARTICLE_TIME_STEP_EVENT, "Particle Time Step Event", 0, 0); - node_type_socket_templates( - &ntype, sim_node_particle_time_step_event_in, sim_node_particle_time_step_event_out); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_set_particle_attribute.cc b/source/blender/nodes/simulation/nodes/node_sim_set_particle_attribute.cc deleted file mode 100644 index 8f5c6818cb4..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_set_particle_attribute.cc +++ /dev/null @@ -1,58 +0,0 @@ -/* - * 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. - */ - -#include "BLI_listbase.h" -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_set_particle_attribute_in[] = { - {SOCK_CONTROL_FLOW, N_("Execute")}, - {SOCK_STRING, N_("Name")}, - {SOCK_FLOAT, N_("Float"), 0.0f, 0.0f, 0.0f, 0.0f, -10000.0f, 10000.0f}, - {SOCK_INT, N_("Int"), 0, 0, 0, 0, -10000, 10000}, - {SOCK_BOOLEAN, N_("Boolean")}, - {SOCK_VECTOR, N_("Vector")}, - {SOCK_RGBA, N_("Color")}, - {SOCK_OBJECT, N_("Object")}, - {SOCK_IMAGE, N_("Image")}, - {-1, ""}, -}; - -static bNodeSocketTemplate sim_node_set_particle_attribute_out[] = { - {SOCK_CONTROL_FLOW, N_("Execute")}, - {-1, ""}, -}; - -static void sim_node_set_particle_attribute_update(bNodeTree *UNUSED(ntree), bNode *node) -{ - int index = 0; - LISTBASE_FOREACH (bNodeSocket *, sock, &node->inputs) { - if (index >= 2) { - nodeSetSocketAvailability(sock, sock->type == node->custom1); - } - index++; - } -} - -void register_node_type_sim_set_particle_attribute() -{ - static bNodeType ntype; - - sim_node_type_base(&ntype, SIM_NODE_SET_PARTICLE_ATTRIBUTE, "Set Particle Attribute", 0, 0); - node_type_socket_templates( - &ntype, sim_node_set_particle_attribute_in, sim_node_set_particle_attribute_out); - node_type_update(&ntype, sim_node_set_particle_attribute_update); - nodeRegisterType(&ntype); -} diff --git a/source/blender/nodes/simulation/nodes/node_sim_simulation_time.cc b/source/blender/nodes/simulation/nodes/node_sim_simulation_time.cc deleted file mode 100644 index 40e1c43fb69..00000000000 --- a/source/blender/nodes/simulation/nodes/node_sim_simulation_time.cc +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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. - */ - -#include "node_simulation_util.h" - -static bNodeSocketTemplate sim_node_time_out[] = { - {SOCK_FLOAT, N_("Time")}, - {-1, ""}, -}; - -void register_node_type_sim_time() -{ - static bNodeType ntype; - - sim_node_type_base(&ntype, SIM_NODE_TIME, "Time", 0, 0); - node_type_socket_templates(&ntype, nullptr, sim_node_time_out); - nodeRegisterType(&ntype); -} |