Skip to content

Commit a54adaa

Browse files
author
L Sikkes
committed
Stop aliasing GetType() in Mono
1 parent 5ad4fc3 commit a54adaa

8 files changed

Lines changed: 291 additions & 74 deletions

doc/classes/Environment.xml

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,26 @@
200200
The strength that is used when blurring across the screen to generate the glow effect. This affects the distance and intensity of the blur. When using the Mobile rendering method, this should be increased to compensate for the lower dynamic range.
201201
[b]Note:[/b] [member 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.
202202
</member>
203+
<member name="pathtracing_debug_mode" type="int" setter="set_pathtracing_debug_mode" getter="get_pathtracing_debug_mode" enum="Environment.PathtracingDebugMode" default="0">
204+
Selects a debug visualization channel to display instead of the final path-traced image. Useful for inspecting individual G-buffer inputs and intermediate shading data. Set to [constant RT_DEBUG_DISABLED] to show the normal rendered result.
205+
[b]Note:[/b] Only has an effect when [member pathtracing_enabled] is [code]true[/code].
206+
</member>
207+
<member name="pathtracing_denoiser" type="int" setter="set_pathtracing_denoiser" getter="get_pathtracing_denoiser" enum="RenderingServer.PathtracingDenoiser" default="1">
208+
The denoiser used to reduce noise in the path-traced image. [constant RenderingServer.PT_DENOISER_DLSS_RAY_RECONSTRUCTION] uses NVIDIA DLSS Ray Reconstruction for high-quality temporal denoising and requires an NVIDIA RTX GPU. Use [constant RenderingServer.PT_DENOISER_NONE] to disable denoising.
209+
[b]Note:[/b] Only has an effect when [member pathtracing_enabled] is [code]true[/code].
210+
</member>
211+
<member name="pathtracing_enabled" type="bool" setter="set_pathtracing_enabled" getter="is_pathtracing_enabled" default="false">
212+
If [code]true[/code], enables hardware-accelerated path tracing for this environment. Path tracing produces physically accurate global illumination, reflections, and shadows by simulating light rays bouncing through the scene. Requires a GPU with ray tracing support.
213+
[b]Note:[/b] Path tracing is mutually exclusive with rasterization-based rendering. When enabled, features such as SDFGI, screen-space reflections, and shadow maps are bypassed.
214+
</member>
215+
<member name="pathtracing_max_bounces" type="int" setter="set_pathtracing_max_bounces" getter="get_pathtracing_max_bounces" default="3">
216+
Maximum number of times a ray is allowed to bounce off surfaces before it is terminated. Higher values produce more accurate indirect lighting and inter-reflections at the cost of GPU performance. A value of [code]0[/code] produces direct illumination only.
217+
[b]Note:[/b] Only has an effect when [member pathtracing_enabled] is [code]true[/code].
218+
</member>
219+
<member name="pathtracing_samples_per_pixel" type="int" setter="set_pathtracing_samples_per_pixel" getter="get_pathtracing_samples_per_pixel" default="1">
220+
Number of ray samples cast per pixel per frame. Higher values reduce noise but increase GPU cost proportionally. When using a temporal denoiser such as DLSS Ray Reconstruction, a low sample count (1-2) is typically sufficient since the denoiser accumulates information across frames.
221+
[b]Note:[/b] Only has an effect when [member pathtracing_enabled] is [code]true[/code].
222+
</member>
203223
<member name="reflected_light_source" type="int" setter="set_reflection_source" getter="get_reflection_source" enum="Environment.ReflectionSource" default="0">
204224
The reflected (specular) light source.
205225
</member>
@@ -460,6 +480,75 @@
460480
<constant name="GLOW_BLEND_MODE_MIX" value="4" enum="GlowBlendMode">
461481
Mixes the glow image with the scene image. Best used with [member glow_bloom] to avoid darkening the scene.
462482
</constant>
483+
<constant name="RT_DEBUG_DISABLED" value="0" enum="PathtracingDebugMode">
484+
No debug visualization. Displays the final path-traced and denoised image.
485+
</constant>
486+
<constant name="RT_DEBUG_MIRROR_REFLECTION" value="1" enum="PathtracingDebugMode">
487+
Displays the mirror (specular) reflection contribution only.
488+
</constant>
489+
<constant name="RT_DEBUG_GEOMETRY_NORMALS" value="2" enum="PathtracingDebugMode">
490+
Displays the raw per-triangle geometric normals, without any normal map applied.
491+
</constant>
492+
<constant name="RT_DEBUG_FINAL_NORMALS" value="3" enum="PathtracingDebugMode">
493+
Displays the final shading normals after applying normal maps and tangent-space transforms.
494+
</constant>
495+
<constant name="RT_DEBUG_NORMAL_MAP" value="4" enum="PathtracingDebugMode">
496+
Displays the normal map texture sample in tangent space.
497+
</constant>
498+
<constant name="RT_DEBUG_TANGENT" value="5" enum="PathtracingDebugMode">
499+
Displays the surface tangent vector at each hit point.
500+
</constant>
501+
<constant name="RT_DEBUG_BITANGENT" value="6" enum="PathtracingDebugMode">
502+
Displays the surface bitangent vector at each hit point.
503+
</constant>
504+
<constant name="RT_DEBUG_UV" value="7" enum="PathtracingDebugMode">
505+
Displays the primary UV texture coordinates as a color (red = U, green = V).
506+
</constant>
507+
<constant name="RT_DEBUG_ALBEDO" value="8" enum="PathtracingDebugMode">
508+
Displays the combined albedo (base color) of each surface.
509+
</constant>
510+
<constant name="RT_DEBUG_ORM" value="9" enum="PathtracingDebugMode">
511+
Displays the packed ORM texture (Occlusion, Roughness, Metalness in RGB channels).
512+
</constant>
513+
<constant name="RT_DEBUG_DIFFUSE_ALBEDO" value="10" enum="PathtracingDebugMode">
514+
Displays only the diffuse albedo contribution, excluding specular.
515+
</constant>
516+
<constant name="RT_DEBUG_SPECULAR_ALBEDO" value="11" enum="PathtracingDebugMode">
517+
Displays only the specular albedo (F0) contribution.
518+
</constant>
519+
<constant name="RT_DEBUG_NORMAL_ROUGHNESS" value="12" enum="PathtracingDebugMode">
520+
Displays the shading normal and roughness packed together (normal in RGB, roughness in alpha visualized as intensity).
521+
</constant>
522+
<constant name="RT_DEBUG_SPECULAR_HIT_DISTANCE" value="13" enum="PathtracingDebugMode">
523+
Displays the distance to the first specular ray hit, encoded as a grayscale value.
524+
</constant>
525+
<constant name="RT_DEBUG_METALNESS" value="14" enum="PathtracingDebugMode">
526+
Displays the metalness value of each surface as a grayscale image.
527+
</constant>
528+
<constant name="RT_DEBUG_ROUGHNESS" value="15" enum="PathtracingDebugMode">
529+
Displays the roughness value of each surface as a grayscale image.
530+
</constant>
531+
<constant name="RT_DEBUG_VIEW_NORMALS" value="16" enum="PathtracingDebugMode">
532+
Displays the shading normals transformed into view (camera) space.
533+
</constant>
534+
<constant name="RT_DEBUG_DIFFUSE_SPECULAR_SPLIT" value="17" enum="PathtracingDebugMode">
535+
Displays diffuse lighting on the left half and specular lighting on the right half of the screen.
536+
</constant>
537+
<constant name="RT_DEBUG_FRESNEL_F0" value="18" enum="PathtracingDebugMode">
538+
Displays the Fresnel F0 reflectance value for each surface.
539+
</constant>
540+
<constant name="RT_DEBUG_FRONT_BACK_FACE" value="19" enum="PathtracingDebugMode">
541+
Displays front-facing geometry in green and back-facing geometry in red. Useful for identifying incorrect face winding or double-sided materials.
542+
</constant>
543+
<constant name="RT_DEBUG_DEPTH" value="20" enum="PathtracingDebugMode">
544+
Displays the primary ray hit depth (distance from camera) as a grayscale image.
545+
</constant>
546+
<constant name="RT_DEBUG_EMISSIVE" value="21" enum="PathtracingDebugMode">
547+
Displays the emissive light contribution of each surface.
548+
</constant>
549+
<constant name="RT_DEBUG_BRDF_REJECTION" value="22" enum="PathtracingDebugMode">
550+
Displays rays that were rejected by the BRDF sampling process, useful for debugging importance sampling issues.
551+
</constant>
463552
<constant name="FOG_MODE_EXPONENTIAL" value="0" enum="FogMode">
464553
Use a physically-based fog model defined primarily by fog density.
465554
</constant>

0 commit comments

Comments
 (0)