21 const AttrDomain domain = (component.
type() == GeometryComponent::Type::Instance) ?
22 AttrDomain::Instance :
25 if (domain_size == 0) {
44 evaluator.
add(id_field);
51 id_attribute.finish();
62 GeometryComponent::Type::Mesh,
63 GeometryComponent::Type::PointCloud,
64 GeometryComponent::Type::Curve})
66 if (geometry_set.
has(type)) {
71 params.set_output(
"Geometry", std::move(geometry_set));
#define NODE_CLASS_GEOMETRY
#define NOD_REGISTER_NODE(REGISTER_FUNC)
void materialize(MutableSpan< T > r_span) const
bool contains(const StringRef attribute_id) const
int attribute_domain_size(AttrDomain domain) const
virtual std::optional< MutableAttributeAccessor > attributes_for_write()
GSpanAttributeWriter lookup_or_add_for_write_span(StringRef attribute_id, AttrDomain domain, eCustomDataType data_type, const AttributeInit &initializer=AttributeInitDefaultValue())
GAttributeWriter lookup_or_add_for_write(StringRef attribute_id, AttrDomain domain, eCustomDataType data_type, const AttributeInit &initializer=AttributeInitDefaultValue())
void set_selection(Field< bool > selection)
int add(GField field, GVArray *varray_ptr)
IndexMask get_evaluated_selection_as_mask() const
int add_with_destination(GField field, GVMutableArray dst)
const GVArray & get_evaluated(const int field_index) const
local_group_size(16, 16) .push_constant(Type b
void node_register_type(bNodeType *ntype)
static void node_geo_exec(GeoNodeExecParams params)
static void node_declare(NodeDeclarationBuilder &b)
static void node_register()
static void set_id_in_component(GeometryComponent &component, const Field< bool > &selection_field, const Field< int > &id_field)
void geo_node_type_base(blender::bke::bNodeType *ntype, int type, const char *name, short nclass)
GPU_SHADER_INTERFACE_INFO(overlay_edit_curve_handle_iface, "vert").flat(Type pos vertex_in(1, Type::UINT, "data") .vertex_out(overlay_edit_curve_handle_iface) .geometry_layout(PrimitiveIn Frequency::GEOMETRY storage_buf(1, Qualifier::READ, "uint", "data[]", Frequency::GEOMETRY) .push_constant(Type Frequency::GEOMETRY selection[]
VMutableArray< T > varray
GeometryComponent & get_component_for_write(GeometryComponent::Type component_type)
bool has(const GeometryComponent::Type component_type) const
NodeGeometryExecFunction geometry_node_execute
NodeDeclareFunction declare