10 b.add_input<
decl::Bool>(
N_(
"Selection")).default_value(
true).hide_value().supports_field();
22 const int domain_size =
component.attribute_domain_size(domain);
23 if (domain_size == 0) {
37 evaluator.add_with_destination(id_field, id_attribute.
varray);
42 evaluator.add(id_field);
44 const IndexMask selection = evaluator.get_evaluated_selection_as_mask();
45 const VArray<int> result_ids = evaluator.get_evaluated<
int>(0);
48 result_ids.
materialize(selection, id_attribute.span);
49 id_attribute.finish();
68 params.set_output(
"Geometry", std::move(geometry_set));
@ GEO_COMPONENT_TYPE_MESH
@ GEO_COMPONENT_TYPE_POINT_CLOUD
@ GEO_COMPONENT_TYPE_INSTANCES
@ GEO_COMPONENT_TYPE_CURVE
#define NODE_CLASS_GEOMETRY
void nodeRegisterType(struct bNodeType *ntype)
static uint8 component(Color32 c, uint i)
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum type
void materialize(MutableSpan< T > r_span) const
bool contains(const AttributeIDRef &attribute_id) const
GAttributeWriter lookup_or_add_for_write(const AttributeIDRef &attribute_id, const eAttrDomain domain, const eCustomDataType data_type, const AttributeInit &initializer=AttributeInitDefault())
GSpanAttributeWriter lookup_or_add_for_write_span(const AttributeIDRef &attribute_id, const eAttrDomain domain, const eCustomDataType data_type, const AttributeInit &initializer=AttributeInitDefault())
void set_selection(Field< bool > selection)
static void node_geo_exec(GeoNodeExecParams params)
static void node_declare(NodeDeclarationBuilder &b)
static void set_id_in_component(GeometryComponent &component, const Field< bool > &selection_field, const Field< int > &id_field)
static const pxr::TfToken b("b", pxr::TfToken::Immortal)
void register_node_type_geo_set_id()
void geo_node_type_base(bNodeType *ntype, int type, const char *name, short nclass)
GeometryComponent & get_component_for_write(GeometryComponentType component_type)
bool has(const GeometryComponentType component_type) const
NodeGeometryExecFunction geometry_node_execute
NodeDeclareFunction declare
VMutableArray< T > varray