Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Letwory <nathan@letworyinteractive.com>2007-04-03 15:24:11 +0400
committerNathan Letwory <nathan@letworyinteractive.com>2007-04-03 15:24:11 +0400
commit9d079a2c2e7f38214e1fdff5b6b0d44dd1e7e731 (patch)
treec0749b28d6b7b79e1ad4d257e18127e29ab3953d /source/blender/python/api2_2x/Node.h
parent5371d956df8a209ea0eff04b6a5df4604641e726 (diff)
* still silent code (enabled through seperate patch)
* changes in alloc/dealloc of pynode internal objects * changes to shd_dynamic.
Diffstat (limited to 'source/blender/python/api2_2x/Node.h')
-rw-r--r--source/blender/python/api2_2x/Node.h59
1 files changed, 21 insertions, 38 deletions
diff --git a/source/blender/python/api2_2x/Node.h b/source/blender/python/api2_2x/Node.h
index 314ba654e83..f4796d1b80b 100644
--- a/source/blender/python/api2_2x/Node.h
+++ b/source/blender/python/api2_2x/Node.h
@@ -30,6 +30,7 @@
* ***** END GPL/BL DUAL LICENSE BLOCK *****
*/
+#ifdef USE_PYNODES /* note: won't work without patch */
#ifndef __NODE_H__
#define __NODE_H__
@@ -39,16 +40,6 @@
#include "RE_shader_ext.h" /* <- ShadeInput Shaderesult TexResult */
-#ifndef SH_NODE_SCRIPT_READY
-#define SH_NODE_SCRIPT_READY 0
-#define SH_NODE_SCRIPT_LOADED 1
-#define SH_NODE_SCRIPT_REPARSE 2
-#define SH_NODE_SCRIPT_NEW 3
-#define SH_NODE_SCRIPT_CREATED 4
-#define SH_NODE_SCRIPT_UPDATED 5
-#define SH_NODE_SCRIPT_ADDEXIST 6
-#endif
-
extern PyTypeObject Node_Type;
extern PyTypeObject ShadeInput_Type;
@@ -58,51 +49,43 @@ extern PyTypeObject ShadeInput_Type;
#define BPy_ShadeInput_Check(v) \
((v)->ob_type == &ShadeInput_Type)
-typedef struct BPy_Node {
- PyObject_HEAD
- bNode *node;
- bNodeStack **inputs;
- bNodeStack **outputs;
- int altered;
-} BPy_Node;
-
typedef struct BPy_ShadeInput {
PyObject_HEAD
ShadeInput *shi;
} BPy_ShadeInput;
typedef struct {
- PyObject_VAR_HEAD /* required python macro */
- bNodeType *typeinfo;
- bNodeStack **inputs;
-} BPy_SockInMap;
-
-typedef struct {
- PyObject_VAR_HEAD /* required python macro */
+ PyObject_VAR_HEAD
bNodeType *typeinfo;
- bNodeStack **outputs;
-} BPy_SockOutMap;
+ bNodeStack **stack;
+} BPy_SockMap;
typedef struct {
- PyObject_HEAD /* required python macro */
+ PyObject_HEAD
bNode *node;
- bNodeStack **outputs;
-} BPy_OutputDefMap;
+} BPy_DefinitionMap;
-typedef struct {
- PyObject_HEAD /* required python macro */
+typedef struct BPy_Node {
+ PyObject_HEAD
bNode *node;
- bNodeStack **outputs;
-} BPy_InputDefMap;
+ bNodeStack **in;
+ bNodeStack **out;
+ ShadeInput *shi;
+} BPy_Node;
extern PyObject *Node_Init(void);
+extern void InitNode(BPy_Node *self, bNode *node);
extern BPy_Node *Node_CreatePyObject(bNode *node);
-extern PyObject *Node_CreateOutputDefMap(BPy_Node *self);
-extern PyObject *Node_CreateInputDefMap(BPy_Node *self);
+extern BPy_DefinitionMap *Node_CreateOutputDefMap(bNode *node);
+extern BPy_DefinitionMap *Node_CreateInputDefMap(bNode *node);
+extern void Node_SetStack(BPy_Node *self, bNodeStack **stack, int type);
+extern void Node_SetShi(BPy_Node *self, ShadeInput *shi);
extern BPy_ShadeInput *ShadeInput_CreatePyObject(ShadeInput *shi);
-extern BPy_SockInMap *Node_getInputs(BPy_Node *self);
-extern BPy_SockOutMap *Node_getOutputs(BPy_Node *self);
extern void Node_dealloc(BPy_Node *self);
extern void ShadeInput_dealloc(BPy_ShadeInput *self);
+#define NODE_INPUTSTACK 0
+#define NODE_OUTPUTSTACK 1
+
#endif /* __NODE_H__*/
+#endif /* USE_PYNODES */