diff options
Diffstat (limited to 'doc/classes/RenderingServer.xml')
-rw-r--r-- | doc/classes/RenderingServer.xml | 324 |
1 files changed, 204 insertions, 120 deletions
diff --git a/doc/classes/RenderingServer.xml b/doc/classes/RenderingServer.xml index 19a75c8515..13e5470a56 100644 --- a/doc/classes/RenderingServer.xml +++ b/doc/classes/RenderingServer.xml @@ -13,6 +13,7 @@ Similarly, in 2D, a canvas is needed to draw all canvas items. In 3D, all visible objects are comprised of a resource and an instance. A resource can be a mesh, a particle system, a light, or any other 3D object. In order to be visible resources must be attached to an instance using [method instance_set_base]. The instance must also be attached to the scenario using [method instance_set_scenario] in order to be visible. In 2D, all visible objects are some form of canvas item. In order to be visible, a canvas item needs to be the child of a canvas attached to a viewport, or it needs to be the child of another canvas item that is eventually attached to the canvas. + [b]Headless mode:[/b] Starting the engine with the [code]--headless[/code] [url=$DOCS_URL/tutorials/editor/command_line_tutorial.html]command line argument[/url] disables all rendering and window management functions. Most functions from [RenderingServer] will return dummy values in this case. </description> <tutorials> <link title="Optimization using Servers">$DOCS_URL/tutorials/performance/using_servers.html</link> @@ -21,34 +22,32 @@ <method name="bake_render_uv2"> <return type="Image[]" /> <param index="0" name="base" type="RID" /> - <param index="1" name="material_overrides" type="Array" /> + <param index="1" name="material_overrides" type="RID[]" /> <param index="2" name="image_size" type="Vector2i" /> <description> </description> </method> - <method name="camera_create"> + <method name="camera_attributes_create"> <return type="RID" /> <description> - Creates a camera and adds it to the RenderingServer. It can be accessed with the RID that is returned. This RID will be used in all [code]camera_*[/code] RenderingServer functions. + Creates a camera attributes object and adds it to the RenderingServer. It can be accessed with the RID that is returned. This RID will be used in all [code]camera_attributes_[/code] RenderingServer functions. Once finished with your RID, you will want to free the RID using the RenderingServer's [method free_rid] static method. </description> </method> - <method name="camera_effects_create"> - <return type="RID" /> - <description> - </description> - </method> - <method name="camera_effects_set_custom_exposure"> + <method name="camera_attributes_set_auto_exposure"> <return type="void" /> - <param index="0" name="camera_effects" type="RID" /> + <param index="0" name="camera_attributes" type="RID" /> <param index="1" name="enable" type="bool" /> - <param index="2" name="exposure" type="float" /> + <param index="2" name="min_sensitivity" type="float" /> + <param index="3" name="max_sensitivity" type="float" /> + <param index="4" name="speed" type="float" /> + <param index="5" name="scale" type="float" /> <description> </description> </method> - <method name="camera_effects_set_dof_blur"> + <method name="camera_attributes_set_dof_blur"> <return type="void" /> - <param index="0" name="camera_effects" type="RID" /> + <param index="0" name="camera_attributes" type="RID" /> <param index="1" name="far_enable" type="bool" /> <param index="2" name="far_distance" type="float" /> <param index="3" name="far_transition" type="float" /> @@ -59,20 +58,46 @@ <description> </description> </method> - <method name="camera_effects_set_dof_blur_bokeh_shape"> + <method name="camera_attributes_set_dof_blur_bokeh_shape"> <return type="void" /> <param index="0" name="shape" type="int" enum="RenderingServer.DOFBokehShape" /> <description> </description> </method> - <method name="camera_effects_set_dof_blur_quality"> + <method name="camera_attributes_set_dof_blur_quality"> <return type="void" /> <param index="0" name="quality" type="int" enum="RenderingServer.DOFBlurQuality" /> <param index="1" name="use_jitter" type="bool" /> <description> </description> </method> - <method name="camera_set_camera_effects"> + <method name="camera_attributes_set_exposure"> + <return type="void" /> + <param index="0" name="camera_attributes" type="RID" /> + <param index="1" name="multiplier" type="float" /> + <param index="2" name="normalization" type="float" /> + <description> + Sets the exposure values that will be used by the renderers. The normalization amount is used to bake a given Exposure Value (EV) into rendering calculations to reduce the dynamic range of the scene. + The normalization factor can be calculated from exposure value (EV100) as follows: + [codeblock] + func get_exposure_normalization(float ev100): + return 1.0 / (pow(2.0, ev100) * 1.2) + [/codeblock] + The exposure value can be calculated from aperture (in f-stops), shutter speed (in seconds), and sensitivity (in ISO) as follows: + [codeblock] + func get_exposure(float aperture, float shutter_speed, float sensitivity): + return log2((aperture * aperture) / shutterSpeed * (100.0 / sensitivity)) + [/codeblock] + </description> + </method> + <method name="camera_create"> + <return type="RID" /> + <description> + Creates a camera and adds it to the RenderingServer. It can be accessed with the RID that is returned. This RID will be used in all [code]camera_*[/code] RenderingServer functions. + Once finished with your RID, you will want to free the RID using the RenderingServer's [method free_rid] static method. + </description> + </method> + <method name="camera_set_camera_attributes"> <return type="void" /> <param index="0" name="camera" type="RID" /> <param index="1" name="effects" type="RID" /> @@ -103,7 +128,7 @@ <param index="3" name="z_near" type="float" /> <param index="4" name="z_far" type="float" /> <description> - Sets camera to use frustum projection. This mode allows adjusting the [code]offset[/code] argument to create "tilted frustum" effects. + Sets camera to use frustum projection. This mode allows adjusting the [param offset] argument to create "tilted frustum" effects. </description> </method> <method name="camera_set_orthogonal"> @@ -176,6 +201,16 @@ <description> </description> </method> + <method name="canvas_item_add_lcd_texture_rect_region"> + <return type="void" /> + <param index="0" name="item" type="RID" /> + <param index="1" name="rect" type="Rect2" /> + <param index="2" name="texture" type="RID" /> + <param index="3" name="src_rect" type="Rect2" /> + <param index="4" name="modulate" type="Color" /> + <description> + </description> + </method> <method name="canvas_item_add_line"> <return type="void" /> <param index="0" name="item" type="RID" /> @@ -464,6 +499,14 @@ Sets if the [CanvasItem] uses its parent's material. </description> </method> + <method name="canvas_item_set_visibility_layer"> + <return type="void" /> + <param index="0" name="item" type="RID" /> + <param index="1" name="visibility_layer" type="int" /> + <description> + Sets the rendering visibility layer associated with this [CanvasItem]. Only [Viewport] nodes with a matching rendering mask will render this [CanvasItem]. + </description> + </method> <method name="canvas_item_set_visibility_notifier"> <return type="void" /> <param index="0" name="item" type="RID" /> @@ -966,7 +1009,8 @@ <method name="environment_set_bg_energy"> <return type="void" /> <param index="0" name="env" type="RID" /> - <param index="1" name="energy" type="float" /> + <param index="1" name="multiplier" type="float" /> + <param index="2" name="exposure_value" type="float" /> <description> Sets the intensity of the background color. </description> @@ -990,6 +1034,7 @@ <param index="6" name="height" type="float" /> <param index="7" name="height_density" type="float" /> <param index="8" name="aerial_perspective" type="float" /> + <param index="9" name="sky_affect" type="float" /> <description> </description> </method> @@ -1133,11 +1178,6 @@ <param index="1" name="tone_mapper" type="int" enum="RenderingServer.EnvironmentToneMapper" /> <param index="2" name="exposure" type="float" /> <param index="3" name="white" type="float" /> - <param index="4" name="auto_exposure" type="bool" /> - <param index="5" name="min_luminance" type="float" /> - <param index="6" name="max_luminance" type="float" /> - <param index="7" name="auto_exp_speed" type="float" /> - <param index="8" name="auto_exp_grey" type="float" /> <description> Sets the variables to be used with the "tonemap" post-process effect. See [Environment] for more details. </description> @@ -1157,6 +1197,7 @@ <param index="10" name="temporal_reprojection" type="bool" /> <param index="11" name="temporal_reprojection_amount" type="float" /> <param index="12" name="ambient_inject" type="float" /> + <param index="13" name="sky_affect" type="float" /> <description> </description> </method> @@ -1172,7 +1213,7 @@ <param index="0" name="size" type="int" /> <param index="1" name="depth" type="int" /> <description> - Sets the resolution of the volumetric fog's froxel buffer. [code]size[/code] is modified by the screen's aspect ratio and then used to set the width and height of the buffer. While [code]depth[/code] is directly used to set the depth of the buffer. + Sets the resolution of the volumetric fog's froxel buffer. [param size] is modified by the screen's aspect ratio and then used to set the width and height of the buffer. While [param depth] is directly used to set the depth of the buffer. </description> </method> <method name="fog_volume_create"> @@ -1240,6 +1281,13 @@ <description> </description> </method> + <method name="get_shader_parameter_list" qualifiers="const"> + <return type="Dictionary[]" /> + <param index="0" name="shader" type="RID" /> + <description> + Returns the parameters of a shader. + </description> + </method> <method name="get_test_cube"> <return type="RID" /> <description> @@ -1290,48 +1338,48 @@ <return type="void" /> <param index="0" name="half_resolution" type="bool" /> <description> - If [code]half_resolution[/code] is [code]true[/code], renders [VoxelGI] and SDFGI ([member Environment.sdfgi_enabled]) buffers at halved resolution (e.g. 960×540 when the viewport size is 1920×1080). This improves performance significantly when VoxelGI or SDFGI is enabled, at the cost of artifacts that may be visible on polygon edges. The loss in quality becomes less noticeable as the viewport resolution increases. [LightmapGI] rendering is not affected by this setting. See also [member ProjectSettings.rendering/global_illumination/gi/use_half_resolution]. + If [param half_resolution] is [code]true[/code], renders [VoxelGI] and SDFGI ([member Environment.sdfgi_enabled]) buffers at halved resolution (e.g. 960×540 when the viewport size is 1920×1080). This improves performance significantly when VoxelGI or SDFGI is enabled, at the cost of artifacts that may be visible on polygon edges. The loss in quality becomes less noticeable as the viewport resolution increases. [LightmapGI] rendering is not affected by this setting. See also [member ProjectSettings.rendering/global_illumination/gi/use_half_resolution]. </description> </method> - <method name="global_shader_uniform_add"> + <method name="global_shader_parameter_add"> <return type="void" /> <param index="0" name="name" type="StringName" /> - <param index="1" name="type" type="int" enum="RenderingServer.GlobalShaderUniformType" /> + <param index="1" name="type" type="int" enum="RenderingServer.GlobalShaderParameterType" /> <param index="2" name="default_value" type="Variant" /> <description> </description> </method> - <method name="global_shader_uniform_get" qualifiers="const"> + <method name="global_shader_parameter_get" qualifiers="const"> <return type="Variant" /> <param index="0" name="name" type="StringName" /> <description> </description> </method> - <method name="global_shader_uniform_get_list" qualifiers="const"> + <method name="global_shader_parameter_get_list" qualifiers="const"> <return type="PackedStringArray" /> <description> </description> </method> - <method name="global_shader_uniform_get_type" qualifiers="const"> - <return type="int" enum="RenderingServer.GlobalShaderUniformType" /> + <method name="global_shader_parameter_get_type" qualifiers="const"> + <return type="int" enum="RenderingServer.GlobalShaderParameterType" /> <param index="0" name="name" type="StringName" /> <description> </description> </method> - <method name="global_shader_uniform_remove"> + <method name="global_shader_parameter_remove"> <return type="void" /> <param index="0" name="name" type="StringName" /> <description> </description> </method> - <method name="global_shader_uniform_set"> + <method name="global_shader_parameter_set"> <return type="void" /> <param index="0" name="name" type="StringName" /> <param index="1" name="value" type="Variant" /> <description> </description> </method> - <method name="global_shader_uniform_set_override"> + <method name="global_shader_parameter_set_override"> <return type="void" /> <param index="0" name="name" type="StringName" /> <param index="1" name="value" type="Variant" /> @@ -1355,7 +1403,7 @@ <return type="bool" /> <param index="0" name="feature" type="String" /> <description> - Returns [code]true[/code] if the OS supports a certain feature. Features might be [code]s3tc[/code], [code]etc[/code], and [code]etc2[/code]. + Returns [code]true[/code] if the OS supports a certain [param feature]. Features might be [code]s3tc[/code], [code]etc[/code], and [code]etc2[/code]. </description> </method> <method name="instance_attach_object_instance_id"> @@ -1391,22 +1439,22 @@ Once finished with your RID, you will want to free the RID using the RenderingServer's [method free_rid] static method. </description> </method> - <method name="instance_geometry_get_shader_uniform" qualifiers="const"> + <method name="instance_geometry_get_shader_parameter" qualifiers="const"> <return type="Variant" /> <param index="0" name="instance" type="RID" /> <param index="1" name="parameter" type="StringName" /> <description> </description> </method> - <method name="instance_geometry_get_shader_uniform_default_value" qualifiers="const"> + <method name="instance_geometry_get_shader_parameter_default_value" qualifiers="const"> <return type="Variant" /> <param index="0" name="instance" type="RID" /> <param index="1" name="parameter" type="StringName" /> <description> </description> </method> - <method name="instance_geometry_get_shader_uniform_list" qualifiers="const"> - <return type="Array" /> + <method name="instance_geometry_get_shader_parameter_list" qualifiers="const"> + <return type="Dictionary[]" /> <param index="0" name="instance" type="RID" /> <description> </description> @@ -1460,7 +1508,7 @@ Sets a material that will override the material for all surfaces on the mesh associated with this instance. Equivalent to [member GeometryInstance3D.material_override]. </description> </method> - <method name="instance_geometry_set_shader_uniform"> + <method name="instance_geometry_set_shader_parameter"> <return type="void" /> <param index="0" name="instance" type="RID" /> <param index="1" name="parameter" type="StringName" /> @@ -1474,9 +1522,9 @@ <param index="1" name="transparency" type="float" /> <description> Sets the transparency for the given geometry instance. Equivalent to [member GeometryInstance3D.transparency]. - A transparency of [code]0.0[/code] is fully opaque, while [code]1.0[/code] is fully transparent. Values greater than [code]0.0[/code] (exclusive) will force the geometry's materials to go through the transparent pipeline, which is slower to render and can exhibit rendering issues due to incorrect transparency sorting. However, unlike using a transparent material, setting [code]transparency[/code] to a value greater than [code]0.0[/code] (exclusive) will [i]not[/i] disable shadow rendering. + A transparency of [code]0.0[/code] is fully opaque, while [code]1.0[/code] is fully transparent. Values greater than [code]0.0[/code] (exclusive) will force the geometry's materials to go through the transparent pipeline, which is slower to render and can exhibit rendering issues due to incorrect transparency sorting. However, unlike using a transparent material, setting [param transparency] to a value greater than [code]0.0[/code] (exclusive) will [i]not[/i] disable shadow rendering. In spatial shaders, [code]1.0 - transparency[/code] is set as the default value of the [code]ALPHA[/code] built-in. - [b]Note:[/b] [code]transparency[/code] is clamped between [code]0.0[/code] and [code]1.0[/code], so this property cannot be used to make transparent materials more opaque than they originally are. + [b]Note:[/b] [param transparency] is clamped between [code]0.0[/code] and [code]1.0[/code], so this property cannot be used to make transparent materials more opaque than they originally are. </description> </method> <method name="instance_geometry_set_visibility_range"> @@ -1581,7 +1629,7 @@ </description> </method> <method name="instances_cull_aabb" qualifiers="const"> - <return type="Array" /> + <return type="PackedInt64Array" /> <param index="0" name="aabb" type="AABB" /> <param index="1" name="scenario" type="RID" /> <description> @@ -1590,8 +1638,8 @@ </description> </method> <method name="instances_cull_convex" qualifiers="const"> - <return type="Array" /> - <param index="0" name="convex" type="Array" /> + <return type="PackedInt64Array" /> + <param index="0" name="convex" type="Plane[]" /> <param index="1" name="scenario" type="RID" /> <description> Returns an array of object IDs intersecting with the provided convex shape. Only visual 3D nodes are considered, such as [MeshInstance3D] or [DirectionalLight3D]. Use [method @GlobalScope.instance_from_id] to obtain the actual nodes. A scenario RID must be provided, which is available in the [World3D] you want to query. This forces an update for all resources queued to update. @@ -1599,7 +1647,7 @@ </description> </method> <method name="instances_cull_ray" qualifiers="const"> - <return type="Array" /> + <return type="PackedInt64Array" /> <param index="0" name="from" type="Vector3" /> <param index="1" name="to" type="Vector3" /> <param index="2" name="scenario" type="RID" /> @@ -1757,6 +1805,14 @@ <description> </description> </method> + <method name="lightmap_set_baked_exposure_normalization"> + <return type="void" /> + <param index="0" name="lightmap" type="RID" /> + <param index="1" name="baked_exposure" type="float" /> + <description> + Used to inform the renderer what exposure normalization value was used while baking the lightmap. This value will be used and modulated at run time to ensure that the lightmap maintains a consistent level of exposure even if the scene-wide exposure normalization is changed at run time. For more information see [method camera_attributes_set_exposure]. + </description> + </method> <method name="lightmap_set_probe_bounds"> <return type="void" /> <param index="0" name="lightmap" type="RID" /> @@ -1801,7 +1857,7 @@ <param index="1" name="longitudes" type="int" /> <param index="2" name="radius" type="float" /> <description> - Returns a mesh of a sphere with the given amount of horizontal and vertical subdivisions. + Returns a mesh of a sphere with the given number of horizontal and vertical subdivisions. </description> </method> <method name="material_create"> @@ -1959,7 +2015,7 @@ </description> </method> <method name="mesh_surface_get_blend_shape_arrays" qualifiers="const"> - <return type="Array" /> + <return type="Array[]" /> <param index="0" name="mesh" type="RID" /> <param index="1" name="surface" type="int" /> <description> @@ -2655,7 +2711,7 @@ The scenario is the 3D world that all the visual instances exist in. </description> </method> - <method name="scenario_set_camera_effects"> + <method name="scenario_set_camera_attributes"> <return type="void" /> <param index="0" name="scenario" type="RID" /> <param index="1" name="effects" type="RID" /> @@ -2693,7 +2749,7 @@ <param index="2" name="scale" type="bool" /> <param index="3" name="use_filter" type="bool" default="true" /> <description> - Sets a boot image. The color defines the background color. If [code]scale[/code] is [code]true[/code], the image will be scaled to fit the screen size. If [code]use_filter[/code] is [code]true[/code], the image will be scaled with linear interpolation. If [code]use_filter[/code] is [code]false[/code], the image will be scaled with nearest-neighbor interpolation. + Sets a boot image. The color defines the background color. If [param scale] is [code]true[/code], the image will be scaled to fit the screen size. If [param use_filter] is [code]true[/code], the image will be scaled with linear interpolation. If [param use_filter] is [code]false[/code], the image will be scaled with nearest-neighbor interpolation. </description> </method> <method name="set_debug_generate_wireframes"> @@ -2724,28 +2780,21 @@ Returns a shader's code. </description> </method> - <method name="shader_get_default_texture_param" qualifiers="const"> + <method name="shader_get_default_texture_parameter" qualifiers="const"> <return type="RID" /> <param index="0" name="shader" type="RID" /> - <param index="1" name="param" type="StringName" /> + <param index="1" name="name" type="StringName" /> <param index="2" name="index" type="int" default="0" /> <description> Returns a default texture from a shader searched by name. - [b]Note:[/b] If the sampler array is used use [code]index[/code] to access the specified texture. + [b]Note:[/b] If the sampler array is used use [param index] to access the specified texture. </description> </method> - <method name="shader_get_param_default" qualifiers="const"> + <method name="shader_get_parameter_default" qualifiers="const"> <return type="Variant" /> <param index="0" name="shader" type="RID" /> - <param index="1" name="param" type="StringName" /> - <description> - </description> - </method> - <method name="shader_get_shader_uniform_list" qualifiers="const"> - <return type="Dictionary[]" /> - <param index="0" name="shader" type="RID" /> + <param index="1" name="name" type="StringName" /> <description> - Returns the parameters of a shader. </description> </method> <method name="shader_set_code"> @@ -2755,15 +2804,15 @@ <description> </description> </method> - <method name="shader_set_default_texture_param"> + <method name="shader_set_default_texture_parameter"> <return type="void" /> <param index="0" name="shader" type="RID" /> - <param index="1" name="param" type="StringName" /> + <param index="1" name="name" type="StringName" /> <param index="2" name="texture" type="RID" /> <param index="3" name="index" type="int" default="0" /> <description> Sets a shader's default texture. Overwrites the texture given by name. - [b]Note:[/b] If the sampler array is used use [code]index[/code] to access the specified texture. + [b]Note:[/b] If the sampler array is used use [param index] to access the specified texture. </description> </method> <method name="shader_set_path_hint"> @@ -2975,6 +3024,14 @@ <description> </description> </method> + <method name="texture_get_rd_texture" qualifiers="const"> + <return type="RID" /> + <param index="0" name="texture" type="RID" /> + <param index="1" name="srgb" type="bool" default="false" /> + <description> + Returns a texture [RID] that can be used with [RenderingDevice]. + </description> + </method> <method name="texture_proxy_create"> <return type="RID" /> <param index="0" name="base" type="RID" /> @@ -3039,7 +3096,7 @@ <param index="1" name="rect" type="Rect2" default="Rect2(0, 0, 0, 0)" /> <param index="2" name="screen" type="int" default="0" /> <description> - Copies the viewport to a region of the screen specified by [code]rect[/code]. If [method viewport_set_render_direct_to_screen] is [code]true[/code], then the viewport does not use a framebuffer and the contents of the viewport are rendered directly to screen. However, note that the root viewport is drawn last, therefore it will draw over the screen. Accordingly, you must set the root viewport to an area that does not cover the area that you have attached this viewport to. + Copies the viewport to a region of the screen specified by [param rect]. If [method viewport_set_render_direct_to_screen] is [code]true[/code], then the viewport does not use a framebuffer and the contents of the viewport are rendered directly to screen. However, note that the root viewport is drawn last, therefore it will draw over the screen. Accordingly, you must set the root viewport to an area that does not cover the area that you have attached this viewport to. For example, you can set the root viewport to not render at all with the following code: FIXME: The method seems to be non-existent. [codeblocks] @@ -3102,6 +3159,14 @@ If [code]true[/code], sets the viewport active, else sets it inactive. </description> </method> + <method name="viewport_set_canvas_cull_mask"> + <return type="void" /> + <param index="0" name="viewport" type="RID" /> + <param index="1" name="canvas_cull_mask" type="int" /> + <description> + Sets the rendering mask associated with this [Viewport]. Only [CanvasItem] nodes with a matching rendering visibility layer will be rendered by this [Viewport]. + </description> + </method> <method name="viewport_set_canvas_stacking"> <return type="void" /> <param index="0" name="viewport" type="RID" /> @@ -3110,7 +3175,7 @@ <param index="3" name="sublayer" type="int" /> <description> Sets the stacking order for a viewport's canvas. - [code]layer[/code] is the actual canvas layer, while [code]sublayer[/code] specifies the stacking order of the canvas among those in the same layer. + [param layer] is the actual canvas layer, while [param sublayer] specifies the stacking order of the canvas among those in the same layer. </description> </method> <method name="viewport_set_canvas_transform"> @@ -3198,12 +3263,20 @@ <description> </description> </method> - <method name="viewport_set_msaa"> + <method name="viewport_set_msaa_2d"> <return type="void" /> <param index="0" name="viewport" type="RID" /> <param index="1" name="msaa" type="int" enum="RenderingServer.ViewportMSAA" /> <description> - Sets the anti-aliasing mode. See [enum ViewportMSAA] for options. + Sets the multisample anti-aliasing mode for 2D/Canvas. See [enum ViewportMSAA] for options. + </description> + </method> + <method name="viewport_set_msaa_3d"> + <return type="void" /> + <param index="0" name="viewport" type="RID" /> + <param index="1" name="msaa" type="int" enum="RenderingServer.ViewportMSAA" /> + <description> + Sets the multisample anti-aliasing mode for 3D. See [enum ViewportMSAA] for options. </description> </method> <method name="viewport_set_occlusion_culling_build_quality"> @@ -3462,6 +3535,14 @@ <description> </description> </method> + <method name="voxel_gi_set_baked_exposure_normalization"> + <return type="void" /> + <param index="0" name="voxel_gi" type="RID" /> + <param index="1" name="baked_exposure" type="float" /> + <description> + Used to inform the renderer what exposure normalization value was used while baking the voxel gi. This value will be used and modulated at run time to ensure that the voxel gi maintains a consistent level of exposure even if the scene-wide exposure normalization is changed at run time. For more information see [method camera_attributes_set_exposure]. + </description> + </method> <method name="voxel_gi_set_bias"> <return type="void" /> <param index="0" name="voxel_gi" type="RID" /> @@ -3774,64 +3855,65 @@ Is a spot light. </constant> <constant name="LIGHT_PARAM_ENERGY" value="0" enum="LightParam"> - The light's energy. + The light's energy multiplier. </constant> <constant name="LIGHT_PARAM_INDIRECT_ENERGY" value="1" enum="LightParam"> The light's indirect energy multiplier (final indirect energy is [constant LIGHT_PARAM_ENERGY] * [constant LIGHT_PARAM_INDIRECT_ENERGY]). </constant> - <constant name="LIGHT_PARAM_SPECULAR" value="2" enum="LightParam"> + <constant name="LIGHT_PARAM_VOLUMETRIC_FOG_ENERGY" value="2" enum="LightParam"> + The light's volumetric fog energy multiplier (final volumetric fog energy is [constant LIGHT_PARAM_ENERGY] * [constant LIGHT_PARAM_VOLUMETRIC_FOG_ENERGY]). + </constant> + <constant name="LIGHT_PARAM_SPECULAR" value="3" enum="LightParam"> The light's influence on specularity. </constant> - <constant name="LIGHT_PARAM_RANGE" value="3" enum="LightParam"> + <constant name="LIGHT_PARAM_RANGE" value="4" enum="LightParam"> The light's range. </constant> - <constant name="LIGHT_PARAM_SIZE" value="4" enum="LightParam"> + <constant name="LIGHT_PARAM_SIZE" value="5" enum="LightParam"> The size of the light when using spot light or omni light. The angular size of the light when using directional light. </constant> - <constant name="LIGHT_PARAM_ATTENUATION" value="5" enum="LightParam"> + <constant name="LIGHT_PARAM_ATTENUATION" value="6" enum="LightParam"> The light's attenuation. </constant> - <constant name="LIGHT_PARAM_SPOT_ANGLE" value="6" enum="LightParam"> + <constant name="LIGHT_PARAM_SPOT_ANGLE" value="7" enum="LightParam"> The spotlight's angle. </constant> - <constant name="LIGHT_PARAM_SPOT_ATTENUATION" value="7" enum="LightParam"> + <constant name="LIGHT_PARAM_SPOT_ATTENUATION" value="8" enum="LightParam"> The spotlight's attenuation. </constant> - <constant name="LIGHT_PARAM_SHADOW_MAX_DISTANCE" value="8" enum="LightParam"> + <constant name="LIGHT_PARAM_SHADOW_MAX_DISTANCE" value="9" enum="LightParam"> Max distance that shadows will be rendered. </constant> - <constant name="LIGHT_PARAM_SHADOW_SPLIT_1_OFFSET" value="9" enum="LightParam"> + <constant name="LIGHT_PARAM_SHADOW_SPLIT_1_OFFSET" value="10" enum="LightParam"> Proportion of shadow atlas occupied by the first split. </constant> - <constant name="LIGHT_PARAM_SHADOW_SPLIT_2_OFFSET" value="10" enum="LightParam"> + <constant name="LIGHT_PARAM_SHADOW_SPLIT_2_OFFSET" value="11" enum="LightParam"> Proportion of shadow atlas occupied by the second split. </constant> - <constant name="LIGHT_PARAM_SHADOW_SPLIT_3_OFFSET" value="11" enum="LightParam"> + <constant name="LIGHT_PARAM_SHADOW_SPLIT_3_OFFSET" value="12" enum="LightParam"> Proportion of shadow atlas occupied by the third split. The fourth split occupies the rest. </constant> - <constant name="LIGHT_PARAM_SHADOW_FADE_START" value="12" enum="LightParam"> + <constant name="LIGHT_PARAM_SHADOW_FADE_START" value="13" enum="LightParam"> Proportion of shadow max distance where the shadow will start to fade out. </constant> - <constant name="LIGHT_PARAM_SHADOW_NORMAL_BIAS" value="13" enum="LightParam"> + <constant name="LIGHT_PARAM_SHADOW_NORMAL_BIAS" value="14" enum="LightParam"> Normal bias used to offset shadow lookup by object normal. Can be used to fix self-shadowing artifacts. </constant> - <constant name="LIGHT_PARAM_SHADOW_BIAS" value="14" enum="LightParam"> + <constant name="LIGHT_PARAM_SHADOW_BIAS" value="15" enum="LightParam"> Bias the shadow lookup to fix self-shadowing artifacts. </constant> - <constant name="LIGHT_PARAM_SHADOW_PANCAKE_SIZE" value="15" enum="LightParam"> + <constant name="LIGHT_PARAM_SHADOW_PANCAKE_SIZE" value="16" enum="LightParam"> Sets the size of the directional shadow pancake. The pancake offsets the start of the shadow's camera frustum to provide a higher effective depth resolution for the shadow. However, a high pancake size can cause artifacts in the shadows of large objects that are close to the edge of the frustum. Reducing the pancake size can help. Setting the size to [code]0[/code] turns off the pancaking effect. </constant> - <constant name="LIGHT_PARAM_SHADOW_OPACITY" value="16" enum="LightParam"> + <constant name="LIGHT_PARAM_SHADOW_OPACITY" value="17" enum="LightParam"> The light's shadow opacity. Values lower than [code]1.0[/code] make the light appear through shadows. This can be used to fake global illumination at a low performance cost. </constant> - <constant name="LIGHT_PARAM_SHADOW_BLUR" value="17" enum="LightParam"> + <constant name="LIGHT_PARAM_SHADOW_BLUR" value="18" enum="LightParam"> Blurs the edges of the shadow. Can be used to hide pixel artifacts in low resolution shadow maps. A high value can make shadows appear grainy and can cause other unwanted artifacts. Try to keep as near default as possible. </constant> - <constant name="LIGHT_PARAM_SHADOW_VOLUMETRIC_FOG_FADE" value="18" enum="LightParam"> - </constant> <constant name="LIGHT_PARAM_TRANSMITTANCE_BIAS" value="19" enum="LightParam"> </constant> - <constant name="LIGHT_PARAM_MAX" value="20" enum="LightParam"> + <constant name="LIGHT_PARAM_MAX" value="21" enum="LightParam"> Represents the size of the [enum LightParam] enum. </constant> <constant name="LIGHT_BAKE_DISABLED" value="0" enum="LightBakeMode"> @@ -4519,9 +4601,11 @@ </constant> <constant name="CANVAS_GROUP_MODE_DISABLED" value="0" enum="CanvasGroupMode"> </constant> - <constant name="CANVAS_GROUP_MODE_OPAQUE" value="1" enum="CanvasGroupMode"> + <constant name="CANVAS_GROUP_MODE_CLIP_ONLY" value="1" enum="CanvasGroupMode"> + </constant> + <constant name="CANVAS_GROUP_MODE_CLIP_AND_DRAW" value="2" enum="CanvasGroupMode"> </constant> - <constant name="CANVAS_GROUP_MODE_TRANSPARENT" value="2" enum="CanvasGroupMode"> + <constant name="CANVAS_GROUP_MODE_TRANSPARENT" value="3" enum="CanvasGroupMode"> </constant> <constant name="CANVAS_LIGHT_MODE_POINT" value="0" enum="CanvasLightMode"> </constant> @@ -4557,63 +4641,63 @@ <constant name="CANVAS_OCCLUDER_POLYGON_CULL_COUNTER_CLOCKWISE" value="2" enum="CanvasOccluderPolygonCullMode"> Culling of the canvas occluder is counterclockwise. </constant> - <constant name="GLOBAL_VAR_TYPE_BOOL" value="0" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_BOOL" value="0" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_BVEC2" value="1" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_BVEC2" value="1" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_BVEC3" value="2" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_BVEC3" value="2" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_BVEC4" value="3" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_BVEC4" value="3" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_INT" value="4" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_INT" value="4" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_IVEC2" value="5" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_IVEC2" value="5" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_IVEC3" value="6" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_IVEC3" value="6" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_IVEC4" value="7" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_IVEC4" value="7" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_RECT2I" value="8" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_RECT2I" value="8" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_UINT" value="9" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_UINT" value="9" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_UVEC2" value="10" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_UVEC2" value="10" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_UVEC3" value="11" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_UVEC3" value="11" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_UVEC4" value="12" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_UVEC4" value="12" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_FLOAT" value="13" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_FLOAT" value="13" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_VEC2" value="14" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_VEC2" value="14" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_VEC3" value="15" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_VEC3" value="15" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_VEC4" value="16" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_VEC4" value="16" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_COLOR" value="17" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_COLOR" value="17" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_RECT2" value="18" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_RECT2" value="18" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_MAT2" value="19" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_MAT2" value="19" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_MAT3" value="20" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_MAT3" value="20" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_MAT4" value="21" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_MAT4" value="21" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_TRANSFORM_2D" value="22" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_TRANSFORM_2D" value="22" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_TRANSFORM" value="23" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_TRANSFORM" value="23" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_SAMPLER2D" value="24" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_SAMPLER2D" value="24" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_SAMPLER2DARRAY" value="25" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_SAMPLER2DARRAY" value="25" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_SAMPLER3D" value="26" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_SAMPLER3D" value="26" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_SAMPLERCUBE" value="27" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_SAMPLERCUBE" value="27" enum="GlobalShaderParameterType"> </constant> - <constant name="GLOBAL_VAR_TYPE_MAX" value="28" enum="GlobalShaderUniformType"> + <constant name="GLOBAL_VAR_TYPE_MAX" value="28" enum="GlobalShaderParameterType"> </constant> <constant name="RENDERING_INFO_TOTAL_OBJECTS_IN_FRAME" value="0" enum="RenderingInfo"> </constant> |