Volumes
Volume rendering is used to render various effects that cannot be represented by hard surfaces alone.
Smoke, fire or clouds are set up using a volume object or fluid simulation, with only a volume shader.
Meshes can also be used to create such shapes by removing the default surface shader and using a volume shader with the mesh shape defining the volume bounds and textures defining the volume density.
Mist is created with a volume shader for the world, or with a large mesh object encompassing the scene.
Absorption in glass is simulated by combining a glass surface shader with refraction and a volume absorption shader for the interior of the object.
Shading(シェーディング)
Principled Volume (プリンシプル ボリューム)
Principled Volume is a physically-based volume shader that can be used to create a wide range of volume materials. It supports scattering, absorption and emission in one easy to use node. Fire can be rendered with blackbody emission.
Volume Components
For more control, volume shading components can be manually combined into a custom shader setup.
Volume Absorption will absorb part of the light as it passes through the volume. This can be used to shade for example black smoke or colored glass objects, or mixed with the Volume Scatter node. This node is similar to the transparent BSDF node, it blocks part of the light and lets other light pass straight through.
Volume Scatter lets light scatter in other directions as it hits particles in the volume. The anisotropy defines in which direction the light is more likely to scatter. A value of 0 will let light scatter evenly in all directions (similar to the diffuse BSDF node), negative values let light scatter mostly backwards, and positive values let light scatter mostly forward. This can be used to shade white smoke or clouds for example.
Emission will emit light from the volume, for example for fire.
付録
When rendering smoke and fire, volume attributes are used to define the shape and shading of the volume. The Principled Volume shader will use them by default, while custom volume shaders can use the Attribute node to get attributes such as density, color and temperature.
Density (密度)
全てのボリュームシェーダーは Density の入力を持ちます。Density はどれだけの光がボリュームと、吸収や拡散として、反応するかを定義し、どれだけが通過するかを定義しています。煙のような効果を得るためには Density の値を、煙が存在してどの程度であるか (Density は 0 より大きな値) と、煙が存在しない (Density は 0) との間でどれだけの値にするかを設定することになるでしょう。
Volumes in the real world consist of particles, a higher density means there are more particles per unit volume. More particles means there is a higher chance for light to collide with a particle and get absorbed or scattered, rather than passing straight through.
Mesh Volumes
Meshes used for volume render should be closed and Manifold. That means that there should be no holes in the mesh. Each edge must be connected to exactly two faces such that there are no holes or T-shaped faces where three or more faces are connected to an edge.
正しい結果を得るため法線は外側を向いている必要が有ります。法線はボリュームに対して光が出入りする方向を決め、もしその方向が間違っていたり、メッシュ上に穴がある場合、レンダラーはボリュームの内側と外側を決定する事ができなくなります。
これらのルールはガラスの屈折を正しくレンダリングする際も同様です。
World Volume
A volume shader can also be applied to the world, filling the entire space.
Currently, this is most useful for night time or other dark scenes, as the world surface shader or sun lights will have no effect if a volume shader is used. This is because the world background is assumed to be infinitely far away, which is accurate enough for the sun for example. However, for modeling effects such as fog or atmospheric scattering, it is not a good assumption that the volume fills the entire space, as most of the distance between the sun and the earth is empty space. For such effects it is be better to create a volume object surrounding the scene. The size of this object will determine how much light is scattered or absorbed.
Multiple Scattering
Real-world effects such as scattering in clouds or subsurface scattering require many scattering bounces. However, unbiased rendering of such effects can be noisy, so by default the number of bounces is zero in Cycles, and no support is available in Eevee. The effect you get when rendering with zero volume bounces is what is known as "single scattering", the effect from more bounces is "multiple scattering".
For rendering materials like skin or milk that require multiple scattering, subsurface scattering is more efficient and easier to control. Particularly the random walk method can accurately render such materials.
For materials such as clouds or smoke that do not have a well-defined surface, volume rendering is required. These look best with many scattering bounces, but in practice one might have to limit the number of bounces to keep render times acceptable.