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

Galen, the number one issue I am facing while using the Substance to 3ds Max plugin for Corona Render is parity between the shader created by manually connecting baked outputs versus the auto-generated shader using the Substance to Corona converter.

I need a clear, step-by-step description of the correct gamma, bitmap filtering, mix parameters, etc. for all the relevant maps to replicate exactly the result of the autogenerated shader using the converter.
If it helps, I can record a short video illustrating exactly the problem, but I don't want to keep spinning my wheels trying to guess the correct configuration.

I think I've discovered the correct shader configuration by basically using the mix maps from the auto generated shader using the Substance to Corona converter.

Using maps baked out from the .SBSAR in the Slate Material Editor:

*NOTE: adjustments are contingent upon the output parameters in Substance Designer(!)

Albedo - Automatic (recommended; 2.2) * gamma (0.45)
Gloss - Automatic (recommended; 2.2)
Anisotropy Level - Override (1.0) * gamma (0.45)
Anisotropy Rotation - Override (1.0) * gamma (0.45)
Metallic - Override (1.0)
Normal - Override (1.0) * gamma (0.45)
Displacement - Override (1.0)
Last Edit: November 07, 2020, 01:53:43 am

I'm not certain on the exact gamma values added, I will need to look into that system to see exactly how it was originally constructed. I am not as familiar with that system, as the image baking and caching system has been unchanged since the original release.

I do not think that we are actively applying a gamma curve to anything, but I think that color maps (emissive, basecolor, diffuse, specular) will have an sRGB curve applied and cooked in, which then Max might reapply a curve back on top when loading it back in as a bitmap.
Last Edit: November 05, 2020, 06:15:04 pm
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries

It is known that 3ds Max applies a gamma / LUT correction based on preference settings (Customize > Preferences > Gamma and LUT) and bitmap gamma correction can be applied per bitmap on import (i.e. Automatic (reccommended; 2.2) vs. override (1.0)).

I don't know what the Substance to Corona converter is doing internally as far as gamma correction is applied, but the issue I am raising refers to using bitmaps generated by Substance tools (e.g. Designer, Painter, Alchemist) for the purposes of rendering in an external DCC.

The Substance to Corona converter automatically generates mix maps for the diffuse, reflection, and fIOR channels, but if users try to generate the shader from scratch using bitmaps exported from Substance tools, they will not know that mix maps are needed, how to configure the mix map, or when / where to apply the mix map; on top of the fact that there is a (sort of) arbitrary gamma correction being applied to different bitmaps. This is an obvious usability problem.

Does this make sense? If I create a substance in Designer to render in 3ds Max Corona Renderer, I have two options:

1. Export the .sbsar from Designer, import to Max Slate Material Editor, Substance to Corona converter
2. Export the bitmaps from Designer, import to Max Slate Material Editor, create the shader from scratch - this is where the usability problem starts because there is no official guidance about how this is supposed to be done correctly.

So you want it to be able to operate on an array of image maps instead of only an sbsar file, like we have in Maya? We could provide documentation on what is being done, although the script is open to be inspected, but allowing it to operate on maps from Painter/Designer/Alchemist seems like the better overall solution.

It is possible to do this, as we have done that in the Maya plugin, but it will require some UI work to map usages as well as perhaps some reorganization of how the 'Substance to ...' workflow scripts operate. The system in the Maya plugin is much more sophisticated, so not all features from it can be brought over immediately.
Last Edit: November 06, 2020, 03:10:29 am
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries

That sounds right, but I want to be very clear about what I'm describing so I will go ahead and record a short video to illustrate.

If you have access to Autodesk Maya, you should be able to inspect the workflow options that the Substance plugin has in that. In that we have:

  • Ability to apply a workflow to a Substance material (sbsar)
  • Ability to apply the exact same workflow to a set of images
  • Generate a custom workflow via button, traversing the node graph forward of the substance graph node and saving it
  • Ability to apply these custom workflows to both sbsars and a set of image files, using the same interface as the ones provided

Personally, I would prefer we implement a data-driven node graph setup like we have there, so we can operate on workflows as data instead of linear scripts, as well as being able to generate new ones via traversal of the material graph.
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries

Overview of shader configuration and gamma correction

Hi, I get this error when trying to use substance to corona in one of my scenes, any idea on how to fix this?


@galen Been a while since the last update(?)


2.4.2 is out, there's just no forum post for it. We're working on a 2.4.3 but it won't have that much in it, updating to some changes in 3ds Max.

I'll take a look at the subanim issue.

For the workflow updates, I'll need to go back through, but it won't be as simple to just add. We already have done something similar, but it'll take time to do. I'll need to evaluate whether I can get what I need from 3ds Max's API.

You can look at the scripts, they don't really operate on a set of outputs, but directly from one sbsar. So I would definitely need to restructure them significantly.
Last Edit: January 26, 2021, 03:53:45 pm
Software Engineer, Integrations
Maya, 3ds Max and Core Libraries

How are the maps being computed inside the Substance node? The baked output from the Substance node is not correct, i.e. is not equivalent to what is produced by Substance Player or the Substance node itself.
Last Edit: February 21, 2021, 08:31:17 pm

There needs to be a clear, documented method from Allegorithmic for exporting bitmaps from Substance Player, or by using the baked output feature of the Substance node in the Slate Material Editor, for achieving visual parity to what the Substance node presents itself.

Could you please provide a video demonstrating the following:

1. Import .SBSAR into Slate Material Editor
2. Make adjustments to the imported .SBSAR
3. Render the adjusted .SBSAR in Corona Renderer on a 3d primitive
4. Replicate that render using only bitmaps from the adjusted .SBSAR in the Slate Material Editor

If this is in fact something easily achievable and generalizable using a clear set of instructions, it should only take a few minutes and would be a huge contribution to resolving workflow myths regarding the Substance in 3ds Max plugin for Corona Renderer.
Last Edit: February 22, 2021, 02:05:07 am