51 if (result_attribute) {
52 return result_attribute->domain();
57 if (input_attribute) {
58 return input_attribute->domain();
68 const std::string result_name =
params.get_input<std::string>(
"Result");
69 const std::string input_name =
params.get_input<std::string>(
"Attribute");
78 result_name, result_domain, result_type);
79 if (!attribute_result) {
84 input_name, result_domain, 0.0f);
90 for (
const int i : data_in.index_range()) {
110 params.set_output(
"Geometry", std::move(geometry_set));
118 node->storage = node_storage;
void BKE_colorband_init(struct ColorBand *coba, bool rangetype)
bool BKE_colorband_evaluate(const struct ColorBand *coba, float in, float out[4])
void node_type_socket_templates(struct bNodeType *ntype, struct bNodeSocketTemplate *inputs, struct bNodeSocketTemplate *outputs)
void node_type_init(struct bNodeType *ntype, void(*initfunc)(struct bNodeTree *ntree, struct bNode *node))
void node_type_size_preset(struct bNodeType *ntype, eNodeSizePreset size)
void node_type_storage(struct bNodeType *ntype, const char *storagename, void(*freefunc)(struct bNode *node), void(*copyfunc)(struct bNodeTree *dest_ntree, struct bNode *dest_node, const struct bNode *src_node))
#define NODE_CLASS_ATTRIBUTE
void nodeRegisterType(struct bNodeType *ntype)
static uint8 component(Color32 c, uint i)
Group RGB to Bright Vector Camera Vector Combine Material Light Line Style Layer Add Ambient Diffuse Glossy Refraction Transparent Toon Principled Hair Volume Principled Light Particle Volume Image Sky Noise Wave Voronoi Brick Texture Vector Combine Vertex Separate Vector White RGB Map Separate Set Z Dilate Combine Combine Color Channel Split ID Combine Luminance Directional Alpha Distance Hue Movie Ellipse Bokeh View Corner Anti Mix RGB Hue Separate TEX_NODE_PROC TEX_NODE_PROC TEX_NODE_PROC TEX_NODE_PROC TEX_NODE_PROC Boolean Random Edge Subdivision Point Object Attribute Attribute GEO_NODE_ATTRIBUTE_COLOR_RAMP
void uiTemplateColorRamp(uiLayout *layout, struct PointerRNA *ptr, const char *propname, bool expand)
void apply_span_and_save()
fn::GMutableSpan get_span_for_write_only()
void *(* MEM_callocN)(size_t len, const char *str)
TypedReadAttribute< float > FloatReadAttribute
GeometrySet geometry_set_realize_instances(const GeometrySet &geometry_set)
std::unique_ptr< ReadAttribute > ReadAttributePtr
static void execute_on_component(const GeoNodeExecParams ¶ms, GeometryComponent &component)
static void geo_node_attribute_color_ramp_init(bNodeTree *UNUSED(ntree), bNode *node)
static AttributeDomain get_result_domain(const GeometryComponent &component, StringRef source_name, StringRef result_name)
static void geo_node_attribute_color_ramp_exec(GeoNodeExecParams params)
static bNodeSocketTemplate geo_node_attribute_color_ramp_in[]
static void geo_node_attribute_color_ramp_layout(uiLayout *layout, bContext *UNUSED(C), PointerRNA *ptr)
void register_node_type_geo_attribute_color_ramp()
static bNodeSocketTemplate geo_node_attribute_color_ramp_out[]
void geo_node_type_base(bNodeType *ntype, int type, const char *name, short nclass, short flag)
void node_copy_standard_storage(bNodeTree *UNUSED(dest_ntree), bNode *dest_node, const bNode *src_node)
void node_free_standard_storage(bNode *node)
GeometryComponent & get_component_for_write(GeometryComponentType component_type)
bool has(const GeometryComponentType component_type) const
Compact definition of a node socket.
NodeGeometryExecFunction geometry_node_execute
void(* draw_buttons)(struct uiLayout *, struct bContext *C, struct PointerRNA *ptr)