What is the Corona Volume Grid object?
The Corona Volume Grid allows you to render objects that are truly volumetric and based on a 3D grid instead of meshes using the Corona Volume Mtl, which always require some kind of surface consisting of polygons to display the volume.
The typical uses of the Corona Volume Grid include:
- Fire
- Explosions
- Smoke
- Clouds
- Steam
- Objects which are not possible or difficult to render when using classic polygonal meshes
In addition to the below content, see also: Corona Volume Grid at the Chaos Documentation Portal
Where to find it?
The Corona Volume Grid can be created by going to the Corona menu > Corona Volume Grid:
What formats are supported?
Only the OpenVDB (.vdb) format is supported. You can learn more about it at http://www.openvdb.org/, and you can download sample .vdb files at http://www.openvdb.org/download/
The Corona Volume Grid also supports animated OpenVDB files (.vdb sequences) as well as Cinema 4D's Pyro fire and smoke simulation tool which was introduced in their 2023 release.
Using Pyro could not be easier. Once you have run your Pyro simulation you can then link it to the Corona Volume Grid object using the eyedropper found in the Objects tab. If the simulation has not been cached already you will receive a prompt asking how you would like to store the cache. There are two options for this. Cache scene and Cache:
Cache scene:
This will prompt you to store all Pyro output objects that are used in a scene to disk in a location chosen by the user.
Note: Exported simulations can take up a lot of HDD storage space so it is worth keeping an eye on the capacity of your HDD.
Cache:
This option allows you to cache a single Pyro output object from a scene.
Once either method has been completed, it is automatically linked to the Corona Volume object and rendering can begin.
For more information about Pyro, please see MAXON's user guide here.
What are the available controls?
Most useful controls include:
Object
The Object options control how the Volume Grid object will be displayed at the viewport and show information from the simulation like the number of cells and density of the grid:
Object - Select files
Use this button to select the VDB file that will be used. In the case of an animated sequence, only select one of the files from the sequence, and the entire animation will be automatically loaded.,
Object - Reload from disk
Use this button to make the Corona Volume Grid object reload the file/sequence from your disk.
Object - Animation - Enable animation
This option will enable/disable the reading of the VDB animated sequence.
Object - Animation - Mode
Use these options to set the animation mode for the VDB animated sequence. You can use any of the following available options:
- Repeat - The VDB animation will playback like a loop.
- Ping Pong - Using this option, the VDB animation will play forward, and once it reaches the end, it will continue playing the animation but as if it was going backward.
- Freeze out of range - When selecting this option, once the VDB animation reaches the end, it will freeze using the last frame.
- Hide out of Range - When selecting this option, once the VDB animation reaches the end, it will hide after the last frame.
Object - Animation - Frame offset
Use this option to offset the VDB animation starting time (you can use either positive or negative values).
Object - Animation - Speed multiplier
Using this option will speed up or slow down the VDB animation playback.
Object - Animation - Load nearest if missing
When using this option, if a file from the VDB animation sequence is missing, it will try loading the nearest available file to continue playing. E.g., If there is a VDB animation sequence consisting of 10 frames and the 4th frame is missing, this option will read the 5th frame as it was the 4th frame, and then it will read the 5th frame as usual.
Object - Viewport display - Type
Use bounding box or point cloud viewport preview for the OpenVDB file.
Warning: the point cloud preview can be slow when a large file is loaded!
Viewport display type = Bounding Box | Viewport display type = Point Cloud |
Object - Viewport display - Quality
This option will control the density of the point cloud preview.
Warning: The point cloud preview can be slow when a large file is loaded, and the quality percentage is increased (for most cases it is suggested to keep it under 25%).,
Viewport display quality = 5% | Viewport display quality = 100% |
Rendering
The Rendering options control how the volume grid object will be processed to display it accurately or not.
Rendering - Interpolation
This option lets you decide about the speed to quality ratio. It is similar to filtering used in many applications when dealing with 2D textures.
- "None" - This option will give the fastest rendering but the lowest quality with a possibility of the "pixelated" or "blocky" appearance of the grid.
- "Linear" - This option is a compromise between quality and render speed, and this mode is used by default.
- "Quadratic" - This option will produce the best quality but at the cost of render time.
Rendering Interpolation = None | Rendering Interpolation = Linear |
Rendering - Step size
Ray marching step size. Decides how many "volumetric steps" can be used to render the object. Higher values mean faster rendering, more noise, and a higher possibility of artifacts showing up. Lower values mean better quality but slower rendering. To get reasonable render times, the step size value should be set to as high as possible until ray marching artifacts are visible ("slices" visible inside the object).
Render Interpolation = Linear Step Size = 0.1 |
Render Interpolation = Linear Step Size = 10 |
Rendering - Flip frame
Flips the OpenVDB file's Y and Z axes, which results in the object being rotated by 90 degrees. This option should be used if the object appears to be incorrectly rotated when loaded.
Flip Frame = Disabled | Flip Frame = Enabled |
Rendering - Motion blur & Frame interpolation
Decides how motion blur is computed.
Rendering - Mode
- Disabled - disables motion blur.
- Simple - simple interpolation between two OpenVDB frames - may lead to artifacts.
- Velocity-based - smooth interpolation based on the velocity channel of the OpenVDB file - requires selecting the correct velocity channel.
Rendering - Velocity
Selects the channel which stores velocity information for the motion blur calculations. Usually, "velocity" should be used for this.
- Multiplier - Strength of the motion blur effect (higher values mean more pronounced motion blur).
Emission
Toggles the emission for the volume. This can be seen as the temperature of the tiny smoke particles. The higher the temperature - the brighter the particles glow.
Emission Disabled Absorption Enabled Scattering Enabled |
Emission Enabled Absorption Enabled Scattering Enabled |
Emission - Channel
Selects the channel (grid) present in the OpenVDB file that will be used for medium emission. Usually, it should be set to "temperature" to get results such as fire or explosion.
There is also an additional channel called "constant" - it is a single solid color, which is applied to the whole bounding box of the volume. In the case of using the "constant" mode for the emission, the entire bounding box of the volume grid object will start glowing.
The "Constant" channel is useful, for example, for scattering light when creating smoke - you can set constant scattering color to have the same type of scattering inside the whole medium. Then its thickness will be controlled only by the absorption properties.
Emission channel set to "Temperature" | Emission channel set to "Constant" |
Emission - Scale
It makes the overall emission more or less intensive (higher values mean higher intensity).
Emission scale set to 1 | Emission scale set to 0.1 |
Emission - Tint
This color is applied to the emission (you can see it as a kind of filter).
Emission tint color: White | Emission tint color: Blue (H=228, S=100, V=100) |
Emission - Map
This is the mask used for emission. Note that the mask is applied in 3D space, so adding a noise map will result in having a 3D noise mask applied to the object. The use of "Texture" or "UV(2D)" space mode is not supported.
Noise map set to work in Object Space | Noise map set to work in Texture or UV(2D) Space (not supported) |
Emission - Mode
It defines how the data from the currently selected channel is interpreted:
- Raw data - uses the original color and intensity, which is stored in the VDB file. It is then affected by scale and tint parameters.
-
Channel mapping - uses custom settings from the "Channel color mapping" tool.
Please scroll down to the "How to use channel color mapping" section below to learn more about it. - Blackbody - simulates color emission of a blackbody at a given Kelvin temperature (useful for fire simulations).
Absorption
Decides how far light can travel inside the object before it is fully consumed. For better results, enable the Scattering property.
Absorption - Channel
Selects the channel (grid) present in the OpenVDB file that will be used for absorption. Usually, it should be set to "smoke" or "density" (it will depend on how this channel has been named when creating the simulation) to get results such as fire or explosion. There is also an additional channel called "constant", which fills the whole bounding box of the volume grid.
Channel used: "Constant" | Channel used: usually "Smoke" or "Density" |
Absorption - Scale
It makes the object absorbs the light faster or slower (higher values mean faster absorption meaning darker overall color, thicker smoke)
Emission = Disabled Absorption Scale = 0.5 |
Emission = Disabled Absorption Scale =5 |
Absorption - Tint
This color is applied to the absorption (you can see it as a kind of filter).
Emission = Disabled Absorption tint = White (default) Scattering = Enabled |
Emission = Disabled Absorption tint = Blue (H=200, S=100, V=100) Scattering = Enabled |
Absorption - Map (Shader)
This is the mask used for absorption. Note that the mask is applied in 3D space, so adding a noise map will result in having a 3D noise mask applied to the object. The use of "Texture" or "UV(2D)" space mode is not supported.
Absorption Shader = Noise working in Object space. | Absorption Shader = Noise working in Texture or UV(2D) space. (Not supported) |
Absorption - Enable Channel color mapping
Uses custom settings from the "Channel color mapping" tool. Please scroll down to the "How to use channel color mapping" section below to learn more about it.
Scattering
Decides how light is scattered inside the volume.
Scattering - Channel
Selects the channel (grid) present in the OpenVDB file that will be used for scattering. Usually, it should be set to "constant" to have the whole medium scatter light in the same way in the areas where absorption allows this, but other channels may work fine too, depending on the needs.
Emission = Disabled Absorption = Enabled Scattering = Disabled Scattering Channel = Constant |
Emission = Disabled Absorption = Enabled Scattering = Enabled Scattering Channel = Constant |
Scattering - Scale
Make the object scatter light more or less (higher values mean more scattering and brighter overall color).
Emission = Disabled Absorption = Enabled Scattering Scale = 0.1 |
Emission = Disabled Absorption = Enabled Scattering Scale = 1 |
Scattering - Tint
This color is applied to the scattering (you can see it as a kind of filter).
Emission = Disabled Absorption = Enabled Scattering Tint = White (default) |
Emission = Disabled Absorption = Enabled Scattering Tint = Blue (H=200, S=70, V=100) |
Scattering - Map (Shader)
This is the mask used for absorption. Note that the mask is applied in 3D space, so adding a noise map will result in having a 3D noise mask applied to the object.
Scattering Shader = Noise working in Object space. | Scattering Shader = Noise working in Texture or UV(2D) space. (Not supported) |
Scattering - Directionality
This is used to adjust the directionality of the scattering. A value of 0 (zero) produces isotropic ("diffuse") scattering. Positive values produce forward scattering. Meanwhile, negative values will produce backward scattering. The default value of 0 is suitable for most media, except for clouds, where higher positive numbers will produce the effect of "silver lining"
Emission = Disabled Absorption = Enabled Scattering Scale = 1 Scattering Directionality = -0.7 |
Emission = Disabled Absorption = Enabled Scattering Scale = 1 Scattering Directionality = 0.7 |
Scattering - Single bounce only
This option should be enabled unless disabling it is absolutely necessary. When enabled, only a single bounce (direct lighting) will be scattered in the medium. This results in a biased (darker) but much faster rendering.
Useful, e.g., for rendering "god rays" inside the medium.
Single bounce only = Enabled. | Single bounce only = Disabled. |
Scattering - Enable Channel color mapping
Uses custom settings from the "Channel color mapping" tool. Please scroll down to the "How to use channel color mapping" section below to learn more about it.
Examples
Example 1 We want to achieve dark, thick smoke, which does not emit or scatter light:
|
|
Example 2 We want to achieve intensive fire with dark, thin smoke, which does scatter some light:
|
|
Example 3 We want to achieve steam:
|
|
Example 4 We want to achieve "magic" fire with colorful smoke:
|
How to use the Channel Color Mapping tool?
The channel color mapping can be used to color the properties of the volume grid (emission, absorption, scattering) based on a gradient. For example, a red-yellow gradient can be used to create fire.
The channel mapping tool allows for mapping floating point values stored in the channel to colors. The mapping is computed as follows:
- First, the floating values are scaled by the "Input scale" to fit into [0,1]. You can use the "Auto-scale" button to compute the input scaling value automatically.
- Float value is mapped to color using the color gradient. The leftmost color of the gradient defines how the value of 0 is mapped to color, while the rightmost color defines how the value of 1 is mapped to color.
- The curve scales the color computed from the gradient. Note that the curve input is not the color from the gradient but the "input-scaled" floating value from the channel (e.g., the result of operation stated in point A). ,
- The final color is computed by scaling the color back using the inverse of "Input scaling".
Suggested workflow (based on emission):
- Place a Corona Volume Grid object and load your VDB file in the Object tab.
- Set the emission enabled and set the channel to temperature.
- Set the emission mode to "Channel mapping".
- Open the "Channel color mapping" rollout.
- Press the "Auto-scale" button to adjust the scaling value automatically.
- Set the desired gradient colors:
- The left most color represents the color of the darkest features of the volumetric effect.
(in case of using the temperature channel, this means the lowest temperature, so all areas outside of the visible fire) - The right-most color represents the color of the brightest features of the volumetric effect.
(in case of using the temperature channel, this means the highest temperature) - All values in-between represent the transition between the extreme intensities (left and rightmost)
- You can add a new color by clicking right under the gradient bar, and you can remove any color by drag & drop the desired color out of the gradient area.
- The left most color represents the color of the darkest features of the volumetric effect.
- At this point, you can adjust the curve to your needs:
Moving the bottom-left point towards the top of the graph will make the darkest colors more intensive. Moving the bottom-left point towards the right side of the graph will "cut off" some of the darkest colors, making them transparent.
Note: this is useful for getting rid of the shape of the volume grid's bounding box being visible in the rendering.Moving the top-right point towards the bottom of the graph will make the whole effect less intensive. Moving the top-right point towards the left side of the graph will make the whole effect more intensive (note that this can often make the effect appear burnt out). You can also add points in other places of the curve to control the in-between values, and you can switch between "Spline", "Cubic" and "Linear" point types. - To add a new point to the curve, simply hold down the Control key on your keyboard while you left-click on any part of the curve.
- To delete any added point, just select the point you want to remove and hit the delete key on your keyboard.
- To change any point type from linear, click on the arrow on the upper left corner of the graph, and go to the "Interpolation" list to choose the point type that you're looking for.
(click on the image to enlarge)
At this point, adjusting the "Input scaling" value will make the overall effect more or less intensive.
- If you adjust the Emission scale parameter, it will work similarly to the "Input scaling" inside the channel color mapping tool but will adjust the intensity of the effect after the overall color and visibility have been set up (e.g., making fire brighter).
How to get the fastest rendering and the best quality?
Here are some guidelines for setting up the Corona Volume Grid object for the best render time/quality ratio:
- If you are rendering only the Volume Grid object against a solid background (without any surrounding environment such as interior or exterior), go to the Render Settings > Corona > Performance and lower the GI vs. AA from the default 16 to a lower value (such as 4, but not lower than 2). This will render the Volume Grid object faster but may introduce noise in other parts of the image, such as glossy reflections or refractions.
- Since some parts of the Volume Grid may rely mostly on direct lighting (this is visible when absorption and scattering are used), it may make sense to increase the Light Samples Multiplier value located at the Render Settings > Corona > Performance. This will improve the quality of the light penetrating the light-scattering part of the object (such as smoke, steam, etc.).
- In the Corona Volume Grid Object's settings, go to the Rendering tab and set the Step size to the highest value possible. Too low values will render extremely slowly. Too high values will reveal ray marching artifacts ("slices" or "cubes" visible in the object) and will make the object appear unrealistically transparent.
- Objects with a lower emission scale will always render faster, as less light will be generated, which will generate less noise.
- Objects with a lower scattering scale (darker color) will always render faster. Respectively, bright scattering (e.g., color set to pure white) will render slower.
- Always use the Single bounce only option under the Scattering tab at the Volume Grid object's properties. Disable this option only when it's absolutely necessary. Enabling it will usually bring just a little quality improvement and will make rendering a lot slower.
Aren't Corona Volume Grid controls similar to those found in the Corona Volume Mtl?
Yes, the controls available in the Corona Volume Grid object are very similar to those found in the Corona Volume material, and they produce very similar results. If you are familiar with the Corona Volume material and SSS effects in Corona, then the volume grids shouldn't be a challenge for you!
See also:
- How to use volumetrics?
- What are the two available SSS modes?
- How to use Subsurface Scattering (SSS) Materials