Chaos Corona 8 – Corona Decal

CORONA CHAOS AND THE CORONA DECAL OBJECT

Table of contents

Corona DECAL - INTRODUCTION

The Corona Decal object (CDecal) allows you to project a texture on an object without the target mesh needing valid UV mapping coordinates. The Corona Decal projected texture is loaded into an adjustable “cuboid” (gizmo), which controls the decal size and projection limits.
Open the CoronaDecal.max and start the Corona Interactive Rendering (Fig. 01).
Fig. 01 - CoronaDecal.max. Corona Decal is textured using a CoronaPhysicalMtl with two textures in the "Base color" and "Opacity" channel.
Corona Decal is displayed as a simple box, with the top face textured by the decal that is project on the receiving geometries (targets). Click on the Corona Decal icon in the Corona 8 toolbar, or go to Create TAB → Geometry → Corona → CDecal (orange arrows) to create a Corona Decal object. Pressing the CTRL key while dragging the mouse will start the creation from the geometric center of the Corona Decal object.
The pivot of the gizmo is 30cm from the top face of Corona Decal (when the total height is 100cm) because Pivot offset is set to 0.3 by default (on a scale of 0 to 1). This setting makes selecting the Corona Decal object in the viewport easier by avoiding overlap with the target objects (in this case, Floor). Think the Corona Decal gizmo in a three-dimensional way, where the decal is projected on all intersecting geometries. According to this principle, both Floor and Teapot (purple arrows) were textured with the yellow graffiti.
Now disable the CDecal_Start layer and enable CDecal_Samples: click Render. For a complete understanding of Corona Decal we need to analyse both the render (Fig. 02) and the orthogonal views (Fig. 03).
Fig. 02 - Render of the CDecal_Samples layer objects.
Fig. 03 - Screenshot of the viewport when the CDecal_Samples layer is enabled. Note: the word VICTOR appears in front of the yellow graffiti, but this is a 3ds Max display issue.
We start with the cyan Corona Decal (vertically oriented), with part of its volume above the wall. Since half of the Corona Decal intersects the wall, the graffiti letter M is projected about 50cm on the top of the target object (cyan arrow). Let’s continue with the yellow and magenta Corona Decal objects. These two objects are also vertical, with the yellow graffiti covering the word VICTOR. In the render, the letter R is not visible: the geometric position of the gizmo defines who overlaps what.
The next example shows the sum of the two previous systems. The blue decal is placed under the red gizmo, with the latter penetrating the barrels (red arrow in Fig. 03): the red decal colors the green cylinder for a few centimetres from the base (green arrows in Fig. 02).
Looking at the scene closely, the yellow Corona Decal is deeper than the wall. We generate a new render, using the Corona_Camera_Back camera: the graffiti is projected on the back side of the wall.
Corona Renderer: THE COMPLETE GUIDE

Corona DECAL - PARAMETERS

