- [Instructor] When we place a map
in the 3ds Max scene environment
that is going to provide a backdrop or background
and also illuminate the scene.
There are a lot of situations
in which we want to separate those two things.
In this case, we're going to separate the background
from the environment merely
to color correct the background or backdrop,
because it's looking a bit too dark here for me.
So in this active shade rendering,
we are seeing the default output of our HDRI image.
Let's make a clone of this active shade window
so we can compare it to a later version
and I'll take that and minimize it.
So let's open up the Material Editor
and we're going to build a very simple shading network.
That's going to allow us to separate the background
from the environment.
So open up the Material Editor
and here's what we have so far.
We've just got the environment map.
We're going to change the name of this
just to make this a little bit more clear.
We're going to call this env file
because it's not going to be what's mapping the environment.
We're going to actually pipe this through another node.
So I'm just name this env file for clarity.
The node that we want is an Environment/Background Switcher
and we'll find it over here on the left side
of the Material Editor, we have the Material Map Browser
and we're looking for the Maps category.
We can collapse the Materials category
and under Maps, OSL, Environment,
we'll see Environment/Background Switcher.
We're going to place this into our graph or view here,
just drag and drop that over into the graph.
And we've just created this new node
and let's rename it as well.
We'll call it env bg switch.
Now this is going to be
what's applied to our scene environment.
So let's open up the environment dialogue,
Rendering, Environment
and we want to instance this new switcher node
into the environment map and to do that, we'll want to click
and hold on the output port in the lower right
of that switcher note.
Click and hold on that output port
and you get a wire when you drag and just drag that wire
over to the other window and release your mouse.
We get the Instance copy dialogue.
Once again, we want to instance so
that any changes we make here will be reflected
in the environment map.
So leave it at Instance and click OK.
Once that's done in both our Viewport and our ActiveShade,
we can see we've got a very strange result
and we're getting this solid green environment lighting
and a solid red background.
And those of course are coming
from these color swatches here in the OSL Map Parameters.
All we need to do is wire up
our HDR env file to the environment.
And that's done by simply connecting the output
of the env file to the environment input.
So click and drag on that output port
and drag over to the environment input.
And now we've got half of it.
We've got the same lighting that we had previously.
Our lighting is coming from the env file.
Our background is still this solid red background.
I could substitute a different background here if I wanted
but really all I want to do is color correct the background
that I have to brighten it up.
For that purpose,
there's an OSL map called ColorCorrection.
And here it is, OSL, ColorCorrection.
Drag that over into the graph.
And with that selected, let's rename it as well.
We'll call it bd color correct.
And we're going to wire this up.
We want to take the output of this file
and plug it into the input of our color correct node.
So we're branching this output,
one copy is going to go into the environment.
Another copy is going to go into this color correct input.
Then we'll take the color correct output
and plug that into the scene background.
Once we do that, now we have made the connections.
If we look at our active shade,
we'll see that it's not going to look quite right
just as we saw in the previous movie,
the values are being clamped by this OSL node.
So we want to go into the parameters
for the color correct nodes.
So select it, scroll down in its parameters
and at the bottom, you'll see Clamp Result,
just disable that.
Once you've disabled Clamp Result, then as long
as we haven't changed any of these other default parameters
we're just passing the HDRI data through this node,
and we're not actually making any changes.
But now we're ready to art direct this.
We have the brightness and it's enabled by default.
And within that Brightness section,
we have a Brightness parameter.
Let's bring that up from its default of one to value of two.
And now our background is twice as right as it was.
Bring it up to a value of three,
and it's three times as bright.
This is a linear parameter.
It doesn't work in powers of two, like an exposure value.
So with a brightness value of four,
we quadrupled the intensity of that map.
And we can also maybe increase the saturation a little bit.
Down here we've got the Color section.
We can enable that Color section
and just bump up the saturation.
We'll set that to a value of 1.1
and we've just increased the saturation
of our sky a little bit, made it a bit more blue.
So that looks pretty good, I think.
If we look in the Viewport, however we'll see
that our background is overexposed.
And if that bothers us, then we can just go back
to our HDRI environment node labeled env file.
And in its OSL Map Parameters under Appearance,
we have the Viewport brightness.
We can bring that down to 0.04
and press Enter.
And now our Viewport is
in the same brightness range as our rendering.
All right, we've made the changes.
We can close the Material Editor.
We can close the Environment and Effects dialogue.
I've got my previous rendering minimize.
We can bring that back and compare the two.
On the left, we have the version
where we've color corrected just the background
and on the right we have a version with no color correction.
It's how to separate the scene environment
into its background
and its environment or lighting components.