Page 1 of 1

Batch Render from command line _ LUA script

PostPosted: Thu Feb 28, 2019 9:31 pm
by calus
Octane command line doesn't provide a built-in way for batch rendering animation,
so here is an advanced LUA script for that.

cmdBatchRender.lua
(22.23 KiB) Downloaded 1097 times

This is a hack based on the batch rendering script shipping with Octane.


USAGE:

--script path to this script -a output path -a render targets -a image format -a start frame -a end frame -a max samples

(arguments -a are optional)


- If no render targets name arguments are provided in the command line, then all render targets are rendered.
- if no start/end frame argument is provided then the entire timeline is rendered.
- If no output path argument is provided, an "images" folder is created for that next to the orbx/ocs file.
- Number arguments have an expected order : start frame, end frame, max samples. (as the script have no way to guess which number argument is for what)
- Image format for a specific render target must be declared before the render target.


Windows command line example :
Code: Select all
octane.exe C:\test.orbx --no-gui --script C:\cmdBatchRender.lua -a C:/images/ -a 1 -a 100 -a 1024 -a EXR16 -a renderTarget1


keywords for image format : PNG8, PNG16, EXR16, EXR16TONEMAPPED, EXR, EXRTONEMAPPED


Default settings are easy to change at the top of the script.

Re: Batch Render from command line _ LUA script

PostPosted: Fri Mar 01, 2019 2:15 pm
by glimpse
thank You!

Re: Batch Render from command line _ LUA script

PostPosted: Tue Apr 02, 2019 10:34 pm
by cgpanda
Thanks for the script!

Is there a way to render multiple projects? Like a render queue.

I have for example 17 stand alone projects. I would love to let it render overnight one by one.

Thanks in advance!

Re: Batch Render from command line _ LUA script

PostPosted: Fri May 01, 2020 12:32 pm
by psclcr
Thanks!
This is exactly what i am looking for!

But i could not figure out how to make it work... :?

i am using Octane Stand alone 3.07.
I have 5 .ocs files
Each have 30 Render Target in it
No animation , just one PNG8 image to render

Actually i do with command line that will "open ocs+render 1 target+exit" so it means 5x30=150 times! open/exit time loss.
What i would like is "open+render all 30 targets+exit" ... one ocs file after the other (5 times)

Any help would be much appreciated

Re: Batch Render from command line _ LUA script

PostPosted: Fri Sep 18, 2020 7:17 am
by Hesekiel2517
I would love to use this, but it gives me errors. Is there a quick way to fix this?

BadArgument.JPG


Thank you in advance!

Re: Batch Render from command line _ LUA script

PostPosted: Wed Aug 04, 2021 2:41 am
by Renbry
Hey there. seems to be a bug i'm chasing down with support. I'll post any fixes i can get asap. i know this is a while after you posted but it's a big problem that i'd like to solve.

Re: Batch Render from command line _ LUA script

PostPosted: Wed Aug 04, 2021 4:54 am
by karl
Here is an updated version of the script that works with Octane 2020.2.

Usage is the same, except that you now specify the image save format (PNG_8 (default), PNG_16, EXR_16, EXR_32) and the color space (SRGB (default), LINEAR_SRGB, ACES2065_1, ACESCG) separately.

To get the same behavior as the old EXR16 you would pass EXR_16 LINEAR_SRGB now.

(Outputting to OCIO color spaces doesn't work - hooking up the OCIO color space name and look name to the script's command line parameters is left as an exercise for the reader).

Re: Batch Render from command line _ LUA script

PostPosted: Tue Feb 27, 2024 9:26 pm
by Hesekiel2517
Hi Karl,

i really love this script. It's the best way imho to batch render orbx files locally. Sadly the script does not work in 2023. It would be really nice, if you could look into it. Thanks in advance!

Re: Batch Render from command line _ LUA script

PostPosted: Tue Feb 27, 2024 10:46 pm
by karl
Here's an updated version of the script that works in 2023.1.x. Let me know if there are any problems.

Re: Batch Render from command line _ LUA script

PostPosted: Wed Mar 13, 2024 3:47 pm
by Hesekiel2517
Thank you so much!