53 char new_name[
sizeof(tno->
name)];
57 const char *name = tno->
name;
64 for (; i; i = i->
next) {
70 if (new_name[0] ==
'\0') {
71 int len = strlen(name);
72 if (
len >= 4 && sscanf(name +
len - 4,
".%03d", &suffix) == 1) {
78 if (new_len > (
sizeof(tno->
name) - 1)) {
79 new_len = (
sizeof(tno->
name) - 1);
86 sprintf(new_name + new_len - 4,
".%03d", ++suffix);
89 if (new_name[0] !=
'\0') {
100 while (tnode->
prev) {
105 for (; tnode; tnode = tnode->
next) {
114 node->custom1 = index;
122 strcpy(tno->
name,
"Default");
#define NODE_CLASS_OUTPUT
void node_type_socket_templates(struct bNodeType *ntype, struct bNodeSocketTemplate *inputs, struct bNodeSocketTemplate *outputs)
void node_type_init(struct bNodeType *ntype, void(*initfunc)(struct bNodeTree *ntree, struct bNode *node))
void node_type_size_preset(struct bNodeType *ntype, eNodeSizePreset size)
void node_type_storage(struct bNodeType *ntype, const char *storagename, void(*freefunc)(struct bNode *node), void(*copyfunc)(struct bNodeTree *dest_ntree, struct bNode *dest_node, const struct bNode *src_node))
void node_type_exec(struct bNodeType *ntype, NodeInitExecFunction init_exec_fn, NodeFreeExecFunction free_exec_fn, NodeExecFunction exec_fn)
void nodeRegisterType(struct bNodeType *ntype)
char * BLI_strncpy(char *__restrict dst, const char *__restrict src, size_t maxncpy) ATTR_NONNULL()
void *(* MEM_callocN)(size_t len, const char *str)
static const pxr::TfToken out("out", pxr::TfToken::Immortal)
static void assign_index(struct bNode *node)
static void copy(bNodeTree *dest_ntree, bNode *dest_node, const bNode *src_node)
void register_node_type_tex_output(void)
static void unique_name(bNode *node)
static bNodeSocketTemplate inputs[]
static void exec(void *data, int UNUSED(thread), bNode *node, bNodeExecData *UNUSED(execdata), bNodeStack **in, bNodeStack **UNUSED(out))
static void init(bNodeTree *UNUSED(ntree), bNode *node)
void tex_input_rgba(float *out, bNodeStack *in, TexParams *params, short thread)
void tex_node_type_base(struct bNodeType *ntype, int type, const char *name, short nclass)
void params_from_cdata(TexParams *out, TexCallData *in)
void node_copy_standard_storage(bNodeTree *UNUSED(dest_ntree), bNode *dest_node, const bNode *src_node)
void node_free_standard_storage(bNode *node)
Compact definition of a node socket.