Using Physical Sun and Sky with HDR reflections
In Flying car I wanted to make good aerial shot with bright sun and nice HDR reflections of clouds on my vehicle. So I needed to combine Physical Sun and Sky with IBL lighting
If you try to turn on both ‘Image based lighting’ and ‘Physical sun and sky’ – you won’t get nice result, because IBL shape blocks Final Gather rays from your sky. We need to create shader that will be seen in reflections and let Final Gather rays pass through it.
Lets have a look at my initial render.
It looks not so bad for beginning, but let’s improve it.
First – create sphere and reverse it’s normals. Also don’t forget to switch Backface Culling on.
Set Render Stats for sphere. We don’t need to Catch Shadows, Receive shadows and Double Sided. You can also switch-off Primary Visibility.
Assign new Lambert material for sphere. Actually it can be any material, we need only it’s shading group. Open Hypershade, select Lambert, we just created, and press Graph>Input and output connections.
And now lets start to build our shading network. First we need to create mip_rayswitch node.
mip_rayswitch is a mental ray production node that allows to use different shaders accordingly to type of rays.
To add this node execute MEL command:
createNode mip_ rayswitch;
New node will appear in Hypergraph work area.
Double click on lambert Shading group to open it in Attribute editor. Connect mip_ rayswitch to Material Shader.
To do that with MMB drag mip_ rayswitch node from Hypershade into Shading Group opened in Attribute Editor.
Let’s have a look at mip_rayswitch.
It has different fields for every type of rays.
We will need Eye, Reflection and Finalgather. Eye and Reflection will be used for texture. Also we need to make sphere surface to pass Final Gather rays through it. Mental ray has mib_continue shader for this case.
mib_continue – is a simple shader that takes incoming rays and continue them through surface.
To create mib_continue type MEL command:
createNode mib_continue;
Connect it to mip_rayswitch Finalgather input.
Now create File texture and select image. Connect File to mip_rayswitch Eye and Reflection inputs.
Quick render.
We got some reflections, but they are too dark. I think multiply node will help.
Add multiplyDivide node between file node and mip_rayswitch:
I tried few multiply factor and saw 6.0 is pretty good.
Now I’ll open it in Photoshop and add some clouds.













0 Comments