Environment

Inherits:Resource<RefCounted<Object

Resource for environment nodes (likeWorldEnvironment) that define multiple rendering options.

Description

Resource for environment nodes (likeWorldEnvironment) that define multiple environment operations (such as backgroundSky orColor, ambient light, fog, depth-of-field...). These parameters affect the final render of the scene. The order of these operations is:

  • Depth of Field Blur

  • Glow

  • Tonemap (Auto Exposure)

  • Adjustments

Tutorials

Properties

float

adjustment_brightness

1.0

Texture

adjustment_color_correction

float

adjustment_contrast

1.0

bool

adjustment_enabled

false

float

adjustment_saturation

1.0

Color

ambient_light_color

Color(0,0,0,1)

float

ambient_light_energy

1.0

float

ambient_light_sky_contribution

1.0

AmbientSource

ambient_light_source

0

int

background_camera_feed_id

1

int

background_canvas_max_layer

0

Color

background_color

Color(0,0,0,1)

float

background_energy_multiplier

1.0

float

background_intensity

30000.0

BGMode

background_mode

0

float

fog_aerial_perspective

0.0

float

fog_density

0.01

float

fog_depth_begin

10.0

float

fog_depth_curve

1.0

float

fog_depth_end

100.0

bool

fog_enabled

false

float

fog_height

0.0

float

fog_height_density

0.0

Color

fog_light_color

Color(0.518,0.553,0.608,1)

float

fog_light_energy

1.0

FogMode

fog_mode

0

float

fog_sky_affect

1.0

float

fog_sun_scatter

0.0

GlowBlendMode

glow_blend_mode

2

float

glow_bloom

0.0

bool

glow_enabled

false

float

glow_hdr_luminance_cap

12.0

float

glow_hdr_scale

2.0

float

glow_hdr_threshold

1.0

float

glow_intensity

0.8

float

glow_levels/1

0.0

float

glow_levels/2

0.0

float

glow_levels/3

1.0

float

glow_levels/4

0.0

float

glow_levels/5

1.0

float

glow_levels/6

0.0

float

glow_levels/7

0.0

Texture

glow_map

float

glow_map_strength

0.8

float

glow_mix

0.05

bool

glow_normalized

false

float

glow_strength

1.0

ReflectionSource

reflected_light_source

0

float

sdfgi_bounce_feedback

0.5

float

sdfgi_cascade0_distance

12.8

int

sdfgi_cascades

4

bool

sdfgi_enabled

false

float

sdfgi_energy

1.0

float

sdfgi_max_distance

204.8

float

sdfgi_min_cell_size

0.2

float

sdfgi_normal_bias

1.1

float

sdfgi_probe_bias

1.1

bool

sdfgi_read_sky_light

true

bool

sdfgi_use_occlusion

false

SDFGIYScale

sdfgi_y_scale

1

Sky

sky

float

sky_custom_fov

0.0

Vector3

sky_rotation

Vector3(0,0,0)

float

ssao_ao_channel_affect

0.0

float

ssao_detail

0.5

bool

ssao_enabled

false

float

ssao_horizon

0.06

float

ssao_intensity

2.0

float

ssao_light_affect

0.0

float

ssao_power

1.5

float

ssao_radius

1.0

float

ssao_sharpness

0.98

bool

ssil_enabled

false

float

ssil_intensity

1.0

float

ssil_normal_rejection

1.0

float

ssil_radius

5.0

float

ssil_sharpness

0.98

float

ssr_depth_tolerance

0.2

bool

ssr_enabled

false

float

ssr_fade_in

0.15

float

ssr_fade_out

2.0

int

ssr_max_steps

64

float

tonemap_exposure

1.0

ToneMapper

tonemap_mode

0

float

tonemap_white

1.0

Color

volumetric_fog_albedo

Color(1,1,1,1)

float

volumetric_fog_ambient_inject

0.0

float

volumetric_fog_anisotropy

0.2

float

volumetric_fog_density

0.05

float

volumetric_fog_detail_spread

2.0

Color

volumetric_fog_emission

Color(0,0,0,1)

float

volumetric_fog_emission_energy

1.0

bool

volumetric_fog_enabled

false

float

volumetric_fog_gi_inject

1.0

float

