[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [38461] trunk/blender/source/blender/ editors/space_node/node_edit.c: Modified behavior when replacing input links: The new target socket for the existing link is now chosen from available sockets that match the _target_ type , instead of the source type.
Lukas Toenne
lukas.toenne at googlemail.com
Sun Jul 17 21:43:14 CEST 2011
Revision: 38461
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=38461
Author: lukastoenne
Date: 2011-07-17 19:43:14 +0000 (Sun, 17 Jul 2011)
Log Message:
-----------
Modified behavior when replacing input links: The new target socket for the existing link is now chosen from available sockets that match the _target_ type, instead of the source type. This leads to more usable replacements, e.g. for toggling inputs on mix nodes. Still not a great solution to the mute/autoconnect problem, but a bit more intuitive for replacements.
Modified Paths:
--------------
trunk/blender/source/blender/editors/space_node/node_edit.c
Modified: trunk/blender/source/blender/editors/space_node/node_edit.c
===================================================================
--- trunk/blender/source/blender/editors/space_node/node_edit.c 2011-07-17 18:51:03 UTC (rev 38460)
+++ trunk/blender/source/blender/editors/space_node/node_edit.c 2011-07-17 19:43:14 UTC (rev 38461)
@@ -2118,9 +2118,9 @@
if(tlink) {
/* try to move the existing link to the next available socket */
if (tlink->tonode) {
- /* is there a free input socket with same type? */
+ /* is there a free input socket with the target type? */
for(sock= tlink->tonode->inputs.first; sock; sock= sock->next) {
- if(sock->type==tlink->fromsock->type)
+ if(sock->type==tlink->tosock->type)
if(nodeCountSocketLinks(snode->edittree, sock) < sock->limit)
break;
}
More information about the Bf-blender-cvs
mailing list