22 b.use_custom_socket_order();
23 b.allow_any_socket_order();
24 b.add_default_layout();
25 const bNode *node =
b.node_or_null();
27 if (node !=
nullptr) {
29 b.add_input(data_type,
"Value").supports_field();
30 b.add_output(data_type,
"Value").field_source_reference_all().align_with_previous();
42 node->
custom1 = int(AttrDomain::Point);
55 params.update_and_connect_available_socket(node,
"Value");
66 GField dst_field{std::make_shared<bke::EvaluateOnDomainInput>(std::move(src_field), domain)};
67 params.set_output<
GField>(
"Value", std::move(dst_field));
75 "Domain the field is evaluated in",
78 int(AttrDomain::Point));
95 ntype.
ui_name =
"Evaluate on Domain";
97 "Retrieve values from a field on a different domain besides the domain from the context";
#define NODE_CLASS_CONVERTER
#define GEO_NODE_EVALUATE_ON_DOMAIN
#define NOD_REGISTER_NODE(REGISTER_FUNC)
#define NOD_inline_enum_accessors(member)
void node_register_type(bNodeType &ntype)
std::optional< eCustomDataType > socket_type_to_custom_data_type(eNodeSocketDatatype type)
const EnumPropertyItem * attribute_type_type_with_socket_fn(bContext *, PointerRNA *, PropertyRNA *, bool *r_free)
static void node_init(bNodeTree *, bNode *node)
static void node_layout(uiLayout *layout, bContext *, PointerRNA *ptr)
static void node_geo_exec(GeoNodeExecParams params)
static void node_rna(StructRNA *srna)
static void node_gather_link_searches(GatherLinkSearchOpParams ¶ms)
static void node_register()
static void node_declare(NodeDeclarationBuilder &b)
PropertyRNA * RNA_def_node_enum(StructRNA *srna, const char *identifier, const char *ui_name, const char *ui_description, const EnumPropertyItem *static_items, const EnumRNAAccessors accessors, std::optional< int > default_value, const EnumPropertyItemFunc item_func, const bool allow_animation)
void geo_node_type_base(blender::bke::bNodeType *ntype, std::string idname, const std::optional< int16_t > legacy_type)
const EnumPropertyItem rna_enum_attribute_domain_items[]
const EnumPropertyItem rna_enum_attribute_type_items[]
std::string ui_description
void(* initfunc)(bNodeTree *ntree, bNode *node)
NodeGeometryExecFunction geometry_node_execute
const char * enum_name_legacy
void(* draw_buttons)(uiLayout *, bContext *C, PointerRNA *ptr)
NodeGatherSocketLinkOperationsFunction gather_link_search_ops
NodeDeclareFunction declare
void prop(PointerRNA *ptr, PropertyRNA *prop, int index, int value, eUI_Item_Flag flag, std::optional< blender::StringRef > name_opt, int icon, std::optional< blender::StringRef > placeholder=std::nullopt)