0
$\begingroup$

I need to save both the 'Combined' pass and the 'indexOB' pass. Is there a simple way to use it with Python? I set the path to save my render -

bpy.context.scene.render.filepath

I can also set the image mode:

bpy.data.scenes['Scene'].render.image_settings.color_mode = 'BW'

enter image description here

But how can I select the render pass?

$\endgroup$
8
  • $\begingroup$ If you want to save the passes, create a file output node in the compositor, done. Related: blender.stackexchange.com/a/215487/31447, one of our famous q&a's: Controling compositor by python $\endgroup$
    – brockmann
    Commented Aug 27, 2021 at 19:09
  • $\begingroup$ How to create the file output node: Output Node with Python $\endgroup$
    – brockmann
    Commented Aug 27, 2021 at 19:16
  • $\begingroup$ If I use the File output nodes, I can't set the File Subpath value with Python. This means I can't set a propper name for the file. $\endgroup$
    – Mapper720
    Commented Aug 28, 2021 at 8:55
  • $\begingroup$ You can do whatever you want with the file output node. I'd suggest add more details to your question and what exactly you'd like to do - sounds like a XY question to me. Recommend the following post to understand the concept: blender.stackexchange.com/questions/16152/… $\endgroup$
    – brockmann
    Commented Aug 28, 2021 at 10:14
  • $\begingroup$ I want to automatize the render process. At every frame Blender should: 0. Render the frame 1. Save the render 2. Save the IndexOB pass 3. Save the 'Normal' matcap view; 4. And every image should have the propper name. I think the list of names will be stored in a text file. $\endgroup$
    – Mapper720
    Commented Aug 28, 2021 at 11:40

0

You must log in to answer this question.

Browse other questions tagged .