Vray LightCache for animation (with multi cams)

Discussion and Support of Deadline, the Render Management System
User avatar
nixx
Posts: 241
Joined: Sat Nov 23, 2013 6:53 am

Vray LightCache for animation (with multi cams)

Postby nixx » Mon Jun 12, 2017 4:32 pm

Okay, so I was looking into automating the LightCache submission and ran into this thread > https://forums.thinkboxsoftware.com/vie ... 11&t=15319

Which is kinda almost does what I was looking for.. but not quite so.. so now is the question if it's possible to get this working from within deadline:

We have 1 scene with multiple camera's, each camera has it's own shot name and frame range included;
Sh01a_fr_0-100
Sh01b_fr_0-250
etc..
Besides that we have 2 folders that are relevant:
z:/project/Cache/LightCache/*shotname* > to place the light caches names by each shot (eg. sh01a.vrlmap)
z:/project/render/shots/*shotname* > to place the renders with the subfolder & the filename being the shotname part of the camera.

Ideally we'd have a submit button that would take all camera's in the scenes and submit these to the farm extracting the information from the camera itself based on the 2 preset paths (which have the same common root) where it would create a single frame lightcache over the relevant range of each shot and submit a dependant job (incl. a preview of x frames) using the lightcache file which renders out the whole file sequence.

before we try and create such elaborate thing.. is this even possible to have it to this extend automated or would this need to have a maxscript running as it needs to read out the camera name etc?
m.rckmn.nl

DL 9.0.2.0

User avatar
Bobo
Posts: 5925
Joined: Tue Nov 15, 2005 10:26 am
Location: Vancouver, Canada
Contact:

Re: Vray LightCache for animation (with multi cams)

Postby Bobo » Mon Jun 12, 2017 4:52 pm

We are in the process of expanded SMTD to support custom submission workflows (mostly prompted by that other thread, but also by years of custom SMTD-based submission scripts development).

Basically the new Workfflows system lets you

* define a struct with properties and functions that describe the functionality of the Workflow
* implement a custom submission function to be executed when the SUBMIT button is pressed in the SMTD UI
* implement custom UI layout to define which tabs and rollouts are shown in the SMTD UI when the Workflow is active
* implement a custom UI modification function to disable or hide individual controls from existing rollouts
* implement new custom rollouts and tabs as needed
* implement storing and restoring of Workflow-related properties with the MAX scene, or via INI files
* implement a custom Sanity Check that disables the SUBMIT button if conditions are not met (e.g V-Ray is not the current renderer)
* implement a function to disable the Workflow from appearing in SMTD (e.g. V-Ray is not even installed)

At the moment I have working prototypes of a Submit Max to V-Ray Standalone Workflow, a FumeFX Simulation Submitter Workflow, a Phoenix FD Submitter Workflow, a better Texture Baking Submitter Workflow, and indeed an early version of the VRay Lighting + Rendering passes submitter based on the discussion on this forum.

In other words, your request is what this new system was designed to enable and encourage, and your requirements would be an amazing testbed for its capabilities.
The Workflow feature is currently targeting the next Deadline version, but the new SMTD could be used with Deadline 9 without problems.

So we should start by defining the exact specification of the UI and functionality you need. Exposing a ListView with all Cameras to check the ones to submit would be trivial. Then juggling the multiple submissions, parsing camera names, scanning for/creating the necessary folders for per-shot data, and setting output paths should be quite straight-forward too.
Borislav "Bobo" Petrov
Product Specialist
Thinkbox Software Inc.

User avatar
nixx
Posts: 241
Joined: Sat Nov 23, 2013 6:53 am

Re: Vray LightCache for animation (with multi cams)

Postby nixx » Mon Jun 12, 2017 5:45 pm

ooh, that sounds great!
Would be awesome to have a look at those features.

what can be done to help?
m.rckmn.nl

DL 9.0.2.0

User avatar
Bobo
Posts: 5925
Joined: Tue Nov 15, 2005 10:26 am
Location: Vancouver, Canada
Contact:

Re: Vray LightCache for animation (with multi cams)

Postby Bobo » Mon Jun 12, 2017 6:25 pm

Here is a quick UI prototype using the new system:
SMTDWorkflow_VRayMultiCameraNixx.png
SMTDWorkflow_VRayMultiCameraNixx.png (61.29 KiB) Viewed 147 times


The actual SUBMIT button does not perform the submission of the checked cameras yet, I will be working on that next.
The current function I have in there has the main body of the code from the VRay LC+Render thread on the forum minus the Jigsaw/Tile handling.
I will need to add a loop for the cameras now, and get it to run with just full frame rendering, submitting LC jobs and dependent render jobs.
Then we can look into expanding its feature set.

Can you confirm whether the Cameras will have names that match strictly Sh*_fr_*, or should I handle something like "PhysCamera001_Sh01b_fr_0-250" ?
Borislav "Bobo" Petrov
Product Specialist
Thinkbox Software Inc.

User avatar
nixx
Posts: 241
Joined: Sat Nov 23, 2013 6:53 am

Re: Vray LightCache for animation (with multi cams)

Postby nixx » Mon Jun 12, 2017 6:41 pm

haha, that's quick, cool!

good thing you checked.. we have "cam_" in front of it and I realised it's "fr." instead of "fr_"
not sure if that matters?

cam_list.JPG
cam_list.JPG (55.02 KiB) Viewed 145 times


We use these names at the moment already to generate the previews without needing to use the slow Max preview (it grabs a direct render of the viewport at any resolution)
m.rckmn.nl

DL 9.0.2.0

User avatar
Bobo
Posts: 5925
Joined: Tue Nov 15, 2005 10:26 am
Location: Vancouver, Canada
Contact:

Re: Vray LightCache for animation (with multi cams)

Postby Bobo » Mon Jun 12, 2017 11:23 pm

Thanks, I have corrected the camera name parsing function.
I will work on polishing the submission loop tomorrow.
Borislav "Bobo" Petrov
Product Specialist
Thinkbox Software Inc.

User avatar
Bobo
Posts: 5925
Joined: Tue Nov 15, 2005 10:26 am
Location: Vancouver, Canada
Contact:

Re: Vray LightCache for animation (with multi cams)

Postby Bobo » Tue Jun 13, 2017 4:21 pm

Progress report:

* I now have LC and dependent VRay render jobs submitting for each camera within the same Batch group.
* The LC vrlmap file is written in a subfolder named according to the Shot name in the camera name.
* Currently, the rendOutputFilename path is used as the base name for saving the Shot's LC, but I will expose a control to specify the central location for cache files as in your request. I will do the same for the render output files.
* If the camera has no shot name defined, a name "ShotN" (where N is an integer counter) is generated.
* If the camera has no range defined, the scene range is used instead, but I can make such cameras invalid and just skip them.

The rest of the submission code is more or less identical to what was in the other thread.
I will need to test all the other potential cases like various region rendering options, QuickTime generation from the output files, etc. Some of them might work already, some might need special attention.

Then I can pass the new SMTD files to you to test and expand your custom logic from there...
Borislav "Bobo" Petrov
Product Specialist
Thinkbox Software Inc.

User avatar
nixx
Posts: 241
Joined: Sat Nov 23, 2013 6:53 am

Re: Vray LightCache for animation (with multi cams)

Postby nixx » Tue Jun 13, 2017 5:53 pm

that sounds perfect!

looking forward to giving it a test run!
m.rckmn.nl

DL 9.0.2.0

brodie
Posts: 2
Joined: Wed Oct 30, 2013 1:15 pm

Re: Vray LightCache for animation (with multi cams)

Postby brodie » Thu Jun 29, 2017 3:58 pm

This sounds great. I'm planning to use this mainly for still images actually. I think the way you describe it would work great for 90% of our renders. The only thing I'd add, would be that sometimes we want to adjust layers being on/off as well as the resolution between shots. This is already handled quite well through State Sets within 3ds Max.

So essentially all I'm looking for is to have the functionality that exists within the script that has already been developed by others, but I need to be able to select which State Sets should be rendered. I'm looking into what it would take to add that functionality to the current script but I'm not much of a scripter so if anyone has any tips, let me know.

Here's the current script I'm working from...
https://www.dropbox.com/s/rxq8jfje8ry45mt/Deadline%20LC-IR%20Submit.ms?dl=0

edit: changed Scene States to State Sets

Dave_Wortley
Posts: 454
Joined: Thu Jan 27, 2011 3:55 am
Location: London
Contact:

Re: Vray LightCache for animation (with multi cams)

Postby Dave_Wortley » Mon Jul 03, 2017 10:40 am

@Bobo, there are 2 other scenarios that you need to pre-bake for as well with Tiles Rendering.... IR +LC but also...

Caustic Map and VrayFastSSS2 Mats from VRay 2.35+

And 'Use light Cache for Glossy Rays' must be disabled if using Tiles Rendering.


Rgds

Dave
HydraGen - Developer


Return to “Thinkbox Software - Deadline”

Who is online

Users browsing this forum: kwatts and 1 guest