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:
authorLukas Toenne <lukas.toenne@googlemail.com>2012-03-28 11:48:08 +0400
committerLukas Toenne <lukas.toenne@googlemail.com>2012-03-28 11:48:08 +0400
commitf342c7de452dad23a918a79fe034d06fa3c93a80 (patch)
treed79c7dea6be3566264807898ad75135bb81943e7 /source/blender/editors/space_node/node_templates.c
parent12655edc8444b5a09949e7e321869c63b1446389 (diff)
Fix for the node tree nodes.new API function, this wasn't setting the scene and main context pointers in the node template, used by file output node. Also the file output node itself now works in case of scene==NULL (might happen in some contexts).
Diffstat (limited to 'source/blender/editors/space_node/node_templates.c')
-rw-r--r--source/blender/editors/space_node/node_templates.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/editors/space_node/node_templates.c b/source/blender/editors/space_node/node_templates.c
index 3d841b05632..049886b1d66 100644
--- a/source/blender/editors/space_node/node_templates.c
+++ b/source/blender/editors/space_node/node_templates.c
@@ -266,6 +266,8 @@ static void ui_node_link(bContext *C, void *arg_p, void *event_p)
ntemp.type = arg->type;
ntemp.ngroup = arg->ngroup;
+ ntemp.scene = CTX_data_scene(C);
+ ntemp.main = CTX_data_main(C);
if (event == UI_NODE_LINK_DISCONNECT)
node_socket_disconnect(bmain, ntree, node_to, sock_to);