Merge pull request #41629 from JFonS/disable_baked_lights

Disable lights for objects with baked lighting
This commit is contained in:
Juan Linietsky
2020-10-19 14:12:50 -03:00
committed by GitHub
15 changed files with 87 additions and 18 deletions

View File

@@ -2153,6 +2153,17 @@
Sets whether to use a dual paraboloid or a cubemap for the shadow map. Dual paraboloid is faster but may suffer from artifacts. Equivalent to [member OmniLight.omni_shadow_mode].
</description>
</method>
<method name="light_set_bake_mode">
<return type="void">
</return>
<argument index="0" name="light" type="RID">
</argument>
<argument index="1" name="bake_mode" type="int" enum="VisualServer.LightBakeMode">
</argument>
<description>
Sets the bake mode for this light, see [enum LightBakeMode] for options. The bake mode affects how the light will be baked in [BakedLightmap]s and [GIProbe]s.
</description>
</method>
<method name="light_set_color">
<return type="void">
</return>
@@ -2251,7 +2262,7 @@
<argument index="1" name="enabled" type="bool">
</argument>
<description>
Sets whether GI probes capture light information from this light.
Sets whether GI probes capture light information from this light. [i]Deprecated method.[/i] Use [method light_set_bake_mode] instead. This method is only kept for compatibility reasons and calls [method light_set_bake_mode] internally, setting the bake mode to [constant LIGHT_BAKE_DISABLED] or [constant LIGHT_BAKE_INDIRECT] depending on the given parameter.
</description>
</method>
<method name="lightmap_capture_create">
@@ -4518,6 +4529,12 @@
<constant name="LIGHT_PARAM_MAX" value="15" enum="LightParam">
Represents the size of the [enum LightParam] enum.
</constant>
<constant name="LIGHT_BAKE_DISABLED" value="0" enum="LightBakeMode">
</constant>
<constant name="LIGHT_BAKE_INDIRECT" value="1" enum="LightBakeMode">
</constant>
<constant name="LIGHT_BAKE_ALL" value="2" enum="LightBakeMode">
</constant>
<constant name="LIGHT_OMNI_SHADOW_DUAL_PARABOLOID" value="0" enum="LightOmniShadowMode">
Use a dual paraboloid shadow map for omni lights.
</constant>