From e9b0b402cc85533c8b247b174f17f41b1892ef04 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Wed, 20 Mar 2013 18:01:47 +0000 Subject: Changes to compositor output node Make it so compositor output node wouldn't be calculated when Render Result image is not visible on the screen. This makes compositor tree editing more friendly and faster. Also, if there's no viewer image visible on the screen viewer nodes wouldn't be handled. Final rendering keeps unchanged for now. This solves issues when for performance artists are disconnecting compo output node before tweaking values in compositor and forgets to attach compo output node before sending file to the farm. --- source/blender/compositor/operations/COM_CompositorOperation.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'source/blender/compositor/operations/COM_CompositorOperation.cpp') diff --git a/source/blender/compositor/operations/COM_CompositorOperation.cpp b/source/blender/compositor/operations/COM_CompositorOperation.cpp index 43f491ad2d9..81e86efed42 100644 --- a/source/blender/compositor/operations/COM_CompositorOperation.cpp +++ b/source/blender/compositor/operations/COM_CompositorOperation.cpp @@ -50,12 +50,16 @@ CompositorOperation::CompositorOperation() : NodeOperation() this->m_depthInput = NULL; this->m_ignoreAlpha = false; + this->m_active = false; this->m_sceneName[0] = '\0'; } void CompositorOperation::initExecution() { + if (!this->m_active) + return; + // When initializing the tree during initial load the width and height can be zero. this->m_imageInput = getInputSocketReader(0); this->m_alphaInput = getInputSocketReader(1); @@ -70,6 +74,9 @@ void CompositorOperation::initExecution() void CompositorOperation::deinitExecution() { + if (!this->m_active) + return; + if (!isBreaked()) { Render *re = RE_GetRender(this->m_sceneName); RenderResult *rr = RE_AcquireResultWrite(re); -- cgit v1.2.3