1
$\begingroup$

I'm using Blender 3.0 in Windows 10. I'm writing a batch file to invoke Blender to render individual .blend files in series (ie render shot 1, then shot 2, etc) in the background.

The problem is that when I invoke blender from within the batch file, It renders the first .blend file just fine, but since the Blender application does not quit after the render is finished, my batch file is essentially hung (ie. it will never process the next command).

enter image description here

Is there a way to tell Blender that when you run it in background mode, you want it to quit once the render is done? I've looked through the docs extensively on the command line options, but nothing is mentioned.

Any ideas or workarounds? Thanks in advance!

$\endgroup$
3
  • $\begingroup$ I'm not sure I understand the problem. Path_to_blender\blender.exe - b Path_to_blend.blend -f 1 will render a still image and exit on Windows. You can specify other options, like the the render type and file as well. See Command Line Rendering for more details. $\endgroup$ Dec 24, 2021 at 23:51
  • $\begingroup$ Doesn't work for me. Blender WILL render the animation file (an MP4, but I keep my shots short), but once the render is done, Blender remains running in the background. I have done this using Blender 2.X in the past, but in 3.0 it just hangs. I'll try it using 2.9 and see if there is a difference. Thanks Marty! $\endgroup$
    – Kaptkaos
    Dec 25, 2021 at 0:15
  • $\begingroup$ That's weird. It works for me in Windows 10 with 3.0 I wonder if it's a batch file versus command line thing? $\endgroup$ Dec 25, 2021 at 0:23

1 Answer 1

0
$\begingroup$

It took me a while to figure this one out, but I got it working by disabling all of my addons during the render. So one of my addons (not sure which yet) was causing Blender to hang at the end of the animation render.

Instead of disabling all of your addons, using the --factory-startup flag in your command line should accomplish the same result without having to manually disable your addons.

$\endgroup$
1
  • $\begingroup$ Actually just use the '-b' command line option. I do this all the time. $\endgroup$
    – james_t
    Feb 19, 2022 at 19:01

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .