Changeset View
Changeset View
Standalone View
Standalone View
source/blender/compositor/nodes/COM_CompositorNode.cpp
| Show All 35 Lines | bool is_active = (editorNode->flag & NODE_DO_OUTPUT_RECALC) || | ||||
| context.isRendering(); | context.isRendering(); | ||||
| bool ignore_alpha = (editorNode->custom2 & CMP_NODE_OUTPUT_IGNORE_ALPHA) != 0; | bool ignore_alpha = (editorNode->custom2 & CMP_NODE_OUTPUT_IGNORE_ALPHA) != 0; | ||||
| NodeInput *imageSocket = this->getInputSocket(0); | NodeInput *imageSocket = this->getInputSocket(0); | ||||
| NodeInput *alphaSocket = this->getInputSocket(1); | NodeInput *alphaSocket = this->getInputSocket(1); | ||||
| NodeInput *depthSocket = this->getInputSocket(2); | NodeInput *depthSocket = this->getInputSocket(2); | ||||
| CompositorOperation *compositorOperation = new CompositorOperation(); | CompositorOperation *compositorOperation = new CompositorOperation(); | ||||
| compositorOperation->setScene(context.getScene()); | |||||
| compositorOperation->setSceneName(context.getScene()->id.name); | compositorOperation->setSceneName(context.getScene()->id.name); | ||||
| compositorOperation->setRenderData(context.getRenderData()); | compositorOperation->setRenderData(context.getRenderData()); | ||||
| compositorOperation->setViewName(context.getViewName()); | compositorOperation->setViewName(context.getViewName()); | ||||
| compositorOperation->setbNodeTree(context.getbNodeTree()); | compositorOperation->setbNodeTree(context.getbNodeTree()); | ||||
| /* alpha socket gives either 1 or a custom alpha value if "use alpha" is enabled */ | /* alpha socket gives either 1 or a custom alpha value if "use alpha" is enabled */ | ||||
| compositorOperation->setUseAlphaInput(ignore_alpha || alphaSocket->isLinked()); | compositorOperation->setUseAlphaInput(ignore_alpha || alphaSocket->isLinked()); | ||||
| compositorOperation->setActive(is_active); | compositorOperation->setActive(is_active); | ||||
| Show All 11 Lines | |||||