Commit Graph

3554 Commits

Author SHA1 Message Date
Stuart Carnie 0043c950f6 Rendering: Fix priority sort table 2026-05-04 06:50:46 +10:00
Thaddeus Crews f059d64e3d Merge pull request #118968 from CookieBadger/area-light-lut-textures
Fix GPU validation errors due to area light LUT format
2026-04-30 10:58:09 -05:00
Thaddeus Crews 179899680b Merge pull request #118198 from viksl/volumetric-fog-nan-handling-reprojected
Filter and sanitize volumetric fog to stop invalid values flooding the screen with black pixels through temporal reprojection.
2026-04-30 10:58:06 -05:00
LiveTrower 936d67b7c7 Fix area light texture color conversion 2026-04-28 10:54:57 -06:00
Thaddeus Crews 393d854f7a Merge pull request #118962 from Chaosus/shader_fix_texture_query_lod
Prevent `textureQueryLod` function from usage in vertex shader
2026-04-28 09:02:53 -05:00
CookieBadger 7c532acc09 change LTC lookup table texture format to RGBAF and set p_8bit_dst to true in gaussian_blur 2026-04-27 21:35:46 +02:00
Thaddeus Crews 75444feae7 Merge pull request #118857 from LiveTrower/clearcoat-reflection-fixes
Fix and clean up clearcoat reflection probe process
2026-04-27 12:05:47 -05:00
Chaosus 618e959afc Prevent textureQueryLod function from usage in vertex shader 2026-04-26 13:39:00 +03:00
LiveTrower 4b94f459f4 Fix and cleanup clearcoat reflection probe process 2026-04-24 16:04:41 -06:00
Thaddeus Crews 4d794c4ffb Merge pull request #118629 from Kaleb-Reid/fix-bilinear-fallback
Fall back to bilinear scaling when setting FSR or MetalFX Temporal on Mobile
2026-04-24 15:43:31 -05:00
Kaleb Reid 57466fd247 Fall back to bilinear scaling when setting FSR or MetalFX Temporal on Mobile 2026-04-22 13:52:46 -07:00
LiveTrower 5dac818f77 Fix clearcoat intensity for area lights 2026-04-22 13:07:53 -06:00
Thaddeus Crews 0e25644655 Merge pull request #118796 from deralmas/gotta-go-wrap
Buildsystem: Simplify `format_buffer` utility method
2026-04-22 09:58:29 -05:00
Thaddeus Crews 835e2dcbba Merge pull request #118809 from blueskythlikesclouds/fix-clearcoat-half-ddx-ddy
Fix SPIR-V validation error in Mobile clearcoat code.
2026-04-21 16:46:14 -05:00
Thaddeus Crews dc12c5f48e Merge pull request #118752 from dsnopek/reflection-probe-rt-error
Fix `Parameter "rt" is null` when toggling `ReflectionProbe` visibility
2026-04-21 16:46:02 -05:00
Dery Almas e4dcf1d852 Buildsystem: Simplify format_buffer utility method
This method is used to generate headers for embedding files into the binary
(think about the new `#embed` feature in C23 and C++26).

While the stringification step itself was plenty fast, it then proceeded
to wrap everything using the `textwrap` module. `textwrap` is *very*
slow, as it's apparently optimized for human text.

This patch reimplements the wrapping logic using a simple regex,
resulting in a tremendous speed improvement (~6x), and switches to `map`
for the stringification itself (thanks Rémi!)

It also removes a (practically) unused argument, `initial_indent`.

The generated files are pretty much the same, with a tiny difference in
line length (for some reason the old logic overshot the requested line
length)
2026-04-21 23:18:42 +02:00
Thaddeus Crews 06fc4f8165 Merge pull request #113413 from Kaleb-Reid/fix-aa-bilinear-scaling
Fix screen-space AA when scaling using bilinear filtering
2026-04-21 08:48:00 -05:00
Skyth 52e8eb4bbb Fix SPIR-V validation error in Mobile clearcoat code. 2026-04-21 13:58:40 +03:00
David Snopek 0c00e99d39 Fix Parameter "rt" is null when toggling ReflectionProbe visibility 2026-04-19 08:45:54 -05:00
Kaleb Reid 08cb31b4d1 Fix screen-space AA when upscaling using bilinear filtering 2026-04-15 15:33:26 -07:00
Kaleb Reid f973e3e346 Remove p_ and add r_ prefixes to argument names 2026-04-15 13:47:15 -07:00
Rémi Verschelde cc212fb90a Merge pull request #117788 from kleonc/canvas_item_shader_generate_sdf_on_using_normal
Generate SDF texture on `texture_sdf_normal` usage
2026-04-15 12:40:50 +02:00
Thaddeus Crews f94bbfc07c Merge pull request #118353 from Chaosus/shader_subgroups
Allow to define more than one subgroup level in shader material
2026-04-14 07:11:08 -05:00
Thaddeus Crews 473b449df7 Merge pull request #118405 from Fahien/fahien/random-raytracing-fixes
Random raytracing fixes
2026-04-14 07:11:07 -05:00
Thaddeus Crews 7ce1853014 Merge pull request #108219 from CookieBadger/area-light-integration
Add Rectangular Area Light Source
2026-04-14 07:10:56 -05:00
Antonio Caggiano 24f9ac81ba raytracing: Fix shader binding table record alignment
Raytracing shader binding table records are addressed through Vulkan
alignment rules that distinguish between the raw shader group handle size,
the per-record handle alignment, and the base alignment required for SBT
region addresses.

