19 b.use_custom_socket_order();
20 b.allow_any_socket_order();
23 .description(
"Curves to change the order of");
24 b.add_output<
decl::Geometry>(
"Curves"_ustr).propagate_all_geometry().align_with_previous();
28 .evaluated_geometry_field();
29 b.add_input<
decl::Int>(
"Order"_ustr).default_value(4).min(2).max(127).evaluated_geometry_field();
35 std::atomic<bool> &has_nurbs)
38 for (
const int layer_index :
grease_pencil.layers().index_range()) {
40 if (drawing ==
nullptr) {
46 curves.attributes_for_write(),
69 std::atomic<bool> has_nurbs =
false;
94 params.
set_output(
"Curves"_ustr, std::move(geometry_set));
102 ntype.
ui_name =
"Set NURBS Order";
104 "Control how many curve control points influence each evaluated point by changing the "
105 "\"nurbs_order\" attribute";
Low-level operations for curves.
Low-level operations for grease pencil.
#define NODE_CLASS_GEOMETRY
#define NOD_REGISTER_NODE(REGISTER_FUNC)
bke::CurvesGeometry & strokes_for_write()
void error_message_add(const NodeWarningType type, StringRef message) const
T extract_input(const UString identifier)
void set_output(const UString identifier, T &&value)
bool try_capture_field_on_geometry(MutableAttributeAccessor attributes, const fn::FieldContext &field_context, const StringRef name, AttrDomain domain, const fn::Field< bool > &selection, const fn::GField &field)
const DataTypeConversions & get_implicit_type_conversions()
void node_register_type(bNodeType &ntype)
void foreach_real_geometry(bke::GeometrySet &geometry, FunctionRef< void(bke::GeometrySet &geometry_set)> fn)
static void node_declare(NodeDeclarationBuilder &b)
static void node_geo_exec(GeoNodeExecParams params)
static void set_grease_pencil_order(GreasePencil &grease_pencil, const Field< bool > &selection, const Field< int8_t > &order, std::atomic< bool > &has_nurbs)
static void node_register()
void geo_node_type_base(bke::bNodeType *ntype, UString idname, const std::optional< int16_t > legacy_type)
Curves * get_curves_for_write()
GreasePencil * get_grease_pencil_for_write()
std::string ui_description
NodeGeometryExecFunction geometry_node_execute
NodeDeclareFunction declare