4

I need a slot to connect multiple links. In the API is an attribute of links to the type of collections:

links = self.inputs ['ListAttrs']. links

for link in links: ...

How can I connect several links in the input node?

  • 1
    If your after some example code: https://svn.blender.org/svnroot/bf-extensions/trunk/py/scripts/addons/io_scene_fbx/cycles_shader_compat.py initialized as node tree, Im using for FBX importer to create node trees. – ideasman42 Sep 11 '13 at 21:57

1 Answers1

3

Links are created using node_tree.links.new:

new(input, output, verify_limits=True)

Add a node link to this node tree

Parameters:

  • input (NodeSocket, (never None)) – The input socket
  • output (NodeSocket, (never None)) – The output socket
  • verify_limits (boolean, (optional)) – Verify Limits, Remove existing links if connection limit is exceeded

Returns: New node link
Return type: NodeLink

Aldrik
  • 9,720
  • 22
  • 56