For the next parameters, disable the CDecal_Samples layer and enable CDecal. A vertical Corona Decal appears, with a CoronaPhysicalMtl applied. We loaded two maps: one for the Base color channel and one for the Opacity and Displacement channels.  
On – enables or disables the texture projection of the Corona Decal object during rendering (Fig. 04).
Fig. 04 - Corona Decal display management in viewport.
>> place the mouse on the image to stop the animation <<
0 object exluded… – press this button to display the 3ds Max Exclude/Include window. We can now define which objects Corona Decal uses as a target objects by selecting the geometries in the left window and clicking the right double arrow “>>” button . We can also add an object in the list by selecting it in the viewport and clicking on the “+” button, without opening the Exclude/Include window. When we right‑click on the “+” icon, three actions can be performed: delete all objects in the list, select the objects in the list, or add the selected objects to the list (Fig. 05).
Fig. 05 - Display the menu using the right mouse button.
From material – selects this option when an opacity map is available in shader applied to Corona Decal (a black and white map in CoronaPhysicalMtl in this example). Corona Decal is transparent where the opacity color is black.
Map – applies a different opacity map than the material assigned to the Corona Decal object (Fig. 06).
Fig. 06 - Mask generated with the "Map" option.
Replace base displacement – when the target object has the displacement effect enabled (the wall in this case), turning on Replace base displacement will replace this effect with the displacement of the shader assigned to Corona Decal. Vice versa, the Corona Decal displacement will be added to the displacement of the target object (Fig. 07).
Fig. 07 - Management of the displacement effect in the Corona Decal object.
>> place the mouse on the image to stop the animation <<
3D bricks of the target Wall object are generated with Displacement through shader. The material of CDecal_Graffiti also has a map in the Displacement channel. When Replace base displacement is disabled, the displacement effect of the Corona Decal material is added to the target shader. As a result, both displacements are visible. On the contrary, only the displacement of the Corona Decal will be taken into account.
Replace base bump – when the target object has the bump effect enabled (the wall in this case), turning on Replace base bump will replace this effect with the bump of the shader assigned to Corona Decal. Vice versa, the Corona Decal displacement will be added to the bump of the target object.
WidthCorona Decal width (Fig. 08).
Fig. 08 - "Width" parameter.
HeightCorona Decal height (Fig. 09).
Fig. 09 - "Height" parameter. Since Corona Decal is placed about 10 cm from the wall (orange arrow), the decal texture also affects the floor when the gizmo intersects the ground. To fix this problem, use the "object Excluded..." button to exclude the floor from the decal projection.
Fit to Bitmap… – click this button to select a texture that defines the width/height ratio the gizmo of Corona Decal.
Fit to assigned mtl – the width/height ratio of the Corona Decal object is be defined by the texture loaded into the assigned material.
Depth limit – defines the depth of the Corona Decal object. Any object beyond this limit will not be affected by the decal.
Select the Corona_Camera_Front camera and set Zoom factor=1.5, move the Corona Decal object from 380 cm to 230 cm on the Y axis, and generate four renders using Depth limit= 5, 60, 130 and 170 cm (Fig. 10).
Fig. 10 - Changing the depth of the Corona Decal object.
In the first test in Fig. 10, since the gizmo of the Corona Decal object does not intersect any geometry, the graffiti does not appear on any mesh. When Depth limit= 60 cm, the decal is projected on the first barrel (green arrows). With Depth limit= 130 cm, all barrels are textured (magenta arrows). Finally, the texture also appears on the wall when Depth limit= 170 cm.
>> place the mouse on the image to stop the animation <<
Max angle limit – limits the projection angle of the decal. 90deg means that the Corona Decal texture appears only on the front faces of the target objects, while the texture is also visible on the back faces when the angle Max angle limit= 180deg. With 1deg (minimum value), the decal is visible only on the faces parallel to the Corona Decal gizmo.
Let’s continue from the last settings in Fig. 10. To better display the effect of the Max angle limit parameter, disable the Base color texture of the barrels. ( Fig. 11).
Fig. 11 - The decal appears on the curved surfaces of the barrels as the "Max angle limit" parameter increases.
>> place the mouse on the image to stop the animation <<
Max angle blur – defines the amount of blur near the edges of the decal when Max angle limit is used (Fig. 12).
Fig. 12 - The higher the "Max angle blur" parameter, the blurrier the projected texture.
>> place the mouse on the image to block the animation <<
Show material preview – manages the viewport display of the Corona Decal texture (Fig. 13).
Fig. 13 - Corona Decal supports the opacity channel in viewport.
Pivot offset – modifies the position of the gizmo, leaving the position of the pivot unchanged. Minimum value= 0.0, maximum value= 1.0, default value= 0.3 (Fig. 14).
Fig. 14 - "Pivot offset" moves the gizmo of Corona Decal.
>> place the mouse on the image to stop the animation <<
We end the chapter on Corona Decal with a comparison of two renders (Fig. 15). In the first image I used two Corona Decal objects and the white Wall material for the wall. In the second image I disabled the CDecals layer and applied the WALL_Composite_Version material to the wall, enabling the UVW Map_Graffiti and UVW Map_Dirt modifiers. For an in-depth study on this shader, read the CoronaMix map chapter (page 625 of Corona: THE COMPLETE GUIDE). The renders are very similar, but the complex setup of the WALL_Composite_Version material, the need for two extra UWV modifiers, the changes of Map Channels at shader and geometric levels, and the lack of flexibility of this map‑based system, make Corona Decal a fast, reliable, and extremely effective tool.
Fig. 15 - Renders made using the Corona Decal object and the 3ds Max Composite map.

THANK YOU!

A heartfelt thanks to all the new friends and students who believed in my project! I wish you hours and hours of pleasant study and reading.
Francesco Legrenzi
Engineer, author, and 3D artist
Corona Renderer: THE COMPLETE GUIDE

Leave a Reply