-
8 light bounces
-
4 light bounces
-
3 light bounces
-
2 light bounces
-
1 light bounce
-
0 bounces (direct light only, no global illumination)
Render Optimization: Difference between revisions
More actions
Standingpad (talk | contribs) Clarified sentence regarding cost of removing alpha faces |
Standingpad (talk | contribs) →Texture Cache: Remove period in reference |
||
| (4 intermediate revisions by the same user not shown) | |||
| Line 63: | Line 63: | ||
</tabber> | </tabber> | ||
In addition to max light bounces, there is also stepping rate and max steps. Stepping rate defines how many "steps" is performed in a volumetric object, where lower values allow for more detail, at the cost of render time, and max steps defines how many steps Cycles will perform for volumes before giving up<ref>https://docs.blender.org/manual/en/4.4/render/cycles/render_settings/volumes.html</ref>. Depending on the scene, the default value of <math>1</math> may be excessively low, and increasing the rate may allow for performance improvements. In addition, decreasing max steps may also improve render times, at the cost of detail. | In addition to max light bounces, there is also volume rendering, which can be set to either the biased ray marching algorithm, or unbiased null scattering algorithm. By default, Cycles uses the unbiased null scattering algorithm to avoid artifacts, at the cost of potentially more noise<ref>https://projects.blender.org/blender/blender/pulls/134460</ref><ref>https://docs.blender.org/manual/en/latest/render/cycles/render_settings/volumes.html</ref>. However, in certain scenarios, null scattering can incur a performance penalty compared to biased rendering with comparable output; this usually occurs in objects where the stepping rate and/or max steps options in biased rendering can be adjusted for performance gains, with little loss in the quality of the rendered volume, such as with clouds<ref>https://www.youtube.com/watch?v=NpKwVgTwAFg</ref>. | ||
Biased volume rendering in Cycles is based on two settings: stepping rate, and max steps. Stepping rate defines how many "steps" is performed in a volumetric object, where lower values allow for more detail, at the cost of render time, and max steps defines how many steps Cycles will perform for volumes before giving up<ref>https://docs.blender.org/manual/en/4.4/render/cycles/render_settings/volumes.html</ref>. Depending on the scene, the default value of <math>1</math> may be excessively low, and increasing the rate may allow for performance improvements. In addition, decreasing max steps may also improve render times, at the cost of detail. | |||
Like many path tracers, Cycles includes options to clamp the brightness of pixels caused by both direct and indirect bounces. When set to <math>0</math>, no clamping is done<ref>https://docs.blender.org/manual/en/4.4/render/cycles/render_settings/light_paths.html#clamping</ref>. While clamping direct lighting is usually not necessary, clamping indirect lighting may reduce the amount of [[Firefly|fireflies]] created when rendering. However, clamping indirect can often reduce the brightness of highlights on reflective objects. | Like many path tracers, Cycles includes options to clamp the brightness of pixels caused by both direct and indirect bounces. When set to <math>0</math>, no clamping is done<ref>https://docs.blender.org/manual/en/4.4/render/cycles/render_settings/light_paths.html#clamping</ref>. While clamping direct lighting is usually not necessary, clamping indirect lighting may reduce the amount of [[Firefly|fireflies]] created when rendering. However, clamping indirect can often reduce the brightness of highlights on reflective objects. | ||
| Line 94: | Line 96: | ||
Alpha transparency may introduce slow down when rendering as Cycles has to execute an object's shader trace a ray when hitting a transparent portion.<ref>https://docs.blender.org/manual/en/latest/render/cycles/render_settings/light_paths.html#transparency</ref> In cases where many objects with alpha transparency overlap, such as leaves or grass, it may be beneficial to remove the transparent portions. <ref>[https://youtu.be/8gSyEpt4-60?si=yKZp6k1iYtFfiVPH Blender Guru: 18 Ways to Speed Up Cycles Rendering - Remove Alpha Transparency]</ref> However, it's possible that any performance improvement is negated by the cost any additional geometry needed to remove alpha transparent faces. | Alpha transparency may introduce slow down when rendering as Cycles has to execute an object's shader trace a ray when hitting a transparent portion.<ref>https://docs.blender.org/manual/en/latest/render/cycles/render_settings/light_paths.html#transparency</ref> In cases where many objects with alpha transparency overlap, such as leaves or grass, it may be beneficial to remove the transparent portions. <ref>[https://youtu.be/8gSyEpt4-60?si=yKZp6k1iYtFfiVPH Blender Guru: 18 Ways to Speed Up Cycles Rendering - Remove Alpha Transparency]</ref> However, it's possible that any performance improvement is negated by the cost any additional geometry needed to remove alpha transparent faces. | ||
Volumetric shaders may introduce additional noise and render time.<ref>[https://youtu.be/8gSyEpt4-60?t=1931 Blender Guru: 18 Ways to Speed Up Cycles Rendering - Remove Volumetrics]</ref> In cases where volumetric shaders are used for god-rays, 2D emissive | Volumetric shaders may introduce additional noise and render time.<ref>[https://youtu.be/8gSyEpt4-60?t=1931 Blender Guru: 18 Ways to Speed Up Cycles Rendering - Remove Volumetrics]</ref> In cases where volumetric shaders are used for god-rays, 2D emissive planes can make a suitable substitute. | ||
==== Lights ==== | ==== Lights ==== | ||
| Line 123: | Line 125: | ||
Adaptive subdivision and/or [[Level of Detail|LOD]] may also introduce memory savings for terrain.<ref>[https://youtu.be/8gSyEpt4-60?t=1670 Blender Guru: 18 Ways to Speed Up Cycles Rendering - Adaptive Subdivision]</ref> | Adaptive subdivision and/or [[Level of Detail|LOD]] may also introduce memory savings for terrain.<ref>[https://youtu.be/8gSyEpt4-60?t=1670 Blender Guru: 18 Ways to Speed Up Cycles Rendering - Adaptive Subdivision]</ref> | ||
===== Texture Cache ===== | |||
{{Note|Note: The following information is about a feature that, as of writing, is not in the stable releases of Blender. While this feature is mostly complete, it is subject to changes before entering stable}} | |||
In scenes with a large amount of textures, the texture cache feature may be used. At its core, texture cache works by taking every texture in the scene and creating various versions with reduced resolutions; it then loads textures that are visible to the camera, using the distance of objects in the scene to decide the resolution loaded<ref>https://developer.blender.org/docs/release_notes/5.2/cycles/</ref><ref>[https://projects.blender.org/blender/blender/pulls/154913 Blender Pull Request 154913: Cycles: Add image texture cache and mipmaps]</ref><ref>[https://youtu.be/-JVROzcTElM Christopher 3D: Blender 5.2: The New Texture Caching System Explained]</ref>. In addition, when using tiles, Cycles will also unload previously loaded textures that are not visible to the current tile being rendered, through a feature known as cache eviction<ref>[https://projects.blender.org/blender/blender/pulls/157244 Blender Pull Request 157244: Cycles: Texture cache eviction and widen ray differentials]</ref><ref>[https://youtu.be/8PIoc8IJLzk Christopher 3D: Blender 5.2. More memory efficiency gains with Cache Eviction]</ref>. | |||
However, the significant reductions in memory usage stemming from texture cache come from scenes with many large textures (e.g. 4K textures). Thus, for Minecraft animation specifically, texture cache may only benefit scenes using higher resolution textures, with standard Minecraft animation scenes setting little to no improvement in memory usage. Further testing would be needed to make definite conclusions. | |||
Latest revision as of 22:11, 16 May 2026
Render optimizations are methods and techniques that aim to improve render times, render quality, or sometimes a combination of both. These include modifying the behavior of the engine or modifying the scene itself.
Optimizing Scenes
In many cases, optimizing the actual scene itself can improve render times or quality. Some of these include:
- Reducing geometry, or optimizing topology (e.g. using quads instead of n-gons)
- Reducing texture sizes (e.g. using 2K textures instead of 4K)
- Adequate routes for light paths (e.g. large gaps)
- Avoiding complex materials or adjusting materials to behave differently (e.g. archviz glass)
- Reducing resolution of the final render
Optimizing Engine Behavior
Often times optimizing an engine's behavior can also allow for reducing render times or scene quality. Some examples include:
- Limiting light bounces, or even approximating lighting through alternate means
- Adjusting sample count for ray tracing engines, often in conjunction with denoising algorithms
- Adjusting shadow resolution for rasterized engines
Software/Engine Specific Recommendations
The following are recommendations for specific programs or render engines. Depending on the scene, these may or may not need to be adjusted.
Cycles (Blender)
Although Cycles is one of the faster path tracing engines, there's some options that can be adjusted for performance.
Sampling
Beyond adjusting the sample count, there are alternate settings in Cycles specifically related to sampling. In particular, adjusting adaptive sampling settings to kick in earlier on can reduce render times, at the cost of more noise.[1] Setting the noise threshold to instead of may be a good compromise of quality and render times.
Another sampling related setting in Cycles is light tree, which reduces noise in scenes with a large amount of lights[2]. Note that issues may result from overlapping area lights, though this may be a bug.[3]
Light Paths
Adjusting light path settings can also be another source of performance and/or quality improvement. This can be in the form of adjusting light bounces, volumetric stepping, or clamping bright pixels.
By default, Cycles sets its max light bounces to , which may be excessive in many cases. Lowering to often creates little to no difference, while reducing render times.
Some scenes may allow for reducing max light bounces further down to or even . However, it should be noted that adjustments the range of to typically introduce larger changes to the scene than higher ranges.[4]
-
8 light bounces
-
4 light bounces
-
3 light bounces
-
2 light bounces
-
1 light bounce
-
0 light bounces
In addition to max light bounces, there is also volume rendering, which can be set to either the biased ray marching algorithm, or unbiased null scattering algorithm. By default, Cycles uses the unbiased null scattering algorithm to avoid artifacts, at the cost of potentially more noise[5][6]. However, in certain scenarios, null scattering can incur a performance penalty compared to biased rendering with comparable output; this usually occurs in objects where the stepping rate and/or max steps options in biased rendering can be adjusted for performance gains, with little loss in the quality of the rendered volume, such as with clouds[7].
Biased volume rendering in Cycles is based on two settings: stepping rate, and max steps. Stepping rate defines how many "steps" is performed in a volumetric object, where lower values allow for more detail, at the cost of render time, and max steps defines how many steps Cycles will perform for volumes before giving up[8]. Depending on the scene, the default value of may be excessively low, and increasing the rate may allow for performance improvements. In addition, decreasing max steps may also improve render times, at the cost of detail.
Like many path tracers, Cycles includes options to clamp the brightness of pixels caused by both direct and indirect bounces. When set to , no clamping is done[9]. While clamping direct lighting is usually not necessary, clamping indirect lighting may reduce the amount of fireflies created when rendering. However, clamping indirect can often reduce the brightness of highlights on reflective objects.
Cycles also includes options to disable caustics.[10] However, disabling these will drastically change lighting if a scene contains many reflective objects, and should be considered a last resort in most cases.[11]
Fast GI approximation can also improve render times[12], though it can also drastically change how a scene looks.
-
Without Fast GI
-
Fast GI approximation after 1 light bounce
-
Fast GI approximation after 2 light bounces
-
Without Fast GI
-
Fast GI approximation after 1 light bounce
-
Fast GI approximation after 2 light bounces
Shaders
In Cycles, certain shaders often create additional noise in a given scene. For example, a glass shader may create additional noise due to the calculation of caustics, leading some to create workarounds (such as archviz glass).
Like glass, the emission shader is often linked to increased noise.
Alpha transparency may introduce slow down when rendering as Cycles has to execute an object's shader trace a ray when hitting a transparent portion.[13] In cases where many objects with alpha transparency overlap, such as leaves or grass, it may be beneficial to remove the transparent portions. [14] However, it's possible that any performance improvement is negated by the cost any additional geometry needed to remove alpha transparent faces.
Volumetric shaders may introduce additional noise and render time.[15] In cases where volumetric shaders are used for god-rays, 2D emissive planes can make a suitable substitute.
Lights
Smaller lights (and by extension smaller beam spread values for area lights) can make it harder for samples to converge in a scene, leading to additional noise.
For a long time, light portals were a suggested method of decreasing noise in interior scenes.[16][17] However, in practice, light portals do not seem to make any difference in noise quality, both with large exterior gaps and small exterior gaps, while also slightly increasing render times. For this reason, light portals are not recommended as of Blender 3.0+. Cycles Legacy (Blender 2.61 to 2.93) may see benefits from portals, but more tests are needed.
- 4096 samples, 0.03 noise threshold
-
Heatmap of sample count in a scene without portals
-
Heatmap of sample count in a scene with portals. Note the lack of any major difference to the heatmap without portals
- 4096 samples, 0.03 noise threshold
-
Heatmap of sample count in a scene without portals
-
Heatmap of sample count in a scene with portals. Note the lack of any major difference to the heatmap without portals
In theory, path guiding is a more viable alternative, though only CPU rendering is supported.[18]
Objects
To reduce memory usage, using object instancing and/or duplicating objects with shared data may reduce memory usage when rendering.[19] This mainly benefits scenes with multiple objects that look the same/similar, such as trees in a forest, where each object doesn't have many unique features.
Adaptive subdivision and/or LOD may also introduce memory savings for terrain.[20]
Texture Cache
In scenes with a large amount of textures, the texture cache feature may be used. At its core, texture cache works by taking every texture in the scene and creating various versions with reduced resolutions; it then loads textures that are visible to the camera, using the distance of objects in the scene to decide the resolution loaded[21][22][23]. In addition, when using tiles, Cycles will also unload previously loaded textures that are not visible to the current tile being rendered, through a feature known as cache eviction[24][25].
However, the significant reductions in memory usage stemming from texture cache come from scenes with many large textures (e.g. 4K textures). Thus, for Minecraft animation specifically, texture cache may only benefit scenes using higher resolution textures, with standard Minecraft animation scenes setting little to no improvement in memory usage. Further testing would be needed to make definite conclusions.
- ↑ https://docs.blender.org/manual/en/4.4/render/cycles/render_settings/sampling.html#adaptive-sampling
- ↑ https://docs.blender.org/manual/en/4.4/render/cycles/render_settings/sampling.html#lights
- ↑ https://projects.blender.org/blender/blender/issues/141576
- ↑ Blender Guru: 18 Ways to Speed Up Cycles Rendering - Reduce Light Bounces
- ↑ https://projects.blender.org/blender/blender/pulls/134460
- ↑ https://docs.blender.org/manual/en/latest/render/cycles/render_settings/volumes.html
- ↑ https://www.youtube.com/watch?v=NpKwVgTwAFg
- ↑ https://docs.blender.org/manual/en/4.4/render/cycles/render_settings/volumes.html
- ↑ https://docs.blender.org/manual/en/4.4/render/cycles/render_settings/light_paths.html#clamping
- ↑ https://docs.blender.org/manual/en/4.4/render/cycles/render_settings/light_paths.html#caustics
- ↑ Blender Guru: 18 Ways to Speed Up Cycles Rendering - Clamp it
- ↑ https://docs.blender.org/manual/en/4.4/render/cycles/render_settings/light_paths.html#fast-gi-approximation
- ↑ https://docs.blender.org/manual/en/latest/render/cycles/render_settings/light_paths.html#transparency
- ↑ Blender Guru: 18 Ways to Speed Up Cycles Rendering - Remove Alpha Transparency
- ↑ Blender Guru: 18 Ways to Speed Up Cycles Rendering - Remove Volumetrics
- ↑ https://docs.blender.org/manual/en/latest/render/cycles/light_settings.html#render-cycles-lights-area-portals
- ↑ Blender Guru: 18 Ways to Speed Up Cycles Rendering - Use Portals
- ↑ https://docs.blender.org/manual/en/latest/render/cycles/render_settings/sampling.html#path-guiding
- ↑ Blender Guru: 18 Ways to Speed Up Cycles Rendering - Object Instancing
- ↑ Blender Guru: 18 Ways to Speed Up Cycles Rendering - Adaptive Subdivision
- ↑ https://developer.blender.org/docs/release_notes/5.2/cycles/
- ↑ Blender Pull Request 154913: Cycles: Add image texture cache and mipmaps
- ↑ Christopher 3D: Blender 5.2: The New Texture Caching System Explained
- ↑ Blender Pull Request 157244: Cycles: Texture cache eviction and widen ray differentials
- ↑ Christopher 3D: Blender 5.2. More memory efficiency gains with Cache Eviction