|
Implements a new operator for detaching nodes. In the process i overhauled the node muting system as well.
There are a number of features that use a kind of "internal linking" in nodes:
1. muting
2. delete + reconnect (restore link to/from node after delete)
3. the new detach operator (same as 2, but don't delete the node)
The desired behavior in all cases is the same: find a sensible mapping of inputs-to-outputs of a node. In the case of muting these links are displayed in red on the node itself. For the other operators they are used to relink connections, such that one gets the best possible ongoing link between previous up- and downstream nodes.
Muting previously used a complicated callback system to ensure consistent behavior in the editor as well as execution in compositor, shader cpu/gpu and texture nodes. This has been greatly simplified by moving the muting step into the node tree localization functions. Any muted node is now bypassed using the generalized nodeInternalRelink function and then removed from the local tree. This way the internal execution system doesn't have to deal with muted nodes at all, as if they are non-existent.
The same function is also used by the delete_reconnect and the new links_detach operators (which work directly in the editor node tree). Detaching nodes is currently keymapped as a translation variant (macro operator): pressing ALTKEY + moving node first detaches and then continues with regular transform operator.
Total comments: 6
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+444 lines, -743 lines) |
Patch |
|
|
source/blender/blenkernel/BKE_node.h
|
View
|
1
2
|
5 chunks |
+8 lines, -27 lines |
0 comments
|
Download
|
|
|
source/blender/blenkernel/intern/node.c
|
View
|
1
2
|
4 chunks |
+53 lines, -18 lines |
0 comments
|
Download
|
|
|
source/blender/editors/space_node/node_draw.c
|
View
|
1
2
|
1 chunk |
+6 lines, -17 lines |
0 comments
|
Download
|
|
|
source/blender/editors/space_node/node_edit.c
|
View
|
1
2
|
4 chunks |
+45 lines, -118 lines |
0 comments
|
Download
|
|
|
source/blender/editors/space_node/node_intern.h
|
View
|
1
2
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
|
source/blender/editors/space_node/node_ops.c
|
View
|
1
2
|
2 chunks |
+7 lines, -2 lines |
0 comments
|
Download
|
|
|
source/blender/editors/transform/transform_ops.c
|
View
|
1
2
|
1 chunk |
+7 lines, -0 lines |
0 comments
|
Download
|
|
|
source/blender/gpu/GPU_material.h
|
View
|
1
2
|
2 chunks |
+0 lines, -2 lines |
0 comments
|
Download
|
|
|
source/blender/gpu/intern/gpu_codegen.c
|
View
|
1
2
|
1 chunk |
+0 lines, -25 lines |
0 comments
|
Download
|
|
|
source/blender/gpu/intern/gpu_shader_material.glsl
|
View
|
1
2
|
1 chunk |
+0 lines, -20 lines |
0 comments
|
Download
|
|
|
source/blender/gpu/intern/gpu_shader_material.glsl.c
|
View
|
1
2
|
1 chunk |
+226 lines, -234 lines |
0 comments
|
Download
|
|
|
source/blender/makesdna/DNA_node_types.h
|
View
|
1
2
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
|
source/blender/nodes/composite/node_composite_tree.c
|
View
|
1
2
|
4 chunks |
+24 lines, -8 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/composite/node_composite_util.h
|
View
|
1
2
|
1 chunk |
+0 lines, -1 line |
0 comments
|
Download
|
|
|
source/blender/nodes/composite/node_composite_util.c
|
View
|
1
2
|
1 chunk |
+0 lines, -26 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/composite/nodes/node_composite_composite.c
|
View
|
1
2
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
|
source/blender/nodes/composite/nodes/node_composite_outputFile.c
|
View
|
1
2
|
4 chunks |
+0 lines, -16 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/composite/nodes/node_composite_splitViewer.c
|
View
|
1
2
|
1 chunk |
+2 lines, -2 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/composite/nodes/node_composite_viewer.c
|
View
|
1
2
|
1 chunk |
+1 line, -2 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/intern/node_exec.c
|
View
|
1
2
|
2 chunks |
+2 lines, -6 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/intern/node_util.h
|
View
|
1
2
|
1 chunk |
+1 line, -8 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/intern/node_util.c
|
View
|
1
2
|
1 chunk |
+18 lines, -36 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/shader/node_shader_tree.c
|
View
|
1
2
|
2 chunks |
+17 lines, -4 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/shader/node_shader_util.h
|
View
|
1
2
|
1 chunk |
+0 lines, -3 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/shader/node_shader_util.c
|
View
|
1
2
|
2 chunks |
+1 line, -58 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/shader/nodes/node_shader_output.c
|
View
|
1
2
|
1 chunk |
+1 line, -2 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/shader/nodes/node_shader_output_lamp.c
|
View
|
1
2
|
1 chunk |
+1 line, -2 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/shader/nodes/node_shader_output_material.c
|
View
|
1
2
|
1 chunk |
+1 line, -2 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/shader/nodes/node_shader_output_world.c
|
View
|
1
2
|
1 chunk |
+1 line, -2 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/texture/node_texture_tree.c
|
View
|
1
2
|
2 chunks |
+17 lines, -4 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/texture/node_texture_util.h
|
View
|
1
2
|
1 chunk |
+0 lines, -2 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/texture/node_texture_util.c
|
View
|
1
2
|
1 chunk |
+0 lines, -92 lines |
0 comments
|
Download
|
|
|
source/blender/nodes/texture/nodes/node_texture_output.c
|
View
|
1
2
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
|
source/blender/nodes/texture/nodes/node_texture_viewer.c
|
View
|
1
2
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
Total messages: 6
|