[Bf-blender-cvs] [e03cfc23742] blender-v2.92-release: Fix T85420: moving color ramp handles via position input does not work
Jacques Lucke
noreply at git.blender.org
Wed Feb 10 17:30:02 CET 2021
Commit: e03cfc23742826db5ca195f06ba41c73171f40f3
Author: Jacques Lucke
Date: Wed Feb 10 17:29:52 2021 +0100
Branches: blender-v2.92-release
https://developer.blender.org/rBe03cfc23742826db5ca195f06ba41c73171f40f3
Fix T85420: moving color ramp handles via position input does not work
This just needed some special case handling for the new attribute color ramp node...
===================================================================
M source/blender/makesrna/intern/rna_color.c
===================================================================
diff --git a/source/blender/makesrna/intern/rna_color.c b/source/blender/makesrna/intern/rna_color.c
index 39aeeb430c2..ea019c70445 100644
--- a/source/blender/makesrna/intern/rna_color.c
+++ b/source/blender/makesrna/intern/rna_color.c
@@ -185,7 +185,11 @@ static char *rna_ColorRamp_path(PointerRNA *ptr)
char *node_path;
for (node = ntree->nodes.first; node; node = node->next) {
- if (ELEM(node->type, SH_NODE_VALTORGB, CMP_NODE_VALTORGB, TEX_NODE_VALTORGB)) {
+ if (ELEM(node->type,
+ SH_NODE_VALTORGB,
+ CMP_NODE_VALTORGB,
+ TEX_NODE_VALTORGB,
+ GEO_NODE_ATTRIBUTE_COLOR_RAMP)) {
if (node->storage == ptr->data) {
/* all node color ramp properties called 'color_ramp'
* prepend path from ID to the node
@@ -312,7 +316,11 @@ static void rna_ColorRamp_update(Main *bmain, Scene *UNUSED(scene), PointerRNA *
bNode *node;
for (node = ntree->nodes.first; node; node = node->next) {
- if (ELEM(node->type, SH_NODE_VALTORGB, CMP_NODE_VALTORGB, TEX_NODE_VALTORGB)) {
+ if (ELEM(node->type,
+ SH_NODE_VALTORGB,
+ CMP_NODE_VALTORGB,
+ TEX_NODE_VALTORGB,
+ GEO_NODE_ATTRIBUTE_COLOR_RAMP)) {
ED_node_tag_update_nodetree(bmain, ntree, node);
}
}
More information about the Bf-blender-cvs
mailing list