diff options
Diffstat (limited to 'source/blender/nodes')
-rw-r--r-- | source/blender/nodes/CMakeLists.txt | 4 | ||||
-rw-r--r-- | source/blender/nodes/NOD_geometry.h | 4 | ||||
-rw-r--r-- | source/blender/nodes/NOD_static_types.h | 4 | ||||
-rw-r--r-- | source/blender/nodes/geometry/nodes/node_geo_subdivide.cc (renamed from source/blender/nodes/geometry/nodes/node_geo_subdivision_surface_simple.cc) | 19 | ||||
-rw-r--r-- | source/blender/nodes/geometry/nodes/node_geo_subdivide_smooth.cc (renamed from source/blender/nodes/geometry/nodes/node_geo_subdivision_surface.cc) | 23 |
5 files changed, 24 insertions, 30 deletions
diff --git a/source/blender/nodes/CMakeLists.txt b/source/blender/nodes/CMakeLists.txt index 9386f686c73..d89cf2ecefa 100644 --- a/source/blender/nodes/CMakeLists.txt +++ b/source/blender/nodes/CMakeLists.txt @@ -168,8 +168,8 @@ set(SRC geometry/nodes/node_geo_point_separate.cc geometry/nodes/node_geo_point_translate.cc geometry/nodes/node_geo_points_to_volume.cc - geometry/nodes/node_geo_subdivision_surface.cc - geometry/nodes/node_geo_subdivision_surface_simple.cc + geometry/nodes/node_geo_subdivide_smooth.cc + geometry/nodes/node_geo_subdivide.cc geometry/nodes/node_geo_transform.cc geometry/nodes/node_geo_triangulate.cc geometry/nodes/node_geo_volume_to_mesh.cc diff --git a/source/blender/nodes/NOD_geometry.h b/source/blender/nodes/NOD_geometry.h index 3ee8067e81a..b094256190c 100644 --- a/source/blender/nodes/NOD_geometry.h +++ b/source/blender/nodes/NOD_geometry.h @@ -51,8 +51,8 @@ void register_node_type_geo_point_separate(void); void register_node_type_geo_point_translate(void); void register_node_type_geo_points_to_volume(void); void register_node_type_geo_sample_texture(void); -void register_node_type_geo_subdivision_surface(void); -void register_node_type_geo_subdivision_surface_simple(void); +void register_node_type_geo_subdivide_smooth(void); +void register_node_type_geo_subdivide(void); void register_node_type_geo_transform(void); void register_node_type_geo_triangulate(void); void register_node_type_geo_volume_to_mesh(void); diff --git a/source/blender/nodes/NOD_static_types.h b/source/blender/nodes/NOD_static_types.h index 35550bdec48..22204d7204e 100644 --- a/source/blender/nodes/NOD_static_types.h +++ b/source/blender/nodes/NOD_static_types.h @@ -272,7 +272,7 @@ DefNode(FunctionNode, FN_NODE_INPUT_STRING, def_fn_input_string, "INPUT_STRING", DefNode(GeometryNode, GEO_NODE_TRIANGULATE, def_geo_triangulate, "TRIANGULATE", Triangulate, "Triangulate", "") DefNode(GeometryNode, GEO_NODE_EDGE_SPLIT, 0, "EDGE_SPLIT", EdgeSplit, "Edge Split", "") DefNode(GeometryNode, GEO_NODE_TRANSFORM, 0, "TRANSFORM", Transform, "Transform", "") -DefNode(GeometryNode, GEO_NODE_SUBDIVISION_SURFACE, 0, "SUBDIVISION_SURFACE", SubdivisionSurface, "Subdivision Surface", "") +DefNode(GeometryNode, GEO_NODE_SUBDIVIDE_SMOOTH, 0, "SUBDIVIDE_SMOOTH", SubdivideSmooth, "Subdivide Smooth", "") DefNode(GeometryNode, GEO_NODE_BOOLEAN, def_geo_boolean, "BOOLEAN", Boolean, "Boolean", "") DefNode(GeometryNode, GEO_NODE_POINT_DISTRIBUTE, def_geo_point_distribute, "POINT_DISTRIBUTE", PointDistribute, "Point Distribute", "") DefNode(GeometryNode, GEO_NODE_POINT_INSTANCE, def_geo_point_instance, "POINT_INSTANCE", PointInstance, "Point Instance", "") @@ -298,7 +298,7 @@ DefNode(GeometryNode, GEO_NODE_ATTRIBUTE_PROXIMITY, def_geo_attribute_proximity, DefNode(GeometryNode, GEO_NODE_VOLUME_TO_MESH, def_geo_volume_to_mesh, "VOLUME_TO_MESH", VolumeToMesh, "Volume to Mesh", "") DefNode(GeometryNode, GEO_NODE_ATTRIBUTE_COMBINE_XYZ, def_geo_attribute_combine_xyz, "ATTRIBUTE_COMBINE_XYZ", AttributeCombineXYZ, "Attribute Combine XYZ", "") DefNode(GeometryNode, GEO_NODE_ATTRIBUTE_SEPARATE_XYZ, def_geo_attribute_separate_xyz, "ATTRIBUTE_SEPARATE_XYZ", AttributeSeparateXYZ, "Attribute Separate XYZ", "") -DefNode(GeometryNode, GEO_NODE_SUBDIVISION_SURFACE_SIMPLE, 0, "SUBDIVISION_SURFACE_SIMPLE", SubdivisionSurfaceSimple, "Simple Subdivision Surface", "") +DefNode(GeometryNode, GEO_NODE_SUBDIVIDE, 0, "SUBDIVIDE", Subdivide, "Subdivide", "") /* undefine macros */ #undef DefNode diff --git a/source/blender/nodes/geometry/nodes/node_geo_subdivision_surface_simple.cc b/source/blender/nodes/geometry/nodes/node_geo_subdivide.cc index 38560d277e3..b5731851229 100644 --- a/source/blender/nodes/geometry/nodes/node_geo_subdivision_surface_simple.cc +++ b/source/blender/nodes/geometry/nodes/node_geo_subdivide.cc @@ -25,20 +25,20 @@ #include "node_geometry_util.hh" -static bNodeSocketTemplate geo_node_subdivision_surface_simple_in[] = { +static bNodeSocketTemplate geo_node_subdivide_in[] = { {SOCK_GEOMETRY, N_("Geometry")}, {SOCK_INT, N_("Level"), 1, 0, 0, 0, 0, 6}, {-1, ""}, }; -static bNodeSocketTemplate geo_node_subdivision_surface_simple_out[] = { +static bNodeSocketTemplate geo_node_subdivide_out[] = { {SOCK_GEOMETRY, N_("Geometry")}, {-1, ""}, }; namespace blender::nodes { -static void geo_node_subdivision_surface_simple_exec(GeoNodeExecParams params) +static void geo_node_subdivide_exec(GeoNodeExecParams params) { GeometrySet geometry_set = params.extract_input<GeometrySet>("Geometry"); @@ -99,17 +99,12 @@ static void geo_node_subdivision_surface_simple_exec(GeoNodeExecParams params) } } // namespace blender::nodes -void register_node_type_geo_subdivision_surface_simple() +void register_node_type_geo_subdivide() { static bNodeType ntype; - geo_node_type_base(&ntype, - GEO_NODE_SUBDIVISION_SURFACE_SIMPLE, - "Simple Subdivision Surface", - NODE_CLASS_GEOMETRY, - 0); - node_type_socket_templates( - &ntype, geo_node_subdivision_surface_simple_in, geo_node_subdivision_surface_simple_out); - ntype.geometry_node_execute = blender::nodes::geo_node_subdivision_surface_simple_exec; + geo_node_type_base(&ntype, GEO_NODE_SUBDIVIDE, "Subdivide", NODE_CLASS_GEOMETRY, 0); + node_type_socket_templates(&ntype, geo_node_subdivide_in, geo_node_subdivide_out); + ntype.geometry_node_execute = blender::nodes::geo_node_subdivide_exec; nodeRegisterType(&ntype); } diff --git a/source/blender/nodes/geometry/nodes/node_geo_subdivision_surface.cc b/source/blender/nodes/geometry/nodes/node_geo_subdivide_smooth.cc index 47304a0de68..4d9b8110d65 100644 --- a/source/blender/nodes/geometry/nodes/node_geo_subdivision_surface.cc +++ b/source/blender/nodes/geometry/nodes/node_geo_subdivide_smooth.cc @@ -25,7 +25,7 @@ #include "node_geometry_util.hh" -static bNodeSocketTemplate geo_node_subdivision_surface_in[] = { +static bNodeSocketTemplate geo_node_subdivide_smooth_in[] = { {SOCK_GEOMETRY, N_("Geometry")}, {SOCK_INT, N_("Level"), 1, 0, 0, 0, 0, 6}, {SOCK_BOOLEAN, N_("Use Creases")}, @@ -34,14 +34,14 @@ static bNodeSocketTemplate geo_node_subdivision_surface_in[] = { {-1, ""}, }; -static bNodeSocketTemplate geo_node_subdivision_surface_out[] = { +static bNodeSocketTemplate geo_node_subdivide_smooth_out[] = { {SOCK_GEOMETRY, N_("Geometry")}, {-1, ""}, }; -static void geo_node_subdivision_surface_layout(uiLayout *layout, - bContext *UNUSED(C), - PointerRNA *UNUSED(ptr)) +static void geo_node_subdivide_smooth_layout(uiLayout *layout, + bContext *UNUSED(C), + PointerRNA *UNUSED(ptr)) { #ifndef WITH_OPENSUBDIV uiItemL(layout, IFACE_("Disabled, built without OpenSubdiv"), ICON_ERROR); @@ -51,7 +51,7 @@ static void geo_node_subdivision_surface_layout(uiLayout *layout, } namespace blender::nodes { -static void geo_node_subdivision_surface_exec(GeoNodeExecParams params) +static void geo_node_subdivide_smooth_exec(GeoNodeExecParams params) { GeometrySet geometry_set = params.extract_input<GeometrySet>("Geometry"); @@ -120,15 +120,14 @@ static void geo_node_subdivision_surface_exec(GeoNodeExecParams params) } } // namespace blender::nodes -void register_node_type_geo_subdivision_surface() +void register_node_type_geo_subdivide_smooth() { static bNodeType ntype; geo_node_type_base( - &ntype, GEO_NODE_SUBDIVISION_SURFACE, "Subdivision Surface", NODE_CLASS_GEOMETRY, 0); - node_type_socket_templates( - &ntype, geo_node_subdivision_surface_in, geo_node_subdivision_surface_out); - ntype.geometry_node_execute = blender::nodes::geo_node_subdivision_surface_exec; - ntype.draw_buttons = geo_node_subdivision_surface_layout; + &ntype, GEO_NODE_SUBDIVIDE_SMOOTH, "Subdivide Smooth", NODE_CLASS_GEOMETRY, 0); + node_type_socket_templates(&ntype, geo_node_subdivide_smooth_in, geo_node_subdivide_smooth_out); + ntype.geometry_node_execute = blender::nodes::geo_node_subdivide_smooth_exec; + ntype.draw_buttons = geo_node_subdivide_smooth_layout; nodeRegisterType(&ntype); } |