volumetric_fog_length

64.0

float

volumetric_fog_sky_affect

1.0

float

volumetric_fog_temporal_reprojection_amount

0.9

bool

volumetric_fog_temporal_reprojection_enabled

true

Methods

float

get_glow_level(idx:int)const

void

set_glow_level(idx:int, intensity:float)


Enumerations

enumBGMode:🔗

BGModeBG_CLEAR_COLOR =0

Clears the background using the clear color defined inProjectSettings.rendering/environment/defaults/default_clear_color.

BGModeBG_COLOR =1

Clears the background using a custom clear color.

BGModeBG_SKY =2

Displays a user-defined sky in the background.

BGModeBG_CANVAS =3

Displays aCanvasLayer in the background.

BGModeBG_KEEP =4

Keeps on screen every pixel drawn in the background. This is the fastest background mode, but it can only be safely used in fully-interior scenes (no visible sky or sky reflections). If enabled in a scene where the background is visible, "ghost trail" artifacts will be visible when moving the camera.

BGModeBG_CAMERA_FEED =5

Displays a camera feed in the background.

BGModeBG_MAX =6

Represents the size of theBGMode enum.


enumAmbientSource:🔗

AmbientSourceAMBIENT_SOURCE_BG =0

Gather ambient light from whichever source is specified as the background.

AmbientSourceAMBIENT_SOURCE_DISABLED =1

Disable ambient light. This provides a slight performance boost overAMBIENT_SOURCE_SKY.

AmbientSourceAMBIENT_SOURCE_COLOR =2

Specify a specificColor for ambient light. This provides a slight performance boost overAMBIENT_SOURCE_SKY.

AmbientSourceAMBIENT_SOURCE_SKY =3

Gather ambient light from theSky regardless of what the background is.


enumReflectionSource:🔗

ReflectionSourceREFLECTION_SOURCE_BG =0

Use the background for reflections.

ReflectionSourceREFLECTION_SOURCE_DISABLED =1

Disable reflections. This provides a slight performance boost over other options.

ReflectionSourceREFLECTION_SOURCE_SKY =2

Use theSky for reflections regardless of what the background is.


enumToneMapper:🔗

ToneMapperTONE_MAPPER_LINEAR =0

Does not modify color data, resulting in a linear tonemapping curve which unnaturally clips bright values, causing bright lighting to look blown out. The simplest and fastest tonemapper.

ToneMapperTONE_MAPPER_REINHARDT =1

A simple tonemapping curve that rolls off bright values to prevent clipping. This results in an image that can appear dull and low contrast. Slower thanTONE_MAPPER_LINEAR.

Note: Whentonemap_white is left at the default value of1.0,TONE_MAPPER_REINHARDT produces an identical image toTONE_MAPPER_LINEAR.

ToneMapperTONE_MAPPER_FILMIC =2

Uses a film-like tonemapping curve to prevent clipping of bright values and provide better contrast thanTONE_MAPPER_REINHARDT. Slightly slower thanTONE_MAPPER_REINHARDT.

ToneMapperTONE_MAPPER_ACES =3

Uses a high-contrast film-like tonemapping curve and desaturates bright values for a more realistic appearance. Slightly slower thanTONE_MAPPER_FILMIC.

Note: This tonemapping operator is called "ACES Fitted" in Godot 3.x.

ToneMapperTONE_MAPPER_AGX =4

Uses a film-like tonemapping curve and desaturates bright values for a more realistic appearance. Better than other tonemappers at maintaining the hue of colors as they become brighter. The slowest tonemapping option.

Note:tonemap_white is fixed at a value of16.29, which makesTONE_MAPPER_AGX unsuitable for use with the Mobile rendering method.


enumGlowBlendMode:🔗

GlowBlendModeGLOW_BLEND_MODE_ADDITIVE =0

Additive glow blending mode. Mostly used for particles, glows (bloom), lens flare, bright sources.

GlowBlendModeGLOW_BLEND_MODE_SCREEN =1

Screen glow blending mode. Increases brightness, used frequently with bloom.

GlowBlendModeGLOW_BLEND_MODE_SOFTLIGHT =2

Soft light glow blending mode. Modifies contrast, exposes shadows and highlights (vivid bloom).

