Author Topic: Substance in 3ds Max - Corona Renderer  (Read 2689 times)

We're currently working with Redshift renderer to get something working with them, and starting some patch releases on 2.4.

Have some time allocated with the 2.4.1 release, will try to look at it this week for that, while 2.5 is in testing for a bit.
Last Edit: September 21, 2020, 05:41:50 am
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries

Does this only happen with Corona 6? I'll update to that, but I don't seem to see anything with Corona 5 and the 2.4.1 build. I'll mess with the denoising settings and make a more complicated scene after updating that.
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries

Okay, I found out what it is now. I checked with both 2020 and 2021 with the most current dev build.

So from the test scene, you have the 'SubstanceRendererCompatibility' scripts set up to run pre/post render, which will replace the Substance outputs with bitmaps. These aren't needed, so you should remove them from the render setup, under scripts, where there is options to remove them.

What is happening is that when they are run, the post-render callback is being fired by Corona before the denoising step, as it views denoising as occurring after the render is completed. So there is an odd timing where the files have been deleted before the denoiser can run, causing it to crash sometimes, or error out if it doesn't crash.

The plugin in its most recent versions should stop displaying this at all, or running it automatically. I'm thinking we're just going to remove them wholesale in the future. The main renderer this was used for was Redshift, and with 2.5.0, we should have some real interop capacity with Redshift, so they will be unnecessary I think.

I'll be looking at the UV coordinates as well. I believe what's happening there is that the 'duplicate' that Corona is referencing is not being updated with the UV coordinates when the node being displayed is.
Last Edit: September 24, 2020, 06:48:33 pm
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries

Any luck?

For tiling? Not yet, but I'm going to finish it before the 2.4.1 release. It's the last thing we have planned to complete for that release.

For the crash, there is no fix on the plugin side that I know of, you need to remove those scripts from your render settings as per the instructions above. The concept of what they're doing looks like it will cause trouble. So they can't be fixed for that purpose, they can only not be run.
Last Edit: October 08, 2020, 04:19:16 am
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries

Looks like I have something promising for tiling, the initial estimation of what the issue was looks to be correct.
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries

There were a number of issues I documented, but the main issue was the UV tiling and the rendering crash I reported.

1. It sounds like the rendering crash can be solved by just removing the post-render scripts you pointed out?
2. UV tiling is under investigation
3. Other issues like substance parameters not loading correctly and Substance to Corona converter not including advanced parameters is on the roadmap?

1. Should be solved by removing those scripts.
2. Should be in review and testing soon, I now have that working at least between renders. That should be in 2.4.1, which should be done when this clears testing.
3. Will need to look at still.
Last Edit: October 12, 2020, 10:29:06 pm
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries

I do now have tiling working and updating in interactive render, so I think we should have that working for the next release.
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries

Niiiiiice! 👍

Just to be clear the post-render scripts you alluded to before that were related to the crash I reported, is there a reason to include those - or will they be included - as a part of the next release?

I do want to call attention to an issue from before where I had shown (video) that some parameters from imported SBSAR in Max / Corona Renderer were resetting to a max float value of 99. For example I had a float parameter that went up to 128, another to 16384, but the SBSAR parameters in Slate Material Editor imported as 99 and would reset to 99 after being adjusted in the editor.

If you need additional documentation of this, let me know and I'll post another video.

Those scripts are useful for renderers that do not handle substance outputs and do not fire the pre/post render events. VRay GPU is really the only one that historically did this, and that may not be true with its more recent versions.

Even if we disable them, scenes could reference them, so we will probably always ship them and disable them to do nothing when the time comes.

I'll try to take a look at resetting parameters, but it will probably be in 2.4.2, as I want to release 2.4.1 after we finish testing final changes. If you can email me just the sbsar file without a scene, that will be more useful than a video.
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries

I'll go ahead and send you the .SBSAR

The other issue to recall is the gamma correction; where and how is that correction being applied or not being applied?

At least Albedo and Glossiness require gamma correction (0.45) to baked outputs from .SBSAR in Slate Material Editor.

It looks like for some reason, a Qt widget was clobbering the input value for integer sliders when creating the slider widget. I should have a fix in for 2.4.2, we'll look at cutting a release after 2.4.1 to have some further changes like this.
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries