diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2011-10-12 19:54:53 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2011-10-12 19:54:53 +0400 |
commit | aff03aa7780e4a7d0dafd06f6e1ed3b3cdb90b5b (patch) | |
tree | e8d6a7b76264cc2acf9d6fe68da040529b473a06 /source/blender/blenkernel/BKE_node.h | |
parent | c3c44f8736b7a3d0e57baabf1f8f212f8cb0b1f4 (diff) |
Cycles: tag shading nodes as being compatible with the old/new shading system,
so they only appear in the list when needed. Old shading nodes were previously
disabled entirely, breaking internal renderer compatibility.
Diffstat (limited to 'source/blender/blenkernel/BKE_node.h')
-rw-r--r-- | source/blender/blenkernel/BKE_node.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/source/blender/blenkernel/BKE_node.h b/source/blender/blenkernel/BKE_node.h index 92968f23396..b25bfd4975d 100644 --- a/source/blender/blenkernel/BKE_node.h +++ b/source/blender/blenkernel/BKE_node.h @@ -133,7 +133,7 @@ typedef struct bNodeType { char name[32]; float width, minwidth, maxwidth; float height, minheight, maxheight; - short nclass, flag; + short nclass, flag, compatibility; /* templates for static sockets */ bNodeSocketTemplate *inputs, *outputs; @@ -236,6 +236,10 @@ typedef struct bNodeType { #define NODE_CLASS_SHADER 40 #define NODE_CLASS_LAYOUT 100 +/* nodetype->compatibility */ +#define NODE_OLD_SHADING 1 +#define NODE_NEW_SHADING 2 + /* enum values for input/output */ #define SOCK_IN 1 #define SOCK_OUT 2 @@ -394,6 +398,7 @@ void node_type_exec_new(struct bNodeType *ntype, void (*newexecfunc)(void *data, int thread, struct bNode *, void *nodedata, struct bNodeStack **, struct bNodeStack **)); void node_type_gpu(struct bNodeType *ntype, int (*gpufunc)(struct GPUMaterial *mat, struct bNode *node, struct GPUNodeStack *in, struct GPUNodeStack *out)); void node_type_gpu_ext(struct bNodeType *ntype, int (*gpuextfunc)(struct GPUMaterial *mat, struct bNode *node, void *nodedata, struct GPUNodeStack *in, struct GPUNodeStack *out)); +void node_type_compatibility(struct bNodeType *ntype, short compatibility); /* ************** COMMON NODES *************** */ |