Changeset View
Changeset View
Standalone View
Standalone View
source/blender/nodes/geometry/nodes/node_geo_subdivision_surface.cc
| Show All 22 Lines | |||||
| static void node_declare(NodeDeclarationBuilder &b) | static void node_declare(NodeDeclarationBuilder &b) | ||||
| { | { | ||||
| b.add_input<decl::Geometry>(N_("Mesh")).supported_type(GEO_COMPONENT_TYPE_MESH); | b.add_input<decl::Geometry>(N_("Mesh")).supported_type(GEO_COMPONENT_TYPE_MESH); | ||||
| b.add_input<decl::Int>(N_("Level")).default_value(1).min(0).max(6); | b.add_input<decl::Int>(N_("Level")).default_value(1).min(0).max(6); | ||||
| b.add_input<decl::Float>(N_("Edge Crease")) | b.add_input<decl::Float>(N_("Edge Crease")) | ||||
| .default_value(0.0f) | .default_value(0.0f) | ||||
| .min(0.0f) | .min(0.0f) | ||||
| .max(1.0f) | .max(1.0f) | ||||
| .supports_field() | .field_on_all() | ||||
| .subtype(PROP_FACTOR); | .subtype(PROP_FACTOR); | ||||
| b.add_input<decl::Float>(N_("Vertex Crease")) | b.add_input<decl::Float>(N_("Vertex Crease")) | ||||
| .default_value(0.0f) | .default_value(0.0f) | ||||
| .min(0.0f) | .min(0.0f) | ||||
| .max(1.0f) | .max(1.0f) | ||||
| .supports_field() | .field_on_all() | ||||
| .subtype(PROP_FACTOR); | .subtype(PROP_FACTOR); | ||||
| b.add_output<decl::Geometry>(N_("Mesh")); | b.add_output<decl::Geometry>(N_("Mesh")).propagate_all(); | ||||
| } | } | ||||
| static void node_layout(uiLayout *layout, bContext * /*C*/, PointerRNA *ptr) | static void node_layout(uiLayout *layout, bContext * /*C*/, PointerRNA *ptr) | ||||
| { | { | ||||
| uiItemR(layout, ptr, "uv_smooth", 0, "", ICON_NONE); | uiItemR(layout, ptr, "uv_smooth", 0, "", ICON_NONE); | ||||
| uiItemR(layout, ptr, "boundary_smooth", 0, "", ICON_NONE); | uiItemR(layout, ptr, "boundary_smooth", 0, "", ICON_NONE); | ||||
| } | } | ||||
| ▲ Show 20 Lines • Show All 161 Lines • Show Last 20 Lines | |||||