GlowBlendModeGLOW_BLEND_MODE_REPLACE =3

Replace glow blending mode. Replaces all pixels' color by the glow value. This can be used to simulate a full-screen blur effect by tweaking the glow parameters to match the original image's brightness.

GlowBlendModeGLOW_BLEND_MODE_MIX =4

Mixes the glow with the underlying color to avoid increasing brightness as much while still maintaining a glow effect.


enumFogMode:🔗

FogModeFOG_MODE_EXPONENTIAL =0

Use a physically-based fog model defined primarily by fog density.

FogModeFOG_MODE_DEPTH =1

Use a simple fog model defined by start and end positions and a custom curve. While not physically accurate, this model can be useful when you need more artistic control.


enumSDFGIYScale:🔗

SDFGIYScaleSDFGI_Y_SCALE_50_PERCENT =0

Use 50% scale for SDFGI on the Y (vertical) axis. SDFGI cells will be twice as short as they are wide. This allows providing increased GI detail and reduced light leaking with thin floors and ceilings. This is usually the best choice for scenes that don't feature much verticality.

SDFGIYScaleSDFGI_Y_SCALE_75_PERCENT =1

Use 75% scale for SDFGI on the Y (vertical) axis. This is a balance between the 50% and 100% SDFGI Y scales.

SDFGIYScaleSDFGI_Y_SCALE_100_PERCENT =2

Use 100% scale for SDFGI on the Y (vertical) axis. SDFGI cells will be as tall as they are wide. This is usually the best choice for highly vertical scenes. The downside is that light leaking may become more noticeable with thin floors and ceilings.


Property Descriptions

floatadjustment_brightness =1.0🔗

The global brightness value of the rendered scene. Effective only ifadjustment_enabled istrue.


Textureadjustment_color_correction🔗

TheTexture2D orTexture3D lookup table (LUT) to use for the built-in post-process color grading. Can use aGradientTexture1D for a 1-dimensional LUT, or aTexture3D for a more complex LUT. Effective only ifadjustment_enabled istrue.


floatadjustment_contrast =1.0🔗

The global contrast value of the rendered scene (default value is 1). Effective only ifadjustment_enabled istrue.


booladjustment_enabled =false🔗

Iftrue, enables theadjustment_* properties provided by this resource. Iffalse, modifications to theadjustment_* properties will have no effect on the rendered scene.


floatadjustment_saturation =1.0🔗

The global color saturation value of the rendered scene (default value is 1). Effective only ifadjustment_enabled istrue.


Colorambient_light_color =Color(0,0,0,1)🔗

The ambient light'sColor. Only effective ifambient_light_sky_contribution is lower than1.0 (exclusive).


floatambient_light_energy =1.0🔗

The ambient light's energy. The higher the value, the stronger the light. Only effective ifambient_light_sky_contribution is lower than1.0 (exclusive).


floatambient_light_sky_contribution =1.0🔗

Defines the amount of light that the sky brings on the scene. A value of0.0 means that the sky's light emission has no effect on the scene illumination, thus all ambient illumination is provided by the ambient light. On the contrary, a value of1.0 means thatall the light that affects the scene is provided by the sky, thus the ambient light parameter has no effect on the scene.

Note:ambient_light_sky_contribution is internally clamped between0.0 and1.0 (inclusive).


AmbientSourceambient_light_source =0🔗

The ambient light source to use for rendering materials and global illumination.


intbackground_camera_feed_id =1🔗

The ID of the camera feed to show in the background.


intbackground_canvas_max_layer =0🔗

The maximum layer ID to display. Only effective when using theBG_CANVAS background mode.


Colorbackground_color =Color(0,0,0,1)🔗

TheColor displayed for clear areas of the scene. Only effective when using theBG_COLOR background mode.


floatbackground_energy_multiplier =1.0🔗

Multiplier for background energy. Increase to make background brighter, decrease to make background dimmer.


floatbackground_intensity =30000.0🔗

Luminance of background measured in nits (candela per square meter). Only used whenProjectSettings.rendering/lights_and_shadows/use_physical_light_units is enabled. The default value is roughly equivalent to the sky at midday.


BGModebackground_mode =0🔗

The background mode.


floatfog_aerial_perspective =0.0🔗

