2

Input and output sockets do not work the same way. The picture seen sockets input and output node "ObjectProps". The socket input button is drawn, while the output socket - no. Who knows the reason? How to make a button in the output socket? enter image description here

1 Answers1

4

This is a missing feature of the node API. There is a patch for this ready and waiting, but since it changes the way node sockets look i want to wait for green light from scripters before committing to trunk.

See bf-committers thread

UPDATE: This feature has been added in trunk now (r60661). Socket draw functions are responsible for drawing only labels if that is the desired behavior, otherwise inputs and outputs draw the same way. See the API changes wiki page.

lukas_t
  • 3,024
  • 13
  • 14
  • I want to draw a button on the socket output. But it does not work. How can draw a button on the socket output?

    The socket input is possible, and in the socket output is not possible. Why?

    – Alexander Nedovizin Sep 07 '13 at 12:46
  • (Also note: in the Properties of N-panel socket output is not adjudged. Input socket is there) – Alexander Nedovizin Sep 07 '13 at 13:42
  • This is just what that patch fixes. You can then use the socket.in_out and socket.is_linked properties to distinguish by input/output and connection to produce the behavior you want. – lukas_t Sep 07 '13 at 13:57
  • Need to change the module source/blender/editors/space_node/drawnode.c and compile the application Blender?

    Can you give a link to the finished compiled Blender with this patch?

    – Alexander Nedovizin Sep 07 '13 at 14:25