Help understanding Refraction, SSS and Transmission passes?

Forums: Help understanding Refraction, SSS and Transmission passes?
Generic forum to discuss Octane Render, post ideas and suggest improvements.
Forum rules
Please add your OS and Hardware Configuration in your signature, it makes it easier for us to help you analyze problems. Example: Win 7 64 | Geforce GTX680 | i7 3770 | 16GB

Help understanding Refraction, SSS and Transmission passes?

Postby linvanchene » Thu Feb 19, 2015 2:41 pm

linvanchene Thu Feb 19, 2015 2:41 pm
I am experimenting a bit with Specular materials to get a better understanding how they can be used for character renders.

My idea was to have a look at the RenderPasses to get a better understanding which settings to change.

Nevertheless at the moment I am stuck at the basics:

What exactly is the difference between Refraction and a SSS pass? :?:

The way I understand it Refraction is supposed to capture those light rays who are not reflected but actually enter a surface.

But would that not be the same as SSS (Sub Surface Scattering)?

- - -

Test Scene:

Fiber mesh hair with Specular Material.

Character with mix material consisting of glossy and Specular Material.
The Specular Material has Transmission but no Absorbtion and Scattering values.


Examples:

Izarra v1006_Refraction.png
Custom Shader Mix - Refraction Pass


Skin:
In this example you can see how the hair blocks the light from behind so no light rays are able to enter the back head surface.
Nevertheless a lot of rays are able to enter at the shoulder.

Hair: The hair has some refraction.
- - -

Izarra v1006_Subsurface scattering.png
Custom Shader Mix - SSS Pass


Skin:
There does not seem to be any SSS at all for the skin.

Written in Hindsight:
Probably this explains why we should use a specular material with Transmission AND Scattering and not just Transmission when mixing materials.


Hair: The hair has some SSS.
- - -

