Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLukas Tönne <lukas.toenne@gmail.com>2014-03-02 20:04:24 +0400
committerLukas Tönne <lukas.toenne@gmail.com>2014-03-02 20:04:24 +0400
commita89ef76136b8a529e1a4755a8b411da93ed81651 (patch)
tree2901603c302fae90d9151a714487fbb70dc84b36 /source/blender/nodes
parent503a9733d18f5da1002c7ca13701c9aff03d21b5 (diff)
Fix for own mistake: arc diff swallowed a commit somehow, breaking
compilation.
Diffstat (limited to 'source/blender/nodes')
-rw-r--r--source/blender/nodes/intern/node_socket.c2
-rw-r--r--source/blender/nodes/intern/node_util.c7
-rw-r--r--source/blender/nodes/shader/nodes/node_shader_tex_wave.c4
3 files changed, 5 insertions, 8 deletions
diff --git a/source/blender/nodes/intern/node_socket.c b/source/blender/nodes/intern/node_socket.c
index b791f6f7393..b30658fa2be 100644
--- a/source/blender/nodes/intern/node_socket.c
+++ b/source/blender/nodes/intern/node_socket.c
@@ -56,7 +56,6 @@ struct bNodeSocket *node_add_socket_from_template(struct bNodeTree *ntree, struc
bNodeSocket *sock = nodeAddStaticSocket(ntree, node, in_out, stemp->type, stemp->subtype, stemp->identifier, stemp->name);
sock->flag |= stemp->flag;
- sock->internal_links = stemp->internal_links;
/* initialize default_value */
switch (stemp->type) {
@@ -118,7 +117,6 @@ static bNodeSocket *verify_socket_template(bNodeTree *ntree, bNode *node, int in
sock->type = stemp->type;
sock->limit = (stemp->limit == 0 ? 0xFFF : stemp->limit);
sock->flag |= stemp->flag;
- sock->internal_links = stemp->internal_links;
BLI_remlink(socklist, sock);
diff --git a/source/blender/nodes/intern/node_util.c b/source/blender/nodes/intern/node_util.c
index 8fb455cd319..d3bde0a3b56 100644
--- a/source/blender/nodes/intern/node_util.c
+++ b/source/blender/nodes/intern/node_util.c
@@ -183,7 +183,6 @@ static int node_datatype_priority(eNodeSocketDatatype from, eNodeSocketDatatype
/* select a suitable input socket for an output */
static bNodeSocket *select_internal_link_input(bNode *node, bNodeSocket *output)
{
- const bool *allowed_inputs = output->internal_links;
bNodeSocket *selected = NULL, *input;
int i;
int sel_priority = -1;
@@ -195,9 +194,9 @@ static bNodeSocket *select_internal_link_input(bNode *node, bNodeSocket *output)
bool preferred;
if (nodeSocketIsHidden(input) || /* ignore hidden sockets */
- (allowed_inputs && !allowed_inputs[i]) || /* ignore if input is not allowed */
+ input->flag & SOCK_NO_INTERNAL_LINK || /* ignore if input is not allowed for internal connections */
priority < 0 || /* ignore incompatible types */
- (priority < sel_priority)) /* ignore if we already found a higher priority input */
+ priority < sel_priority) /* ignore if we already found a higher priority input */
continue;
/* determine if this input is preferred over the currently selected */
@@ -234,7 +233,7 @@ void node_update_internal_links_default(bNodeTree *ntree, bNode *node)
output = link->fromsock;
if (link->fromnode != node || output->link)
continue;
- if (nodeSocketIsHidden(output))
+ if (nodeSocketIsHidden(output) || output->flag & SOCK_NO_INTERNAL_LINK)
continue;
output->link = link; /* not really used, just for tagging handled sockets */
diff --git a/source/blender/nodes/shader/nodes/node_shader_tex_wave.c b/source/blender/nodes/shader/nodes/node_shader_tex_wave.c
index a052817e9aa..e502f7d9d31 100644
--- a/source/blender/nodes/shader/nodes/node_shader_tex_wave.c
+++ b/source/blender/nodes/shader/nodes/node_shader_tex_wave.c
@@ -41,8 +41,8 @@ static bNodeSocketTemplate sh_node_tex_wave_in[] = {
const bool internal_links[5] = {0,0,0,0,0};
static bNodeSocketTemplate sh_node_tex_wave_out[] = {
- { SOCK_RGBA, 0, N_("Color"), 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 1.0f, PROP_NONE, 0, internal_links},
- { SOCK_FLOAT, 0, N_("Fac"), 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 1.0f, PROP_FACTOR, 0, internal_links},
+ { SOCK_RGBA, 0, N_("Color"), 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 1.0f, PROP_NONE, SOCK_NO_INTERNAL_LINK},
+ { SOCK_FLOAT, 0, N_("Fac"), 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 1.0f, PROP_FACTOR, SOCK_NO_INTERNAL_LINK},
{ -1, 0, "" }
};