summaryrefslogtreecommitdiff
path: root/doc/classes
diff options
context:
space:
mode:
authorclayjohn <claynjohn@gmail.com>2020-12-07 21:37:09 -0800
committerclayjohn <claynjohn@gmail.com>2020-12-21 23:08:59 -0800
commit44f89223059c8dbdafa8f9cfc2256b135653f646 (patch)
treea7cafaba48ea2e3dbd4ea4c7a5f7489075d13466 /doc/classes
parentfa9332a0e77d498ce9815d36414ebbe4eadfc37b (diff)
Port ASSAO to Godot to replace SAO
Diffstat (limited to 'doc/classes')
-rw-r--r--doc/classes/Environment.xml39
-rw-r--r--doc/classes/ProjectSettings.xml19
-rw-r--r--doc/classes/RenderingServer.xml38
3 files changed, 48 insertions, 48 deletions
diff --git a/doc/classes/Environment.xml b/doc/classes/Environment.xml
index c5b6a54f71..9dd4ecc37b 100644
--- a/doc/classes/Environment.xml
+++ b/doc/classes/Environment.xml
@@ -218,26 +218,29 @@
<member name="ssao_ao_channel_affect" type="float" setter="set_ssao_ao_channel_affect" getter="get_ssao_ao_channel_affect" default="0.0">
The screen-space ambient occlusion intensity on materials that have an AO texture defined. Values higher than [code]0[/code] will make the SSAO effect visible in areas darkened by AO textures.
</member>
- <member name="ssao_bias" type="float" setter="set_ssao_bias" getter="get_ssao_bias" default="0.01">
- The screen-space ambient occlusion bias. This should be kept high enough to prevent "smooth" curves from being affected by ambient occlusion.
- </member>
- <member name="ssao_blur" type="int" setter="set_ssao_blur" getter="get_ssao_blur" enum="Environment.SSAOBlur" default="3">
- The screen-space ambient occlusion blur quality. See [enum SSAOBlur] for possible values.
- </member>
- <member name="ssao_edge_sharpness" type="float" setter="set_ssao_edge_sharpness" getter="get_ssao_edge_sharpness" default="4.0">
- The screen-space ambient occlusion edge sharpness.
+ <member name="ssao_detail" type="float" setter="set_ssao_detail" getter="get_ssao_detail" default="0.5">
+ Sets the strength of the additional level of detail for the screen-space ambient occlusion effect. A high value makes the detail pass more prominent, but it may contribute to aliasing in your final image.
</member>
<member name="ssao_enabled" type="bool" setter="set_ssao_enabled" getter="is_ssao_enabled" default="false">
- If [code]true[/code], the screen-space ambient occlusion effect is enabled. This darkens objects' corners and cavities to simulate ambient light not reaching the entire object as in real life. This works well for small, dynamic objects, but baked lighting or ambient occlusion textures will do a better job at displaying ambient occlusion on large static objects. This is a costly effect and should be disabled first when running into performance issues.
+ If [code]true[/code], the screen-space ambient occlusion effect is enabled. This darkens objects' corners and cavities to simulate ambient light not reaching the entire object as in real life. This works well for small, dynamic objects, but baked lighting or ambient occlusion textures will do a better job at displaying ambient occlusion on large static objects. Godot uses a form of SSAO called Adaptive Screen Space Ambient Occlusion which is itself a form of Horizon Based Ambient Occlusion.
+ </member>
+ <member name="ssao_horizon" type="float" setter="set_ssao_horizon" getter="get_ssao_horizon" default="0.06">
+ The threshold for considering whether a given point on a surface is occluded or not represented as an angle from the horizon mapped into the [code]0.0-1.0[/code] range. A value of [code]1.0[/code] results in no occlusion.
</member>
- <member name="ssao_intensity" type="float" setter="set_ssao_intensity" getter="get_ssao_intensity" default="1.0">
- The primary screen-space ambient occlusion intensity. See also [member ssao_radius].
+ <member name="ssao_intensity" type="float" setter="set_ssao_intensity" getter="get_ssao_intensity" default="2.0">
+ The primary screen-space ambient occlusion intensity. Acts as a multiplier for the screen-space ambient occlusion effect. A higher value results in darker occlusion.
</member>
<member name="ssao_light_affect" type="float" setter="set_ssao_direct_light_affect" getter="get_ssao_direct_light_affect" default="0.0">
The screen-space ambient occlusion intensity in direct light. In real life, ambient occlusion only applies to indirect light, which means its effects can't be seen in direct light. Values higher than [code]0[/code] will make the SSAO effect visible in direct light.
</member>
+ <member name="ssao_power" type="float" setter="set_ssao_power" getter="get_ssao_power" default="1.5">
+ The distribution of occlusion. A higher value results in darker occlusion, similar to [member ssao_intensity], but with a sharper falloff.
+ </member>
<member name="ssao_radius" type="float" setter="set_ssao_radius" getter="get_ssao_radius" default="1.0">
- The primary screen-space ambient occlusion radius.
+ The distance at which objects can occlude each other when calculating screen-space ambient occlusion. Higher values will result in occlusion over a greater distance at the cost of performance and quality.
+ </member>
+ <member name="ssao_sharpness" type="float" setter="set_ssao_sharpness" getter="get_ssao_sharpness" default="0.98">
+ Sharpness refers to the amount that the screen-space ambient occlusion effect is allowed to blur over the edges of objects. Setting too high will result in aliasing around the edges of objects. Setting too low will make object edges appear blurry.
</member>
<member name="tonemap_exposure" type="float" setter="set_tonemap_exposure" getter="get_tonemap_exposure" default="1.0">
The default exposure used for tonemapping.
@@ -335,18 +338,6 @@
<constant name="GLOW_BLEND_MODE_MIX" value="4" enum="GlowBlendMode">
Mixes the glow with the underlying color to avoid increasing brightness as much while still maintaining a glow effect.
</constant>
- <constant name="SSAO_BLUR_DISABLED" value="0" enum="SSAOBlur">
- No blur for the screen-space ambient occlusion effect (fastest).
- </constant>
- <constant name="SSAO_BLUR_1x1" value="1" enum="SSAOBlur">
- 1×1 blur for the screen-space ambient occlusion effect.
- </constant>
- <constant name="SSAO_BLUR_2x2" value="2" enum="SSAOBlur">
- 2×2 blur for the screen-space ambient occlusion effect.
- </constant>
- <constant name="SSAO_BLUR_3x3" value="3" enum="SSAOBlur">
- 3×3 blur for the screen-space ambient occlusion effect. Increases the radius of the blur for a smoother look, but can result in checkerboard-like artifacts.
- </constant>
<constant name="SDFGI_CASCADES_4" value="0" enum="SDFGICascades">
</constant>
<constant name="SDFGI_CASCADES_6" value="1" enum="SDFGICascades">
diff --git a/doc/classes/ProjectSettings.xml b/doc/classes/ProjectSettings.xml
index d0f2a927cb..e856d1ea9c 100644
--- a/doc/classes/ProjectSettings.xml
+++ b/doc/classes/ProjectSettings.xml
@@ -1240,11 +1240,26 @@
<member name="rendering/quality/shadows/soft_shadow_quality.mobile" type="int" setter="" getter="" default="0">
Lower-end override for [member rendering/quality/shadows/soft_shadow_quality] on mobile devices, due to performance concerns or driver support.
</member>
+ <member name="rendering/quality/ssao/adaptive_target" type="float" setter="" getter="" default="0.5">
+ Quality target to use when [member rendering/quality/ssao/quality] is set to [code]ULTRA[/code]. A value of [code]0.0[/code] provides a quality and speed similar to [code]MEDIUM[/code] while a value of [code]1.0[/code] provides much higher quality than any of the other settings at the cost of performance.
+ </member>
+ <member name="rendering/quality/ssao/blur_passes" type="int" setter="" getter="" default="2">
+ Number of blur passes to use when computing screen-space ambient occlusion. A higher number will result in a smoother look, but will be slower to compute and will have less high-frequency detail.
+ </member>
+ <member name="rendering/quality/ssao/fadeout_from" type="float" setter="" getter="" default="50.0">
+ Distance at which the screen-space ambient occlusion effect starts to fade out. Use this hide ambient occlusion at great distances.
+ </member>
+ <member name="rendering/quality/ssao/fadeout_to" type="float" setter="" getter="" default="300.0">
+ Distance at which the screen-space ambient occlusion is fully faded out. Use this hide ambient occlusion at great distances.
+ </member>
<member name="rendering/quality/ssao/half_size" type="bool" setter="" getter="" default="false">
If [code]true[/code], screen-space ambient occlusion will be rendered at half size and then upscaled before being added to the scene. This is significantly faster but may miss small details.
</member>
- <member name="rendering/quality/ssao/quality" type="int" setter="" getter="" default="1">
- Sets the quality of the screen-space ambient occlusion effect. Higher values take more samples and so will result in better quality, at the cost of performance.
+ <member name="rendering/quality/ssao/half_size.mobile" type="bool" setter="" getter="" default="true">
+ Lower-end override for [member rendering/quality/ssao/half_size] on mobile devices, due to performance concerns.
+ </member>
+ <member name="rendering/quality/ssao/quality" type="int" setter="" getter="" default="2">
+ Sets the quality of the screen-space ambient occlusion effect. Higher values take more samples and so will result in better quality, at the cost of performance. Setting to [code]ULTRA[/code] will use the [member rendering/quality/ssao/adaptive_target] setting.
</member>
<member name="rendering/quality/subsurface_scattering/subsurface_scattering_depth_scale" type="float" setter="" getter="" default="0.01">
Scales the depth over which the subsurface scattering effect is applied. A high value may allow light to scatter into a part of the mesh or another mesh that is close in screen space but far in depth.
diff --git a/doc/classes/RenderingServer.xml b/doc/classes/RenderingServer.xml
index 74eb6a17e5..036b50f0ed 100644
--- a/doc/classes/RenderingServer.xml
+++ b/doc/classes/RenderingServer.xml
@@ -765,17 +765,20 @@
</argument>
<argument index="3" name="intensity" type="float">
</argument>
- <argument index="4" name="bias" type="float">
+ <argument index="4" name="power" type="float">
</argument>
- <argument index="5" name="light_affect" type="float">
+ <argument index="5" name="detail" type="float">
</argument>
- <argument index="6" name="ao_channel_affect" type="float">
+ <argument index="6" name="horizon" type="float">
</argument>
- <argument index="7" name="blur" type="int" enum="RenderingServer.EnvironmentSSAOBlur">
+ <argument index="7" name="sharpness" type="float">
</argument>
- <argument index="8" name="bilateral_sharpness" type="float">
+ <argument index="8" name="light_affect" type="float">
+ </argument>
+ <argument index="9" name="ao_channel_affect" type="float">
</argument>
<description>
+ Sets the variables to be used with the "screen space ambient occlusion" post-process effect. See [Environment] for more details.
</description>
</method>
<method name="environment_set_ssr">
@@ -3499,29 +3502,20 @@
</constant>
<constant name="ENV_SSR_ROUGNESS_QUALITY_HIGH" value="3" enum="EnvironmentSSRRoughnessQuality">
</constant>
- <constant name="ENV_SSAO_BLUR_DISABLED" value="0" enum="EnvironmentSSAOBlur">
- Disables the blur set for SSAO. Will make SSAO look noisier.
- </constant>
- <constant name="ENV_SSAO_BLUR_1x1" value="1" enum="EnvironmentSSAOBlur">
- Perform a 1x1 blur on the SSAO output.
- </constant>
- <constant name="ENV_SSAO_BLUR_2x2" value="2" enum="EnvironmentSSAOBlur">
- Performs a 2x2 blur on the SSAO output.
- </constant>
- <constant name="ENV_SSAO_BLUR_3x3" value="3" enum="EnvironmentSSAOBlur">
- Performs a 3x3 blur on the SSAO output. Use this for smoothest SSAO.
- </constant>
- <constant name="ENV_SSAO_QUALITY_LOW" value="0" enum="EnvironmentSSAOQuality">
+ <constant name="ENV_SSAO_QUALITY_VERY_LOW" value="0" enum="EnvironmentSSAOQuality">
Lowest quality of screen space ambient occlusion.
</constant>
- <constant name="ENV_SSAO_QUALITY_MEDIUM" value="1" enum="EnvironmentSSAOQuality">
+ <constant name="ENV_SSAO_QUALITY_LOW" value="1" enum="EnvironmentSSAOQuality">
+ Low quality screen space ambient occlusion.
+ </constant>
+ <constant name="ENV_SSAO_QUALITY_MEDIUM" value="2" enum="EnvironmentSSAOQuality">
Medium quality screen space ambient occlusion.
</constant>
- <constant name="ENV_SSAO_QUALITY_HIGH" value="2" enum="EnvironmentSSAOQuality">
+ <constant name="ENV_SSAO_QUALITY_HIGH" value="3" enum="EnvironmentSSAOQuality">
High quality screen space ambient occlusion.
</constant>
- <constant name="ENV_SSAO_QUALITY_ULTRA" value="3" enum="EnvironmentSSAOQuality">
- Highest quality screen space ambient occlusion.
+ <constant name="ENV_SSAO_QUALITY_ULTRA" value="4" enum="EnvironmentSSAOQuality">
+ Highest quality screen space ambient occlusion. Uses the adaptive setting which can be dynamically adjusted to smoothly balance performance and visual quality.
</constant>
<constant name="SUB_SURFACE_SCATTERING_QUALITY_DISABLED" value="0" enum="SubSurfaceScatteringQuality">
</constant>