If set above0.0 (exclusive), blends between the fog's color and the color of the backgroundSky, as read from the radiance cubemap. This has a small performance cost when set above0.0. Must havebackground_mode set toBG_SKY.

This is useful to simulateaerial perspective in large scenes with low density fog. However, it is not very useful for high-density fog, as the sky will shine through. When set to1.0, the fog color comes completely from theSky. If set to0.0, aerial perspective is disabled.

Notice that this does not sample theSky directly, but rather the radiance cubemap. The cubemap is sampled at a mipmap level depending on the depth of the rendered pixel; the farther away, the higher the resolution of the sampled mipmap. This results in the actual color being a blurred version of the sky, with more blur closer to the camera. The highest mipmap resolution is used at a depth ofCamera3D.far.


floatfog_density =0.01🔗

The fog density to be used. This is demonstrated in different ways depending on thefog_mode mode chosen:

Exponential Fog Mode: Higher values result in denser fog. The fog rendering is exponential like in real life.

Depth Fog mode: The maximum intensity of the deep fog, effect will appear in the distance (relative to the camera). At1.0 the fog will fully obscure the scene, at0.0 the fog will not be visible.


floatfog_depth_begin =10.0🔗

The fog's depth starting distance from the camera. Only available whenfog_mode is set toFOG_MODE_DEPTH.


floatfog_depth_curve =1.0🔗

The fog depth's intensity curve. A number of presets are available in the Inspector by right-clicking the curve. Only available whenfog_mode is set toFOG_MODE_DEPTH.


floatfog_depth_end =100.0🔗

The fog's depth end distance from the camera. If this value is set to0, it will be equal to the current camera'sCamera3D.far value. Only available whenfog_mode is set toFOG_MODE_DEPTH.


boolfog_enabled =false🔗

Iftrue, fog effects are enabled.


floatfog_height =0.0🔗

The height at which the height fog effect begins.


floatfog_height_density =0.0🔗

The density used to increase fog as height decreases. To make fog increase as height increases, use a negative value.


Colorfog_light_color =Color(0.518,0.553,0.608,1)🔗

The fog's color.


floatfog_light_energy =1.0🔗

The fog's brightness. Higher values result in brighter fog.


FogModefog_mode =0🔗

The fog mode.


floatfog_sky_affect =1.0🔗

The factor to use when affecting the sky with non-volumetric fog.1.0 means that fog can fully obscure the sky. Lower values reduce the impact of fog on sky rendering, with0.0 not affecting sky rendering at all.

Note:fog_sky_affect has no visual effect iffog_aerial_perspective is1.0.


floatfog_sun_scatter =0.0🔗

If set above0.0, renders the scene's directional light(s) in the fog color depending on the view angle. This can be used to give the impression that the sun is "piercing" through the fog.


GlowBlendModeglow_blend_mode =2🔗

The glow blending mode.

Note:glow_blend_mode has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


floatglow_bloom =0.0🔗

The bloom's intensity. If set to a value higher than0, this will make glow visible in areas darker than theglow_hdr_threshold.


boolglow_enabled =false🔗

Iftrue, the glow effect is enabled. This simulates real world eye/camera behavior where bright pixels bleed onto surrounding pixels.

Note: When using the Mobile rendering method, glow looks different due to the lower dynamic range available in the Mobile rendering method.

