diff options
Diffstat (limited to 'source/blender/compositor/nodes/COM_DefocusNode.cpp')
-rw-r--r-- | source/blender/compositor/nodes/COM_DefocusNode.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/compositor/nodes/COM_DefocusNode.cpp b/source/blender/compositor/nodes/COM_DefocusNode.cpp index c2bd8997525..c2d25bbccd8 100644 --- a/source/blender/compositor/nodes/COM_DefocusNode.cpp +++ b/source/blender/compositor/nodes/COM_DefocusNode.cpp @@ -42,9 +42,9 @@ DefocusNode::DefocusNode(bNode *editorNode) : Node(editorNode) void DefocusNode::convertToOperations(ExecutionSystem *graph, CompositorContext *context) { bNode *node = this->getbNode(); - Scene *scene = (Scene *)node->id; - Object *camob = (scene) ? scene->camera : NULL; NodeDefocus *data = (NodeDefocus *)node->storage; + Scene *scene = node->id ? (Scene *)node->id : context->getScene(); + Object *camob = scene ? scene->camera : NULL; NodeOperation *radiusOperation; if (data->no_zbuf) { |