Fix [#20000] Connect to File Output node creates segfault
This commit is contained in:
@@ -1239,7 +1239,7 @@ bNode *node_add_node(SpaceNode *snode, Scene *scene, int type, float locx, float
|
||||
node_set_active(snode, node);
|
||||
|
||||
if(snode->nodetree->type==NTREE_COMPOSIT) {
|
||||
if(ELEM3(node->type, CMP_NODE_R_LAYERS, CMP_NODE_COMPOSITE, CMP_NODE_DEFOCUS))
|
||||
if(ELEM4(node->type, CMP_NODE_R_LAYERS, CMP_NODE_COMPOSITE, CMP_NODE_DEFOCUS, CMP_NODE_OUTPUT_FILE))
|
||||
node->id = &scene->id;
|
||||
|
||||
ntreeCompositForceHidden(snode->edittree, scene);
|
||||
|
||||
@@ -62,7 +62,7 @@ static void node_composit_exec_output_file(void *data, bNode *node, bNodeStack *
|
||||
}
|
||||
}
|
||||
|
||||
BKE_makepicstring(string, nif->name, rd->cfra, nif->imtype, ((Scene *)node->id)->r.scemode & R_EXTENSION);
|
||||
BKE_makepicstring(string, nif->name, rd->cfra, nif->imtype, (rd->scemode & R_EXTENSION));
|
||||
|
||||
if(0 == BKE_write_ibuf((Scene *)node->id, ibuf, string, nif->imtype, nif->subimtype, nif->imtype==R_OPENEXR?nif->codec:nif->quality))
|
||||
printf("Cannot save Node File Output to %s\n", string);
|
||||
|
||||
Reference in New Issue
Block a user