Mtl override - opacity

Hi

Im testing Corona 16 daily and I have noticed that when using mtl. override in a material with metalness, its opacity isnt show correctly because metalic materials cant use Thin shell, but it depends if you turn it on previously.

The “good news” is that if youre not using mtl override theres no issue as far as I have tested.

In Corona 15 the opacity isnt displayed correcty even with thin shell activated.

Thanks, we will check this.

Hi,

I cannot reproduce it with newly created PhysicalMtl.
I guess you have earlier created materials which are converted to PhysicalMtl, right?

Nop, but I created them when Physical Material was introduced, still, if that would be the case, it needs to be fixed for “old” scenes.

Also I have tested in a newly scene and new physical mtl and still occurs in Corona 15, but… I found that If I use only unsupported its “fixed”, really odd.

Its also “solved” In Corona 16 preview when using Only unsupported with metalness without using “thin shell”

@ChuckRT you have “preserve opacity” enabled in mtl override settings. So whatever opacity you use in your override material, the original material’s opacity will be used instead.

This also explains why enabling “only unsupported” helps - you are actually disabling the override then (it is not applied to supported objects).

The only thing I don’t understand right now is why in some scenarios it “worked” for you - i.e. it did use the override material’s opacity despite “preserve opacity” being on.

Can you attach a sample scene?

Sorry I forgot to attach the scene

Its in Max 23 with 2 materials that uses opacity and the HDR for environment light

Override Opacity.zip (7.3 MB)

@ChuckRT mystery solved:

  • the culprit is volumetric absorption which is “internally” enabled for the override material
  • this is not visible if the override material is applied to a fully opaque object - because you cannot see its inside then
  • when the original material has some opacity value/texture and you enable the “preserve opacity” option for the override mtl - the inside of the object becomes visible thanks to the opacity map used in the object’s original material and the volumetric inside becomes visible according to the override material’s properties

Fix:

In your Clay material, expose additional params, and:

  • set absorption distance to 0
    and/or
  • set volumetric absorption color to pure white

(alternatively, you can enable volumetric effects in the Clay material, for example by lowering opacity, and fix those properties in the usual UI)

Fix these properties:

Result:

How I found out:

I placed a light inside of that problematic object and noticed that it gets darker the further I move it inside the object. This made me thing this was some volumetric effect. Then I ran the attached script to compare properties of a new Corona Physical Mtl and Clay. Absorption distance was highlighted in red because in a new material it is set to 0 and in Clay it was set to 3.

ObjectMaterialPropertyComparer.zip (1.9 KB)

I wouldn’t say this is a bug and I would call it expected, but since it doesn’t make any practical sense and is unexpected from the user point of view, I will report it. It’s probably very uncommon to encounter though. :slight_smile: