Fix #19604: defocus node was not using camera object yet. Could use
a proper fix, but for now this makes things work again.
This commit is contained in:
@@ -4119,7 +4119,7 @@ static void composite_patch(bNodeTree *ntree, Scene *scene)
|
||||
bNode *node;
|
||||
|
||||
for(node= ntree->nodes.first; node; node= node->next)
|
||||
if(node->id==NULL && ELEM(node->type, CMP_NODE_R_LAYERS, CMP_NODE_COMPOSITE))
|
||||
if(node->id==NULL && ELEM3(node->type, CMP_NODE_R_LAYERS, CMP_NODE_COMPOSITE, CMP_NODE_DEFOCUS))
|
||||
node->id= &scene->id;
|
||||
}
|
||||
|
||||
|
@@ -253,7 +253,8 @@ static void defocus_blur(bNode *node, CompBuf *new, CompBuf *img, CompBuf *zbuf,
|
||||
|
||||
// get some required params from the current scene camera
|
||||
// (ton) this is wrong, needs fixed
|
||||
Object* camob = NULL; // XXX G.scene->camera;
|
||||
Scene *scene= (Scene*)node->id;
|
||||
Object* camob = (scene)? scene->camera: NULL;
|
||||
if (camob && camob->type==OB_CAMERA) {
|
||||
Camera* cam = (Camera*)camob->data;
|
||||
cam_lens = cam->lens;
|
||||
|
Reference in New Issue
Block a user