Save Custom AOVs from lua
Posted: Fri Feb 03, 2023 10:18 am
Hi, I'm trying to save Custom AOVs from lua scripting but when trying I get always the same error "not all the passes for tonemaping are enabled". I create an AOV node, connect it to the render target, enable it and save it with the correct render id pass. I'd appreciate it if someone can tell what I'm doing wrong. The code:
thanks
- Code: Select all
--Create AOV node
renderTarget = octane.render.getRenderTargetNode()
AOV = octane.node.create
{
type = octane.NT_AOV_CUSTOM,
name = "AOV_Custom",
}
renderTarget:connectTo(octane.P_RENDER_PASSES, AOV)
--Enable AOV and save it
AOV:setPinValue(octane.P_SUB_TYPE, 0)
AOV:setPinValue(octane.P_ENABLED, true)
octane.render.saveRenderPass3(501, string.format("%s/%s_%s_mask_%04d.exr", basepath, basename, maskName[idx], imagenumber), img_type, propsRenderColorSpaceInfo, 0, exr_comp)
end
thanks