/* make sure all group node in ntree, which use ngroup, are sync'd */ void node_group_verify(struct bNodeTree *ntree, struct bNode *node, struct ID *id) { /* check inputs and outputs, and remove or insert them */ if (node->id==id) { bNodeTree *ngroup= (bNodeTree*)node->id; group_verify_socket_list(ntree, node, &node->inputs, SOCK_IN, &ngroup->inputs); group_verify_socket_list(ntree, node, &node->outputs, SOCK_OUT, &ngroup->outputs); } }
void node_group_output_verify(bNodeTree *ntree, bNode *node, ID *id) { /* check inputs and outputs, and remove or insert them */ if (id == (ID *)ntree) { /* value_in_out inverted for interface nodes to get correct socket value_property */ group_verify_socket_list(ntree, node, &ntree->outputs, &node->inputs, SOCK_IN); /* add virtual extension socket */ nodeAddSocket(ntree, node, SOCK_IN, "NodeSocketVirtual", "__extend__", ""); } }