Note: When using the Compatibility rendering method, glow uses a different implementation with some properties being unavailable and hidden from the inspector:glow_levels/*,glow_normalized,glow_strength,glow_blend_mode,glow_mix,glow_map, andglow_map_strength. This implementation is optimized to run on low-end devices and is less flexible as a result.


floatglow_hdr_luminance_cap =12.0🔗

The higher threshold of the HDR glow. Areas brighter than this threshold will be clamped for the purposes of the glow effect.


floatglow_hdr_scale =2.0🔗

The bleed scale of the HDR glow.


floatglow_hdr_threshold =1.0🔗

The lower threshold of the HDR glow. When using the Mobile rendering method (which only supports a lower dynamic range up to2.0), this may need to be below1.0 for glow to be visible. A value of0.9 works well in this case. This value also needs to be decreased below1.0 when using glow in 2D, as 2D rendering is performed in SDR.


floatglow_intensity =0.8🔗

The overall brightness multiplier of the glow effect. When using the Mobile rendering method (which only supports a lower dynamic range up to2.0), this should be increased to1.5 to compensate.


floatglow_levels/1 =0.0🔗

The intensity of the 1st level of glow. This is the most "local" level (least blurry).

Note:glow_levels/1 has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


floatglow_levels/2 =0.0🔗

The intensity of the 2nd level of glow.

Note:glow_levels/2 has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


floatglow_levels/3 =1.0🔗

The intensity of the 3rd level of glow.

Note:glow_levels/3 has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


floatglow_levels/4 =0.0🔗

The intensity of the 4th level of glow.

Note:glow_levels/4 has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


floatglow_levels/5 =1.0🔗

The intensity of the 5th level of glow.

Note:glow_levels/5 has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


floatglow_levels/6 =0.0🔗

The intensity of the 6th level of glow.

Note:glow_levels/6 has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


floatglow_levels/7 =0.0🔗

The intensity of the 7th level of glow. This is the most "global" level (blurriest).

Note:glow_levels/7 has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


Textureglow_map🔗

The texture that should be used as a glow map tomultiply the resulting glow color according toglow_map_strength. This can be used to create a "lens dirt" effect. The texture's RGB color channels are used for modulation, but the alpha channel is ignored.

Note: The texture will be stretched to fit the screen. Therefore, it's recommended to use a texture with an aspect ratio that matches your project's base aspect ratio (typically 16:9).

Note:glow_map has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


floatglow_map_strength =0.8🔗

How strong of an influence theglow_map should have on the overall glow effect. A strength of0.0 means the glow map has no influence, while a strength of1.0 means the glow map has full influence.

Note: If the glow map has black areas, a value of1.0 can also turn off the glow effect entirely in specific areas of the screen.

Note:glow_map_strength has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


floatglow_mix =0.05🔗

When using theGLOW_BLEND_MODE_MIXglow_blend_mode, this controls how much the source image is blended with the glow layer. A value of0.0 makes the glow rendering invisible, while a value of1.0 is equivalent toGLOW_BLEND_MODE_REPLACE.

Note:glow_mix has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


boolglow_normalized =false🔗

Iftrue, glow levels will be normalized so that summed together their intensities equal1.0.

Note:glow_normalized has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


floatglow_strength =1.0🔗

The strength of the glow effect. This applies as the glow is blurred across the screen and increases the distance and intensity of the blur. When using the Mobile rendering method, this should be increased to compensate for the lower dynamic range.

Note:glow_strength has no effect when using the Compatibility rendering method, due to this rendering method using a simpler glow implementation optimized for low-end devices.


ReflectionSourcereflected_light_source =0🔗

The reflected (specular) light source.


floatsdfgi_bounce_feedback =0.5🔗

The energy multiplier applied to light every time it bounces from a surface when using SDFGI. Values greater than0.0 will simulate multiple bounces, resulting in a more realistic appearance. Increasingsdfgi_bounce_feedback generally has no performance impact. See alsosdfgi_energy.

Note: Values greater than0.5 can cause infinite feedback loops and should be avoided in scenes with bright materials.

Note: Ifsdfgi_bounce_feedback is0.0, indirect lighting will not be represented in reflections as light will only bounce one time.


floatsdfgi_cascade0_distance =12.8🔗

Note: This property is linked tosdfgi_min_cell_size andsdfgi_max_distance. Changing its value will automatically change those properties as well.


intsdfgi_cascades =4🔗

The number of cascades to use for SDFGI (between 1 and 8). A higher number of cascades allows displaying SDFGI further away while preserving detail up close, at the cost of performance. When using SDFGI on small-scale levels,sdfgi_cascades can often be decreased between1 and4 to improve performance.


boolsdfgi_enabled =false🔗

Iftrue, enables signed distance field global illumination for meshes that have theirGeometryInstance3D.gi_mode set toGeometryInstance3D.GI_MODE_STATIC. SDFGI is a real-time global illumination technique that works well with procedurally generated and user-built levels, including in situations where geometry is created during gameplay. The signed distance field is automatically generated around the camera as it moves. Dynamic lights are supported, but dynamic occluders and emissive surfaces are not.

Note: SDFGI is only supported in the Forward+ rendering method, not Mobile or Compatibility.

Performance: SDFGI is relatively demanding on the GPU and is not suited to low-end hardware such as integrated graphics (considerLightmapGI instead). To improve SDFGI performance, enableProjectSettings.rendering/global_illumination/gi/use_half_resolution in the Project Settings.

Note: Meshes should have sufficiently thick walls to avoid light leaks (avoid one-sided walls). For interior levels, enclose your level geometry in a sufficiently large box and bridge the loops to close the mesh.


floatsdfgi_energy =1.0🔗

The energy multiplier to use for SDFGI. Higher values will result in brighter indirect lighting and reflections. See alsosdfgi_bounce_feedback.


floatsdfgi_max_distance =204.8🔗

The maximum distance at which SDFGI is visible. Beyond this distance, environment lighting or other sources of GI such asReflectionProbe will be used as a fallback.

Note: This property is linked tosdfgi_min_cell_size andsdfgi_cascade0_distance. Changing its value will automatically change those properties as well.


floatsdfgi_min_cell_size =0.2🔗

The cell size to use for the closest SDFGI cascade (in 3D units). Lower values allow SDFGI to be more precise up close, at the cost of making SDFGI updates more demanding. This can cause stuttering when the camera moves fast. Higher values allow SDFGI to cover more ground, while also reducing the performance impact of SDFGI updates.

Note: This property is linked tosdfgi_max_distance andsdfgi_cascade0_distance. Changing its value will automatically change those properties as well.


floatsdfgi_normal_bias =1.1🔗

The normal bias to use for SDFGI probes. Increasing this value can reduce visible streaking artifacts on sloped surfaces, at the cost of increased light leaking.


floatsdfgi_probe_bias =1.1🔗

The constant bias to use for SDFGI probes. Increasing this value can reduce visible streaking artifacts on sloped surfaces, at the cost of increased light leaking.


boolsdfgi_read_sky_light =true🔗

Iftrue, SDFGI takes the environment lighting into account. This should be set tofalse for interior scenes.


boolsdfgi_use_occlusion =false🔗

Iftrue, SDFGI uses an occlusion detection approach to reduce light leaking. Occlusion may however introduce dark blotches in certain spots, which may be undesired in mostly outdoor scenes.sdfgi_use_occlusion has a performance impact and should only be enabled when needed.


SDFGIYScalesdfgi_y_scale =1🔗

The Y scale to use for SDFGI cells. Lower values will result in SDFGI cells being packed together more closely on the Y axis. This is used to balance between quality and covering a lot of vertical ground.sdfgi_y_scale should be set depending on how vertical your scene is (and how fast your camera may move on the Y axis).


Skysky🔗

TheSky resource used for thisEnvironment.


floatsky_custom_fov =0.0🔗

If set to a value greater than0.0, overrides the field of view to use for sky rendering. If set to0.0, the same FOV as the currentCamera3D is used for sky rendering.


Vector3sky_rotation =Vector3(0,0,0)🔗

The rotation to use for sky rendering.


floatssao_ao_channel_affect =0.0🔗

The screen-space ambient occlusion intensity on materials that have an AO texture defined. Values higher than0 will make the SSAO effect visible in areas darkened by AO textures.


floatssao_detail =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.


boolssao_enabled =false🔗

Iftrue, 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.

Note: SSAO is only supported in the Forward+ rendering method, not Mobile or Compatibility.


floatssao_horizon =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 the0.0-1.0 range. A value of1.0 results in no occlusion.


floatssao_intensity =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.


floatssao_light_affect =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 than0 will make the SSAO effect visible in direct light.


floatssao_power =1.5🔗

The distribution of occlusion. A higher value results in darker occlusion, similar tossao_intensity, but with a sharper falloff.


floatssao_radius =1.0🔗

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.


floatssao_sharpness =0.98🔗

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.


boolssil_enabled =false🔗

Iftrue, the screen-space indirect lighting effect is enabled. Screen space indirect lighting is a form of indirect lighting that allows diffuse light to bounce between nearby objects. Screen-space indirect lighting works very similarly to screen-space ambient occlusion, in that it only affects a limited range. It is intended to be used along with a form of proper global illumination like SDFGI orVoxelGI. Screen-space indirect lighting is not affected by individual light'sLight3D.light_indirect_energy.

Note: SSIL is only supported in the Forward+ rendering method, not Mobile or Compatibility.


floatssil_intensity =1.0🔗

The brightness multiplier for the screen-space indirect lighting effect. A higher value will result in brighter light.


floatssil_normal_rejection =1.0🔗

Amount of normal rejection used when calculating screen-space indirect lighting. Normal rejection uses the normal of a given sample point to reject samples that are facing away from the current pixel. Normal rejection is necessary to avoid light leaking when only one side of an object is illuminated. However, normal rejection can be disabled if light leaking is desirable, such as when the scene mostly contains emissive objects that emit light from faces that cannot be seen from the camera.


floatssil_radius =5.0🔗

The distance that bounced lighting can travel when using the screen space indirect lighting effect. A larger value will result in light bouncing further in a scene, but may result in under-sampling artifacts which look like long spikes surrounding light sources.


floatssil_sharpness =0.98🔗

The amount that the screen-space indirect lighting 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.


floatssr_depth_tolerance =0.2🔗

The depth tolerance for screen-space reflections.


boolssr_enabled =false🔗

Iftrue, screen-space reflections are enabled. Screen-space reflections are more accurate than reflections fromVoxelGIs orReflectionProbes, but are slower and can't reflect surfaces occluded by others.

Note: SSR is only supported in the Forward+ rendering method, not Mobile or Compatibility.


floatssr_fade_in =0.15🔗

The fade-in distance for screen-space reflections. Affects the area from the reflected material to the screen-space reflection. Only positive values are valid (negative values will be clamped to0.0).


floatssr_fade_out =2.0🔗

The fade-out distance for screen-space reflections. Affects the area from the screen-space reflection to the "global" reflection. Only positive values are valid (negative values will be clamped to0.0).


intssr_max_steps =64🔗

The maximum number of steps for screen-space reflections. Higher values are slower.


floattonemap_exposure =1.0🔗

Adjusts the brightness of values before they are provided to the tonemapper. Highertonemap_exposure values result in a brighter image. See alsotonemap_white.

Note: Values provided to the tonemapper will also be multiplied by2.0 and1.8 forTONE_MAPPER_FILMIC andTONE_MAPPER_ACES respectively to produce a similar apparent brightness asTONE_MAPPER_LINEAR.


ToneMappertonemap_mode =0🔗

The tonemapping mode to use. Tonemapping is the process that "converts" HDR values to be suitable for rendering on an LDR display. (Godot doesn't support rendering on HDR displays yet.)


floattonemap_white =1.0🔗

The white reference value for tonemapping, which indicates where bright white is located in the scale of values provided to the tonemapper. For photorealistic lighting, recommended values are between6.0 and8.0. Higher values result in less blown out highlights, but may make the scene appear lower contrast. See alsotonemap_exposure.

Note:tonemap_white is ignored when usingTONE_MAPPER_LINEAR orTONE_MAPPER_AGX.


Colorvolumetric_fog_albedo =Color(1,1,1,1)🔗

TheColor of the volumetric fog when interacting with lights. Mist and fog have an albedo close toColor(1,1,1,1) while smoke has a darker albedo.


floatvolumetric_fog_ambient_inject =0.0🔗

Scales the strength of ambient light used in the volumetric fog. A value of0.0 means that ambient light will not impact the volumetric fog.volumetric_fog_ambient_inject has a small performance cost when set above0.0.

Note: This has no visible effect ifvolumetric_fog_density is0.0 or ifvolumetric_fog_albedo is a fully black color.


floatvolumetric_fog_anisotropy =0.2🔗

The direction of scattered light as it goes through the volumetric fog. A value close to1.0 means almost all light is scattered forward. A value close to0.0 means light is scattered equally in all directions. A value close to-1.0 means light is scattered mostly backward. Fog and mist scatter light slightly forward, while smoke scatters light equally in all directions.


floatvolumetric_fog_density =0.05🔗

The baseexponential density of the volumetric fog. Set this to the lowest density you want to have globally.FogVolumes can be used to add to or subtract from this density in specific areas. Fog rendering is exponential as in real life.

A value of0.0 disables global volumetric fog while allowingFogVolumes to display volumetric fog in specific areas.

To make volumetric fog work as a volumetriclighting solution, setvolumetric_fog_density to the lowest non-zero value (0.0001) then increase lights'Light3D.light_volumetric_fog_energy to values between10000 and100000 to compensate for the very low density.


floatvolumetric_fog_detail_spread =2.0🔗

The distribution of size down the length of the froxel buffer. A higher value compresses the froxels closer to the camera and places more detail closer to the camera.


Colorvolumetric_fog_emission =Color(0,0,0,1)🔗

The emitted light from the volumetric fog. Even with emission, volumetric fog will not cast light onto other surfaces. Emission is useful to establish an ambient color. As the volumetric fog effect uses single-scattering only, fog tends to need a little bit of emission to soften the harsh shadows.


floatvolumetric_fog_emission_energy =1.0🔗

The brightness of the emitted light from the volumetric fog.


boolvolumetric_fog_enabled =false🔗

Enables the volumetric fog effect. Volumetric fog uses a screen-aligned froxel buffer to calculate accurate volumetric scattering in the short to medium range. Volumetric fog interacts withFogVolumes and lights to calculate localized and global fog. Volumetric fog uses a PBR single-scattering model based on extinction, scattering, and emission which it exposes to users as density, albedo, and emission.

Note: Volumetric fog is only supported in the Forward+ rendering method, not Mobile or Compatibility.


floatvolumetric_fog_gi_inject =1.0🔗

Scales the strength of Global Illumination used in the volumetric fog's albedo color. A value of0.0 means that Global Illumination will not impact the volumetric fog.volumetric_fog_gi_inject has a small performance cost when set above0.0.

Note: This has no visible effect ifvolumetric_fog_density is0.0 or ifvolumetric_fog_albedo is a fully black color.

Note: OnlyVoxelGI and SDFGI (sdfgi_enabled) are taken into account when usingvolumetric_fog_gi_inject. Global illumination fromLightmapGI,ReflectionProbe and SSIL (seessil_enabled) will be ignored by volumetric fog.


floatvolumetric_fog_length =64.0🔗

The distance over which the volumetric fog is computed. Increase to compute fog over a greater range, decrease to add more detail when a long range is not needed. For best quality fog, keep this as low as possible. See alsoProjectSettings.rendering/environment/volumetric_fog/volume_depth.


floatvolumetric_fog_sky_affect =1.0🔗

The factor to use when affecting the sky with volumetric fog.1.0 means that volumetric fog can fully obscure the sky. Lower values reduce the impact of volumetric fog on sky rendering, with0.0 not affecting sky rendering at all.

Note:volumetric_fog_sky_affect also affectsFogVolumes, even ifvolumetric_fog_density is0.0. If you noticeFogVolumes are disappearing when looking towards the sky, setvolumetric_fog_sky_affect to1.0.


floatvolumetric_fog_temporal_reprojection_amount =0.9🔗

The amount by which to blend the last frame with the current frame. A higher number results in smoother volumetric fog, but makes "ghosting" much worse. A lower value reduces ghosting but can result in the per-frame temporal jitter becoming visible.


boolvolumetric_fog_temporal_reprojection_enabled =true🔗

Enables temporal reprojection in the volumetric fog. Temporal reprojection blends the current frame's volumetric fog with the last frame's volumetric fog to smooth out jagged edges. The performance cost is minimal; however, it leads to movingFogVolumes andLight3Ds "ghosting" and leaving a trail behind them. When temporal reprojection is enabled, try to avoid movingFogVolumes orLight3Ds too fast. Short-lived dynamic lighting effects should haveLight3D.light_volumetric_fog_energy set to0.0 to avoid ghosting.


Method Descriptions

floatget_glow_level(idx:int)const🔗

Returns the intensity of the glow levelidx.


voidset_glow_level(idx:int, intensity:float)🔗

Sets the intensity of the glow levelidx. A value above0.0 enables the level. Each level relies on the previous level. This means that enabling higher glow levels will slow down the glow effect rendering, even if previous levels aren't enabled.


User-contributed notes

Please read theUser-contributed notes policy before submitting a comment.