This is a commandline tool, written in PHP for rendering multiple Blender (.blend) files in batch.
It searches the directory it resides in for .blend files and starts rendering them in alphabetical order (when using the -r option).
Or it returns a string that can be copied into your terminal to start the render.
Basically it just rigs the render command for every .blend file together with "&&".
This way, you can safely go to bed, while all your .blend files are sequentially rendered.
-
You need a version of PHP installed on your system. Versions 5 and up should work.
-
PHP needs to be accessible through your terminal (defined in PATH).
-
A version of Blender needs to be installed on your system.
-
Blender needs to be accessed through your terminal:
- OR define blender in your PATH.
More info can be found in Blenders manual.
For MacOS just copy this into your terminal:
echo "alias blender='/Applications/Blender/Blender.app/Contents/MacOS/Blender'" >> ~/.zshrc && source ~/.zshrc - OR put the path of the blender executable into the the variable $path_to_blender at the top of the render_current_dir.php script.
- OR define blender in your PATH.
-
Copy this script into the directory in which your .blend files you want to render are located.
-
Open the terminal at this directory, or navigate to it.
-
In your terminal type:
php render_current_dir.php -r
-
Rendering starts instantly.
-
(Use ctrl+c to cancel the rendering in case of emergency)
-
Copy this script into the directory in which your .blend files you want to render are located.
-
Open the terminal at this directory, or navigate to it.
-
In your terminal type:
php render_current_dir.php
-
Copy the output back into the terminal an press enter.
-
(Use ctrl+c to cancel the rendering in case of emergency)