Help Topic: VRayBlendMtl - How to properly blend specular layers.

Hello All,

Once again I have to apologise for this question. I may have asked about it before in the past but can remember the answer. I wish to know the proper way to layer a specular material onto a base material. (For use in skin shading and other complex materials)

I have 3 renders

01 - Base Material is a VRay Material with the Parameters set. I wish to re-create this material with a blended shader network.
02 - Falloff Blended is a VRayBlendMtl that blends both materials based on a falloff
03 - Additive Blended is a VRayblendMtl with Additive mode on. It looks closest to the original but still slightly different.

Scene file for testing https://drive.google.com/open?id=0B3…0ZZR2dKR1JnbGM

The other two images are shader networks that show how I set the blend materials up. I am not able to recreate the specular reflection of the original material. What is the correct way to recreate the original material using a VRayBlenMaterial?

Thank you.

Steve ~





You could try with an hdr dome light to see the differences better, but here is what I can see from this:

- The Falloff blend should be the correct one, likely the difference comes from the glossy Fresnel setting, which affects the Fresnel falloff in the VRayMtl. As the Falloff map does not have this setting it will likely look different if you have this enabled.
You could try a test with glossy Fresnel disabled, and another with using this map which is a falloff-type map which does include a basic version of it:

- The additive blend should be incorrect as there is no falloff in this setup, my guess is that it just happens to look corrent with this light setup. :slight_smile:

Thank you. I am going to re-test this.

One thing you can do is hold Ctrl+Left Click the images to open them in tabs. Then Hit Ctrl+Tab to scroll through and compare each sphere.

I will also test with a HDR dome as you suggested.

Thanks again for your input :slight_smile:

Oh yeah, good tip!

This is crazy…I cant get it to work.

Do you think chaos group should write a falloff map that works properly? Maybe Vray should make the Fake Fresnel map and actual proper one that works just like the VRayMaterial?

https://drive.google.com/open?id=0B3…0ZZR2dKR1JnbGM

Here is the scene file

Ideally, the workflow for this would be possible with the Vray Advanced Plugin and official maps so I can submit the files to production pipeline. Some companies don’t accept OSL to their pipeline.

Did a quick test with that scene, and by using the map I linked to above I can get exactly matching results without Glossy Fresnel enabled. With it enabled (and setting glossiness to 0.5 as well on the Reflector map) it’s somewhat close but not quite, though likely as close as you can get for now. There are some curve parameters on the Reflector map you could try to match it closer.

And I forgot, but the Falloff map does not correctly calculate the Fresnel falloff, it’s too dark in the front. It’s subtle but basically it’s broken.

Thanks for your help. I’m really shocked that this workflow is broken. I hope Chaos group can fix it with a proper falloff texture that replicates the Fresnel of VRay Mtl. I’m going to flag this as a suggestion to fix. Thanks for your help.

No worries! With roughness_falloff set to 0.7 and rhg_darken_brighten set to 0.5 I can get somewhat close. I wrote this before the Glossy Fresnel setting was available in the VRayMtl, now would be a good time to revisit it and match it to the VRayMtl output.

Yeah I will ask Vlado to put this on the todo list

I made a product suggestion here. If you want to put any ideas forward, now is a good time :slight_smile:

Why you don’t you use rens osl?
I’d like to have a native solution too but it should work quite well.

And you could still turn fresnel off and eyeball it using a fake fresnel map.

Or do it the oldscool way and put a falloff in perpendicular/Parallel mode in the blend amount and use the output curve of said map to set it up correctly. (with fresnel disabled)
We’ve been working like that for 10 jears. All three options should give you quite good results.

That’s a very good tutorial for this: https://vimeo.com/94813625

Thank you for the link and the advice

Sorry, but, why is it wrong to use Additive mode?

Using additive mode makes the specular appear almost the same.

Since additive mode breaks energy conservation, is it then up to me to make sure the total reflectance value is energy conserving?

(On a side note - I’m really annoyed and anxious because having a coat material is so fundamentally important! - Does anyone know when Vlado will update this ?..in my opinion VRay cannot create a coat material, these workflows are not goood enough for a high-en render engine. I have to be able to submit work to companies that have expectations and requirements. Not all of them will accept an OSL in their shader networks. Please Vlado, if you see this, I hope you understand how important it is that Vray have a Glossy Coat Material so we can layer speculars.)

Can I just use Additive mode and manually make sure that I dont go past a reflection value brighter than the light source?

I will also try the hacks and tricks but I may just use additive mode as it looks the most correct. It matches the glossy fresnel of the vray material.

I hope vlado can code a coat material soon…like in 1 week.

Scene to test that would be:
A Sphere with many polygons and a dome light with an intensity of 1 and no exposure control, leave the color mapping untouched.

The sphere with the Material should never ever reflect more than 1(the light’s intensity) at any angle. But try to keep it below 0.9 at least.
The numbers are the raw float values exposed as white text in the pixel info dialogue.
You can also make it visible.
Turn off “force color clamping” (the little button in the vfb).
Now you can see where it gets brighter than 1.

You can further use curves to set a different max value. For example, take the upper point and type 0.6 in the first field If you want to make sure your material won’t reflect more than 0.6.

Thank you very much for this.

I think I will use this method until Chaos Group fixes this huge problem with a proper VrayCoatMtl

It would be good to hear from Chaos Group - freed-back regarding the coat material. May I please ask if someone from Chaos Group can comment on the subject of a coat material? it will help release my anxiety to know that a solution is on its way.

Thank you all for being so helpful

Steve ~

I did some research and found that the falloff map is from the scanline render days when they used a falloff in the reflection slot. That’s like, 15 year old tech…

I hope Vray can make their own coat material soon.

Well, the actual math for it is about 200 years old, it’s just not implemented correctly in the Falloff map. :slight_smile: