Академический Документы
Профессиональный Документы
Культура Документы
Shadow Channel
One of the features of Thea Render v1.4 is the availability of a variety of new Render Channels
supported by Presto engines. One of these channels is the Shadow Channel, supported by both
Presto (AO) and Presto (MC). This separate pass for the scene shadows allows faster and better
post processing resulting in a variety of final outcomes.
An example of what can be produced is seen in Figure 2, where with the use of the Shadow
Channel (as seen in Figure 1) we managed to isolate from our scene the model with its shadows Figure 1: Shadow Channel
and add it later on different backgrounds, reserving all shadow information.
Tutorial Contents
At this small tutorial we will see the way we can generate this Channel from inside Thea Studio
and Integrated plugins:
• 3dsMax
• Cinema4D
• SketchUp
At the final part of the tutorial we will give the basic steps one needs to follow in post process- Figure 2: Plane with shadows - after post process
ing (with the use of an image editor software) to isolate the desired models and their shadows
and generate the final images.
Note: at the final step of post-processing, we will also need a way to isolate our models and their shadows. For this, we will need to
use the Mask Channel. So on parallel with Shadow Channel we will show how the Mask Channel can be generated and used.
Mask Channel allow us to index the models/groups we want (by assigning a Mask Index to them) and in this way produce the need-
ed black/white masks of the selected models.
1
SHADOW CHANNEL
Physically-based GPU+CPU Render
General Note: At the following paragraphs we will examine how we can enable the Mask Index
for the selected model and how we can generate the Shadow and Mask Channels. For all cases,
we suppose we have the same scene and goal:
• We will start from a scene with some models laid on a floor.
• We will then produce the Color, Mask and Shadow Channels.
• Finally, we will combine these three images at post processing to produce the final image,
our models and their shadows.
Figure 3: Some models laid on a floor
• Assign at first a Mask Index to the item you need to use as Mask (floor to our example). For
doing this you can use both native 3dsMax tags: Object ID and Material ID. In case you select
both, note that Material ID has a higher priority (so you can set a sub-material ID inside a ob-
ject that already has an ID applied).
• Then, before rendering, select as render engine cores Presto (AO) or Presto (MC) and enable
the Shadow/Mask Channels (see Figure 4). These Channels can be found at the Render Ele-
ments tab of the Render Setup window.
2
SHADOW CHANNEL
Physically-based GPU+CPU Render
Figure 7: Select and see Shadow/ Figure 8: Select and see Shadow/Mask Channels at Figure 6: Enable Shadow Channel at Render
Mask Channels at Thea Darkroom Picture Viewer Settings
3
SHADOW CHANNEL
Physically-based GPU+CPU Render
4
SHADOW CHANNEL
Physically-based GPU+CPU Render
• Select the floor model and then at the Properties Panel increase the Mask Index from the de-
fault 0 (that means no Indexing) to number 1, as seen in Figure 12.
• Then, and before rendering, go to the Settings Panel and enable the Production mode (either by
double clicking on the Interactive tab or by going to the Darkroom).
• Go to the General tab and select as Engine Core Presto (AO) or Presto (MC).
• Switch to the Channels tab and enable both Mask and Shadow Channels (see Figure 13).
• Once the rendering starts you will be able to find the Shadow/Mask Channels listed at the Chan- Figure 12: Enabling Mask Index for the
nels drop-down menu, at the Darkroom (see Figure 14). floor
• With the Save button you are able to save the Color, Mask and Shadow Channels at the desired
format (png for example).
In case of an animation, the rendered images and their channels will be added directly to the spec-
ified output folder.
Figure 14: Find Mask and Shadow Channels at the Darkroom Figure 13: Select Both Mask and Shadow
Channels
5
SHADOW CHANNEL
Physically-based GPU+CPU Render
Figure 15: Initial Scene (Studio Viewport) Figure 16: Color Channel Figure 17: Mask Channel Figure 18: Shadow Channel
As we have created now the above channels we can use an image editing software, like Gimp or
Adobe Photoshop in order to make the needed modifications to our Channels and produce the re-
sults we want. In our example we will use Photoshop. We import all the channels (Color, Mask and
Shadow) in Photoshop and then we follow the next basic steps.
Step 1: The first we will need to do is to isolate the models we need from the rest ones with the
use of the Mask channel (remove the floor in our example).
We select the Mask channel and we copy it. We go at the Color channel layer, and from the menu
on top we select Layer > New Layer Mask > Reveal All (Figure 19).
We paste then (paste in place) the copied Mask channel to the new mask layer and then we invert Figure 19: Add New Layer Mask
it. This is how the Color layer with the applied Mask should look like now:
In Figure 20 we see that the background has been removed now from the Color Channel.
6
SHADOW CHANNEL
Physically-based GPU+CPU Render
Step 2: The mask channel will be used once again at this step in order to isolate the needed shad-
ows. These are the contact shadows, created by the models onto the floor.
We select the Mask channel and we copy it. We go then to the Shadow channel layer, and once
again from the top menu we go at Layer > New Layer Mask > Reveal All (Figure 19).
We paste in place then the Mask channel to the new mask layer (no need to invert it this time). Figure 21: Mask applied to the Shadow
This is how the layer should look like now: Channel
We see the results on the Shadow Channel in Figure 21. As you see the only problem we still need
to handle is the white color appearing at the background.
What we need to do now is to remove totally these white parts and keep the shadows only in a
transparent background.
For doing this we go the Blending Options of the layer (Figure 22) and at the Blend If Grey panel,
at first bar (This Layer), with Alt+Click we drag the right cursor half-left part at the left side as we
see in Figure 22. Figure 22: Blending Options
In this way we manage to remove the white background and our results are seen in Figure 23.
7
SHADOW CHANNEL
Physically-based GPU+CPU Render
Step 3: The final step is to combine the Models with their Shadows.
For doing this, we simply need to copy the layer with the Shadows as we created at the
previous step, Step 2. We need to copy it merged. Then paste it (paste in place) as a
new layer below the Color layer.
This is the way our layers should like now:
The resulted image is seen in Figure 24. Figure 24: Models with their Shadows
Then you can add any other background to a layer below the Shadow layer. This is the
way our layers should like now:
At the Blending options of the Shadow layer select the Multiply option, and see your
rendered models and images at a new background (as seen in Figure 25 and Figure 26).
Tip 1: In case any “gaps” exist between the models and the Figure 25: Models with Shadows in a new background - 1 -
shadows you can select the Shadow layer, go to Filter > Other
> Minimum and change Radius value to 1-2. This will give you
a smooth result.
Figure 27: Minimum Filter Figure 26: Models with Shadows in a new background - 2 -
8
SHADOW CHANNEL
Physically-based GPU+CPU Render
What if one needs to use this image at a website for example? We will need to export the im-
age with the shadows only (and transparent background).
Figure 28: Load Selection Window
With the method we stated above, by hiding the background layer and saving the resulted im-
age in png format, some white parts will be still left on the shadows area, as the Multiply Blend
is ignored.
For totally removing these white parts, some additional steps are needed:
• At the layer with the Shadow, as it has been already generated from the previous steps you
need to use the option from the top menu Select > Load Selection (enable the invert option
at the dialogue box) as seen in Figure 28. Then go to Edit > Cut and cut the selected part.
• Afterwards, at top menu again go to Image > Adjustments > Levels and remove totally the
white color (see Figure 29).
The above steps will let you have a white-free shadow to use it at websites or a leaflet with any
Figure 29: Levels Window
background color. You can see such an example in the next image, where some parts are over
our document grey coloured background box, some others on white but still their shadows are
correctly applied.