The first question I encountered was: `

What is the difference between a Refraction and a SSS pass??


In hindsight after experimenting further I try to answer this myself:
If the rays pass trough you find the results in the Refraction pass?
If the rays get stuck somewhere in the geometry you find the result in the SSS pass?

Did I interpret the results properly or is there more to consider?
After all in the case of the fiber mesh hair there is a SSS AND a Refraction part!?!
:|


At the moment I find it very difficult to predict what the SSS, Refraction and Transmission passes will look like when I change the values of Transmission, Scattering and Absorption of a Specular Material.

- - -

I tried to figure this out and experimented further. But the more I experimented the more questions started to raise. :oops:

My confusion increases when I look at the differences in the passes depending on if you use a Diffuse or Specular material.


If you take a Diffuse material with Transmission you get:

Diffuse Material with Transmission - Beauty Pass.jpg
Diffuse Material with Transmission - Beauty Pass


As I would expect the transmission is output in the Transmission pass:

Diffuse Material with Transmission - Transmission Pass.jpg
Diffuse Material with Transmission - Transmission Pass


- - -

But when you create a Specular Material with Transmission things seem to be different:

Specular Material with Transmission - Beauty Pass.jpg
Specular Material with Transmission - Beauty Pass


Now the Transmission is output in the Refraction Pass?!

Specular Material with Transmission - Refraction Pass.jpg
Specular Material with Transmission - Refraction Pass


- - -

Now I add some Scattering to the previous Specular Material.

A Specular Material with Transmission and Scattering:

Specular Material with Scattering - Beauty Pass.jpg
Specular Material with Scattering - Beauty Pass


But now there is nothing to be found anymore in the Refraction Pass.
The result is now displayed in the SSS Pass:

Specular Material with Scattering - SSS Pass.jpg
Specular Material with Scattering - SSS Pass


- - -

Can anyone summarize some rules in which cases the values of Transmission, Scattering and Absorption are bound to be found in which pass when using Diffuse or Specular Materials? :?:

or alternatively:

Can anyone share some other examples of SSS, Refraction and also Transmission passes they created to get a better understanding how they could look if done correctly?
Win 10 Pro 64bit | Rendering: 2 x ASUS GeForce RTX 2080 Ti TURBO | Asus RTX NVLink Bridge 4-Slot | Intel Core i7 5820K | ASUS X99-E WS| 64 GB RAM
FAQ: OctaneRender for DAZ Studio - FAQ link collection
User avatar
linvanchene
Licensed Customer
Licensed Customer
 
Posts: 783
Joined: Mon Mar 25, 2013 10:58 pm
Location: Switzerland

Re: Help understanding Refraction, SSS and Transmission passes?

Postby stratified » Thu Feb 19, 2015 8:12 pm

stratified Thu Feb 19, 2015 8:12 pm
Hi,

I will try my best to explain. Refraction, transmission and SSS are tightly coupled and it's easy to get confused.

Refraction: Applies only for specular materials. In a sense it's like the diffuse transmission but rays go in a pre-defined direction. The rays are refracted at the interface between the 2 materials because the speed of light is different in the materials. For more info refer to Snell's law which gives the relation between the incoming and refracted ray.

refraction.jpg
For refraction, the direction of the ray changes when it enters another material.


Transmission: Applies only for diffuse materials, light rays are refracted according a cosine distribution on the hemisphere. Mathematically this means that the ray can make any direction with the normal between 0 and 90 degrees but smaller angles are more likely (because of the cosine distribution). (NOTE: I initially confused this with opacity but it isn't the same. For opacity the rays go straight through the medium while in the transmission case they are still refracted at the interface). This is the same effect as translucency in nature.

transluscent_leaves.jpg
Translucency like in diffuse transmission.



SSS: Subsurface scattering means that the light ray is scattered under the surface (i.e. in a volume). To put it simple, a light ray travelling in a medium can all of the sudden decide that it doesn't like it's current direction any more and change direction. This is called a scatter event. In Octane you can control the different directions that a ray can scatter via the phase (i.e. can the ray reverse totally backwards or can it only deflect it's direction a bit?). The further a ray travelled in a medium, the more likely it is to scatter. This scatter probability is controlled via the scale pin on the medium. If the medium is thick enough, all the rays will scatter and none go through the medium.

Transmission and refraction are a necessary precondition for scattering. The ray has to enter the medium before it can scatter. If the ray enters the medium, it doesn't necessarily mean it will scatter. Rays that go all the way through are normal transmitted/refracted rays and will go to the corresponding render pass. Rays that where transmitted/refracted at the interface but then scattered in the medium will go to the SSS pass.

In your scene, all the rays are scattered in your sphere because the sphere is too thick or the scattering probability too high. Non of the poor rays makes it to the other side without being scattered and hence you don't see anything in the refraction pass. Try playing with the scale on the scatter node or use thinner geometry that way you should see something in both the SSS and refraction/transmission passes.

I hope this clarifies things?

cheers,
Thomas
User avatar
stratified
OctaneRender Team
OctaneRender Team
 
Posts: 945
Joined: Wed Aug 15, 2012 6:32 am
Location: Auckland, New Zealand

Re: Help understanding Refraction, SSS and Transmission passes?

Postby linvanchene » Thu Feb 19, 2015 10:48 pm

linvanchene Thu Feb 19, 2015 10:48 pm
stratified wrote:
I hope this clarifies things?



Wow! Thank you so much Thomas. Your overview of Refraction, Transmission and SSS made me realize on which points I need to read up on.

I now believe I have a better idea in which pass I will find the results if I change those settings! :D

- - -

In Octane you can control the different directions that a ray can scatter via the phase (i.e. can the ray reverse totally backwards or can it only deflect it's direction a bit?). The further a ray travelled in a medium, the more likely it is to scatter. This scatter probability is controlled via the scale pin on the medium.


This is the part I will have to take another look at.
I experimented once with phase direction settings in a fog volume but then forgot to search for examples in which real life materials which scatter direction is likely to be found. :geek:

- - -

Update / Edit:

In the meantime I updated the shaders used in my experimental portrait project.

Now the different passes look like this:

Izarra v1015 by linvanoak OctaneRender passes 5333x3000 v1003.jpg
Izarra v1015 OctaneRender passes


- - -

In any case I would find it interesting if more people would start to share render passes to get a better understanding how each layer contributes to the final image.

- - -
Last edited by linvanchene on Fri Feb 27, 2015 9:35 pm, edited 1 time in total.
Win 10 Pro 64bit | Rendering: 2 x ASUS GeForce RTX 2080 Ti TURBO | Asus RTX NVLink Bridge 4-Slot | Intel Core i7 5820K | ASUS X99-E WS| 64 GB RAM
FAQ: OctaneRender for DAZ Studio - FAQ link collection
User avatar
linvanchene
Licensed Customer
Licensed Customer
 
Posts: 783
Joined: Mon Mar 25, 2013 10:58 pm
Location: Switzerland

Re: Help understanding Refraction, SSS and Transmission passes?

Postby pegot » Fri Feb 20, 2015 9:59 am

pegot Fri Feb 20, 2015 9:59 am
I too want to thank you also stratified for such a clear and straightforward explanation - your breakdown of these properties and how they relate to Octane was tremendously helpful.

Render Layers, In addition to their flexibility to assist with compositing, also make for a great learning tool!
Win 10
3.7Ghz i9 10900k / 64GB
ASUS STRIX Z490-E
PSU: PowerSpec 850Wd
RTX 3090 Asus Tuff

Network rendering:
Win 10
4.2Ghz i7 7700k / 64GB
AsRock SuperCarrier
PSU: EVGA 1200w
RTX 3080 Ti EVGA Hybrid
RTX 3080 ASUS Tuff
GTX 1080ti SC Black (wc)
pegot
Licensed Customer
Licensed Customer
 
Posts: 921
Joined: Mon Nov 07, 2011 3:44 am

Re: Help understanding Refraction, SSS and Transmission passes?

Postby garytyler » Tue Feb 24, 2015 8:56 am

garytyler Tue Feb 24, 2015 8:56 am
just love it when an inquiry gets that kind of response. bravo.
Win 8.1 / C4D R16 / Maya '16 / 5x GTX 980 Ti
garytyler
Licensed Customer
Licensed Customer
 
Posts: 234
Joined: Mon Nov 10, 2014 7:40 am
Location: Portland, OR

Return to General Discussion


Who is online

Users browsing this forum: No registered users and 15 guests

Tue Mar 19, 2024 5:26 am [ UTC ]