19 b.add_input<
decl::Int>(
"Level").default_value(1).min(0).max(6);
24static Mesh *simple_subdivide_mesh(
const Mesh &mesh,
const int level)
36 subdiv_settings.
level = 1;
61 const int level =
clamp_i(
params.extract_input<
int>(
"Level"), 0, 11);
63 params.set_output(
"Mesh", std::move(geometry_set));
69 geometry_set.replace_mesh(simple_subdivide_mesh(*mesh, level));
73 params.error_message_add(NodeWarningType::Error,
74 TIP_(
"Disabled, Blender was compiled without OpenSubdiv"));
76 params.set_output(
"Mesh", std::move(geometry_set));
#define NODE_CLASS_GEOMETRY
MINLINE int clamp_i(int value, int min, int max)
#define NOD_REGISTER_NODE(REGISTER_FUNC)
local_group_size(16, 16) .push_constant(Type b
void free(Subdiv *subdiv)
Subdiv * new_from_mesh(const Settings *settings, const Mesh *mesh)
FVarLinearInterpolation fvar_interpolation_from_uv_smooth(int uv_smooth)
VtxBoundaryInterpolation vtx_boundary_interpolation_from_subsurf(int boundary_smooth)
Mesh * subdiv_to_mesh(Subdiv *subdiv, const ToMeshSettings *settings, const Mesh *coarse_mesh)
void node_register_type(bNodeType *ntype)
void debug_randomize_mesh_order(Mesh *mesh)
static void node_register()
static void node_declare(NodeDeclarationBuilder &b)
static void node_geo_exec(GeoNodeExecParams params)
void geo_node_type_base(blender::bke::bNodeType *ntype, int type, const char *name, short nclass)
const Mesh * get_mesh() const
void modify_geometry_sets(ForeachSubGeometryCallback callback)
NodeGeometryExecFunction geometry_node_execute
NodeDeclareFunction declare
VtxBoundaryInterpolation vtx_boundary_interpolation
FVarLinearInterpolation fvar_linear_interpolation