Page 1 of 1

Gussian Scatter as surface property

Posted: Mon Mar 23, 2020 4:16 pm
by Meinhard
Hello together,

Is there a material node that scatters like the Gaussian Scatter function. I know that glossy material works with the Schlick brdf. Is there a way to kompare the Schlick model with the Gaussian model?


If not is it hard to implement?

Thanks,

Meinhard

Re: Gussian Scatter as surface property

Posted: Mon Mar 23, 2020 4:42 pm
by Dade
Meinhard wrote: Mon Mar 23, 2020 4:16 pm Is there a material node that scatters like the Gaussian Scatter function.

I know that glossy material works with the Schlick brdf. Is there a way to kompare the Schlick model with the Gaussian model?

If not is it hard to implement?
Probably no but it depends also on what do you mean exactly with "Gaussian distribution": a Gaussian distribution around the perfect specular reflection ? Something like https://support.photonengr.com/article/ ... tter-model ?

Re: Gussian Scatter as surface property

Posted: Mon Mar 23, 2020 5:04 pm
by Meinhard
Yeah i mean a gaussian distrubution around the specular Reflection.

The formula i have is similar:

f(\rho)=C * exp^(\rho)^2/(2\sigma^2)]

with
\sigma=1/(sqrt(2ln(2)) * HWHM
and
\rho$is the angle between the normal and the scattered normal

Anyone know how to implement this?

Can i take the cpp and change the parameters of the oren nayar model or the Schlick scattering to the parameters of the gaussian model? Or are these Scattering functions working different?

Thanks

Re: Gussian Scatter as surface property

Posted: Mon Mar 23, 2020 5:15 pm
by Dade
Meinhard wrote: Mon Mar 23, 2020 5:04 pm Yeah i mean a gaussian distrubution around the specular Reflection.

The formula i have is similar:

f(\rho)=C * exp^(\rho)^2/(2\sigma^2)]

with
\sigma=1/(sqrt(2ln(2)) * HWHM
and
\rho$is the angle between the normal and the scattered normal

Anyone know how to implement this?

Can i take the cpp and change the parameters of the oren nayar model or the Schlick scattering to the parameters of the gaussian model?
Not really, you need to implement a custom Material. This, for instance, is the implementation of the matte material (the most simple material available): https://github.com/LuxCoreRender/LuxCor ... /matte.cpp

The most important methods are Material::Evaluate() (given a known incoming and outgoing direction evaluate the material)
Material::Sample() (given a known incoming direction sample an outgoing direction). It is not a trivial task at all.

Re: Gussian Scatter as surface property

Posted: Mon Mar 23, 2020 6:39 pm
by Meinhard
Ah i see. Schicks Brdf alone has no scattering. Its just an alternative for Fresnel?
In the glossy Material is also a lambertian scattering implemented?

Re: Gussian Scatter as surface property

Posted: Mon Mar 23, 2020 9:53 pm
by Dade
Meinhard wrote: Mon Mar 23, 2020 6:39 pm Ah i see. Schicks Brdf alone has no scattering. Its just an alternative for Fresnel?
In the glossy Material is also a lambertian scattering implemented?
Yes, glossy material is a lambertian layer plus a Schlick coating.