The previous layout treated the shader group handle size as the record
stride everywhere. This worked only on devices where the handle size
already satisfied all relevant alignment requirements. It broke down once
multiple ray generation shaders were placed in the same SBT: selecting a
non-zero raygen index advanced the raygen region address by the raw handle
size, which could produce an address that was not aligned to the required
shader group base alignment.

Separate the SBT layout into the appropriate strides:

- ray generation records use a base-aligned stride, since selecting a
  raygen shader changes the SBT region start address for the dispatch.
- miss and hit records use the handle-aligned shader group stride, since
  their regions start at a base-aligned address and individual records are
  selected through the region stride.

This keeps the CPU-side SBT population and the dispatch-time SBT regions
using the same layout, so shader group handles are written to the same
aligned slots that Vulkan later addresses.
2026-04-13 23:24:17 +02:00
Thaddeus Crews b042e9688e Merge pull request #118519 from blueskythlikesclouds/fix-max-instance-computation
Fix max instance computation when creating vertex arrays.
2026-04-13 15:52:16 -05:00
Thaddeus Crews cee489f46e Merge pull request #118242 from BlueCube3310/draw-tex-set-type
Properly set `drawable_type` property in RenderingServer's `DrawableTexture`
2026-04-13 15:52:15 -05:00
Skyth 6b1ddf3c62 Fix max instance computation when creating vertex arrays. 2026-04-13 17:38:42 +03:00
Antonio Caggiano b4e802c79d raytracing: Check error when updating hit SBT 2026-04-13 13:57:34 +02:00
Antonio Caggiano dd5fe138a0 raytracing: Add device address flag to SBT buffer 2026-04-13 13:57:34 +02:00
Clay John ba7f91ccc8 Remove is_discardable property from several textures
The property is causing issues on NVidia devices
2026-04-10 16:00:28 -07:00
Thaddeus Crews 9268bc73a0 Merge pull request #117619 from BastiaanOlij/fix_117303
Fix assymmetrical rendering of reflections in SDFGI
2026-04-10 10:32:35 -05:00
Skyth 83d2b84a51 Refactor raytracing pipelines. 2026-04-10 14:21:02 +03:00
Thaddeus Crews bed5d2774a Merge pull request #118239 from blueskythlikesclouds/rd-disallow-zero-sizes-in-copies
Forbid zero size values in RD texture copy method.
2026-04-09 17:41:18 -05:00
Thaddeus Crews daa913af63 Merge pull request #117672 from Chaosus/shader_pp_ops
Fix a few operators in shader preprocessor expression
2026-04-09 17:41:16 -05:00
Thaddeus Crews 27799eb871 Merge pull request #117847 from Nolkaloid/keyword_icon
Add  keyword code completion option
2026-04-09 17:41:09 -05:00
Chaosus 5c667de60c Allow to define more than one subgroup level in shader material 2026-04-09 19:15:19 +03:00
Thaddeus Crews 967b56efec Merge pull request #118317 from clayjohn/sky-shader-fallback
Ensure that sky shader automatic mode consistently uses the fallback
2026-04-08 17:00:43 -05:00
Nolkaloid 1d165e7ea9 Add keyword code completion option 2026-04-08 20:04:08 +02:00
clayjohn 63c49cc668 Ensure that sky shader automatic mode consistently uses the fallback
This is necessary so that the proper backing textures can be allocated for the sky shader
2026-04-08 10:49:18 -07:00
Thaddeus Crews b6f86739b6 Merge pull request #109911 from TCROC/fix-particles-moving-timescale-0
Fix particles moving when timescale is 0
2026-04-08 09:25:25 -05:00
Thaddeus Crews ccdb6fdb29 Merge pull request #118120 from romgerman/visual-profiler-folding
Add folding to the Visual Profiler tree
2026-04-08 09:25:21 -05:00
Thaddeus Crews fdc9f35119 Merge pull request #117148 from blueskythlikesclouds/rt-api-adjustments
Raytracing API adjustments.
2026-04-06 13:02:27 -05:00
Skyth e7519d4849 Forbid zero size values in RD texture copy method. 2026-04-06 14:33:18 +03:00
BlueCube3310 7ba643bdcf Properly set drawable_type property in RenderingServer's DrawableTexture 2026-04-06 13:11:49 +02:00
Altay Evren Özsan d18e225ba5 Added math constants to texture-blit
Fixes #118144

Fixed an issue where texture-blit shader was failing to compile when using some math constants because the code was incorrectly passing name strings into the shader
2026-04-05 22:45:50 +03:00
viksl 2248544daa Filtering out invalid values from density and fog textures.
Added clamps for 16 bit float range (textures are 16 bit) to avoid overflow - particularly needed due to large values from attenuation.

Normalizing couple vectors are now done through a new safe_normalize function since some vectors can have 0 length which leads to zero division.
2026-04-04 15:55:28 +02:00
German 0d08515a5b Add folding to the Visual Profiler tree 2026-04-04 14:43:54 +03:00
CookieBadger 7b7bd1dcea Add AreaLight3D 2026-04-04 01:37:10 +02:00