Ricardo Buring
56fc0fd175
CPUParticles2D - Add ability to follow physics interpolated target
...
Allows a non-interpolated particle system to closely follow an interpolated target without tracking ahead of the target, by performing fixed timestep interpolation on the particle system global transform, and using this for emission.
Co-authored-by: lawnjelly <lawnjelly@gmail.com>
2025-01-24 14:13:20 +01:00
Stuart Carnie
663917449b
2D: Fix `CanvasTexture` rendering when updating channels
2025-01-24 07:01:37 +11:00
Florent Guiocheau
d08ff57148
Fix peter-panning with default spotlight
2025-01-22 17:05:04 +01:00
Thaddeus Crews
0d4696b472
Merge pull request #101515 from allenwp/agx-negative-optimizations
...
Optimize AgX tonemapper's handling of negative values
2025-01-20 10:05:38 -06:00
yesfish
860a6ab9ac
fix source_color default value
2025-01-16 16:07:25 +00:00
Matias N. Goldberg
7b2f1e1d09
Fix union order to simplify empty initializers
...
This is a followup to PR #101344 (commit
0e06eb80bc ).
Some of them were not an issue because Godot was initializing all
members, but they were "fixed" just in case since it could become a
problem in the future.
Valgrind was specifically complaining about HashMapData &
GlobalPipelineData.
2025-01-14 19:05:01 -03:00
Rémi Verschelde
85b066aa78
Merge pull request #99455 from Bonkahe/IndirectMultimeshImplementation
...
Add indirect draw functionality to `MultiMesh`
2025-01-14 15:05:42 +01:00
thimenesup
3d92f406b2
Implement Buffer Device Address for Rendering Device Vulkan and DirectX12
2025-01-13 22:43:29 -08:00
Allen Pestaluky
c5cf73a2e7
Optimize AgX tonemapper's handling of negative values
...
This change improves performance of the AgX tonemapper by allowing two matrix multiplications to be combined into one. This comes at the cost of loss of color information that could be correctly interpreted as positive RGB values in the Rec. 2020 color space. Additionally, an insignificant amount of error is intentionally introduced to the input color value to prevent the need for a second max function call before log2. The final negative color clipping has been removed to allow the tonemapper to return negative RGB values, similar to other tonemappers in Godot.
2025-01-13 17:35:35 -05:00
David House
e6daec9cf8
Added indirect drawing functionality to MultiMesh
...
Update doc/classes/RenderingServer.xml
Co-Authored-By: Micky <66727710+Mickeon@users.noreply.github.com>
2025-01-13 14:51:51 -06:00
Rémi Verschelde
133db1fd60
Merge pull request #92089 from QbieShay/qbe/particle_seek
...
Implement particle seek request and seed options.
2025-01-13 20:21:28 +01:00
QbieShay
e9eb0b6082
Implemented tools around particles seed randomization.
...
The purpose of this code is to expose the necessary
functions for users and engine devs to develop tooling
for properly timing and seeking inside particles.
Co-authored-by: Hugo Locurcio <hugo.locurcio@hugo.pro>
Co-authored-by: A Thousand Ships <96648715+AThousandShips@users.noreply.github.com>
Co-authored-by: Tomasz Chabora <kobewi4e@gmail.com>
Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2025-01-11 16:31:24 +01:00
Allen Pestaluky
77ddaaaa91
Fix AgX sigmoid contrast curve approximation
...
This changes the polynomial function so that a lower input always results in a lower output and vice-versa. Additionally, the new function returns a value that is much closer to 1.0 when given an input of 1.0.
2025-01-10 18:17:38 -05:00
Rémi Verschelde
139619ca0c
Merge pull request #101355 from akien-mga/style-clang-format-InsertBraces
...
Style: Enable clang-format's `InsertBraces` config
2025-01-10 23:06:15 +01:00
Rémi Verschelde
3014eec40d
Merge pull request #99407 from devloglogan/rec-resolution
...
Allow using custom `Rect2i` for rendering with OpenXR
2025-01-10 23:05:46 +01:00
Rémi Verschelde
469808f66b
Merge pull request #101112 from clayjohn/skyrd-fov
...
Ensure Sky with custom fov has correction matrix applied to it in RD renderers
2025-01-09 20:51:26 +01:00
Rémi Verschelde
5240e60509
Merge pull request #101344 from DarioSamo/union-order-fix
...
Fix union order to simplify empty initializers.
2025-01-09 17:07:23 +01:00
Rémi Verschelde
03c83cea1e
Style: Enable clang-format's `InsertBraces` config
...
This was part of our style guide since we started using clang-format
but the feature was only added in clang-format 15, and we hadn't
noticed it yet.
2025-01-09 16:46:51 +01:00
devloglogan
e7f6b7ea0b
Allow using custom Rect2i for rendering with OpenXR
2025-01-09 09:46:15 -06:00
Dario
0e06eb80bc
Fix union order to simplify empty initializers.
2025-01-09 10:39:13 -03:00
Dario
1af1edf60c
Fix duplicated spec constant on SPIR-V reflection.
2025-01-09 10:27:38 -03:00
Rémi Verschelde
a659548946
Merge pull request #101298 from stuartcarnie/rendering_server
...
Renderer: Minor optimisation when running `gl_compatibility` mode
2025-01-08 18:20:11 +01:00
Rémi Verschelde
21721ae344
Merge pull request #87260 from Calinou/tonemap-add-agx
...
Add AgX tonemapper option to Environment
2025-01-08 18:20:03 +01:00
Stuart Carnie
abd0e6990c
Renderer: minor optimisation when running `gl_compatibility` mode
2025-01-08 09:43:35 -07:00
Hugo Locurcio
084e84be78
Add AgX tonemapper option to Environment
...
Technical implementation notes:
- Moved linearization step to before the outset matrix is applied and
changed polynomial contrast curve approximation.
- This does *not* implement Blender's chroma rotation to address hue shift.
This hue rotation was found to have a significant performance impact.
- Improved performance by combining the AgX outset matrix with the Rec 2020 matrix.
Co-authored-by: Allen Pestaluky <allenpestaluky@gmail.com>
Co-authored-by: Clay John <claynjohn@gmail.com>
2025-01-08 17:01:16 +01:00
Aarni Koskela
f134769506
Fix various typos
...
* Add TODO notes for typos that should be fixed for 5.0
Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2025-01-08 14:47:42 +02:00
Rémi Verschelde
a0c3798fba
Merge pull request #101210 from clayjohn/headless-export-shader
...
Save instance and global uniform data in RenderingServerDummy
2025-01-07 23:18:09 +01:00
Rémi Verschelde
21fdf1678a
Merge pull request #101193 from clayjohn/FSR-y-aspect
...
Correct aspect ratio used in FSR2 calculations
2025-01-07 23:18:04 +01:00
Rémi Verschelde
084da581be
Merge pull request #100241 from lander-vr/reflection-probe-priority
...
Add priority-based blending to reflection probes.
2025-01-07 10:14:38 +01:00
clayjohn
49846cf79a
Save instance and global uniform data in RenderingServerDummy so they can be exported with headless exports
2025-01-06 19:25:11 -08:00
clayjohn
25a9b04ecc
Correct aspect ratio used in FSR2 calculations to remove a source of depth-based ghosting
2025-01-06 14:00:58 -08:00
Rémi Verschelde
0f76ee4688
Merge pull request #101110 from clayjohn/light2d-rect-fix
...
Update Light2D `rect_cache` even when not using shadows.
2025-01-06 22:49:01 +01:00
Rémi Verschelde
62ea2f76b4
Merge pull request #101069 from DarioSamo/rd-thread-safety-comment
...
Remove TODO from RenderingDevice regarding thread safety.
2025-01-06 22:48:28 +01:00
Rémi Verschelde
ddb01528ea
Merge pull request #100956 from Geometror/dont-toast-shader-code
...
Don't toast shader code
2025-01-06 22:48:05 +01:00
Stuart Carnie
11dc4f2e5e
Metal: Add MetalFX upscaling support
...
Co-authored-by: Hugo Locurcio <hugo.locurcio@hugo.pro>
2025-01-06 06:03:18 -07:00
Hendrik Brucker
c0eae103e2
Don't toast shader code
2025-01-05 13:19:45 +01:00
clayjohn
96ce5c0001
Ensure Sky with custom fov has correction matrix applied to it in RD renderers
2025-01-03 17:11:02 -08:00
clayjohn
7e8facc526
Update Light2D rect_cache even when not using shadows.
...
This also cleans up how the rect_cache is updated to make the steps more clear
2025-01-03 16:17:58 -08:00
Dario
dea083864b
Remove TODO from RenderingDevice regarding thread safety.
2025-01-03 10:26:44 -03:00
Rémi Verschelde
21e6671740
Merge pull request #100937 from Repiteo/style/clang-format-sync
...
Style: Enforce `AllowShortFunctionsOnASingleLine`
2025-01-03 00:49:44 +01:00
Rémi Verschelde
19a7b466c2
Merge pull request #100848 from BlueCube3310/astc-improvements
...
astcenc: Misc improvements and optimizations
2025-01-03 00:49:22 +01:00
Rémi Verschelde
0d710da96c
Merge pull request #98554 from Calinou/add-property-hint-ranges
...
Add more property hint ranges for project settings
2025-01-03 00:47:59 +01:00
Thaddeus Crews
e06d83860d
Style: Enforce `AllowShortFunctionsOnASingleLine`
2025-01-02 10:09:41 -06:00
BlueCube3310
6f363b989a
astcenc: Misc improvements and optimizations
2024-12-31 14:25:14 +01:00
Thaddeus Crews
13992bbf7b
Merge pull request #100766 from stuartcarnie/metal_crash
...
Metal: Fix crash when uniform set is empty for slot binding mode
2024-12-30 08:58:51 -06:00
Thaddeus Crews
58b48a934e
Merge pull request #100859 from StaydMcMuffin/scene-shaders-user-normal-fix
...
Fix User-supplied Normals Being Ignored
2024-12-30 08:58:47 -06:00
Thaddeus Crews
888883d608
Merge pull request #100862 from Flarkk/fix_100850
...
Fix regression with shadows when light range is 0 or close
2024-12-30 08:58:12 -06:00
Florent Guiocheau
c9632d0eb6
Fix regression with shadows when light range is 0 or close
2024-12-28 11:40:54 +01:00
Stayd
40f17127ef
Fix User-supplied Normals Being Ignored
...
Moves the initialization of the geo_normal value
to after the user shader code, so that the normal
supplied by the user is actually used instead of
the interpolated vertex normal.
2024-12-27 13:01:20 -07:00
Stuart Carnie
b643599749
Metal: Fix crash when uniform set is empty for slot binding mode
...
Co-authored-by: Hugo Locurcio <hugo.locurcio@hugo.pro>
2024-12-24 07:53:21 -07:00
A Thousand Ships
a1846b27ea
Improve use of `Ref.is_null/valid`
...
Use `is_null` over `!is_valid` and vice versa.
2024-12-23 16:35:02 -05:00
landervr
1637736c20
ReflectionProbe priority
2024-12-23 21:58:11 +01:00
Hugo Locurcio
62c17911ea
Add more property hint ranges for project settings
...
- Tweak property hint ranges for some networking settings to ensure
the minimum values don't break the debugger entirely.
- Ensure shader time rollover is set to at least 1, as 0 causes a division by
zero to occur.
All relevant project settings are now covered by a range hint.
2024-12-23 18:22:32 +01:00
Rémi Verschelde
f7d6924afb
Merge pull request #100677 from clayjohn/light2d-cull
...
Properly transform light rect and occluder rect to perform Light2D culling in canvas space
2024-12-22 00:10:12 +01:00
clayjohn
30801af298
Properly transform light rect and occluder rect to perform light2d culling in canvas space
2024-12-20 16:58:02 -07:00
Rémi Verschelde
6e23de0aa6
Merge pull request #100653 from stuartcarnie/remove_moltenvk_hack
...
Rendering: MoltenVK hack is no longer required, as bug was fixed.
2024-12-20 23:57:27 +01:00
Rémi Verschelde
87855e04ad
Merge pull request #100643 from ze2j/follow_up_of_array_mesh_surface_remove
...
Follow-up of `ArrayMesh::surface_remove` addition
2024-12-20 23:57:20 +01:00
Stuart Carnie
9344a29f0e
Rendering: MoltenVK hack is no longer required, as bug was fixed.
...
Original issue: https://github.com/godotengine/godot/pull/51679#issuecomment-976900929
And related fix in SPIRV-Cross: https://github.com/KhronosGroup/SPIRV-Cross/issues/2046
2024-12-20 06:38:42 -07:00
Yufeng Ying
e88e30c273
Remove unused headers in servers.
...
Co-authored-by: bruvzg <7645683+bruvzg@users.noreply.github.com>
2024-12-20 18:51:01 +08:00
ze2j
97b093617d
Follow-up of ArrayMesh::surface_remove addition
2024-12-20 10:53:43 +01:00
Thaddeus Crews
e51ab56f9a
Merge pull request #100593 from Namey5/lightmapgi-null-sky-crash
...
LightmapGI: Fix crash during baking when sky is null
2024-12-19 20:00:14 -06:00
Thaddeus Crews
1536e0e236
Merge pull request #100441 from StaydMcMuffin/scene-shaders-tbn-fixes
...
Scene Shaders - TBN Vector Fixes
2024-12-19 19:59:58 -06:00
Thaddeus Crews
b715fabd70
Merge pull request #76371 from ze2j/array_mesh_surface_remove
...
Add `ArrayMesh::surface_remove`
2024-12-19 19:59:56 -06:00
Thaddeus Crews
2fcd8223e8
Merge pull request #99538 from Geometror/lightmap-gi-transparent-surface
...
Add transparency support for LightmapGI
2024-12-19 19:59:52 -06:00
Thaddeus Crews
4665faaaa9
Merge pull request #100427 from Namey5/fog-sky-luminance
...
Separate sky luminance and brightness calculations for consistent fog
2024-12-19 19:59:50 -06:00
Thaddeus Crews
41b468f961
Merge pull request #100544 from Namey5/sdfgi-sky-rotation
...
Support custom sky rotation in SDFGI
2024-12-19 19:59:46 -06:00
Thaddeus Crews
0b2596a319
Merge pull request #100399 from Fahien/fahien/resource-usage-to-string
...
Convert resource usage to string
2024-12-19 19:59:40 -06:00
Thaddeus Crews
d3e5b62ea2
Merge pull request #99230 from paddy-exe/instance_uniforms_compatability_renderer
...
Implement 2D instance uniforms
2024-12-19 19:59:37 -06:00
Alex Threlfo
e4fd2f003f
Support custom sky rotation in SDFGI
2024-12-20 11:26:28 +11:00
Alex Threlfo
5f617663aa
fix: separate sky luminance and user brightness calculations around fog
2024-12-20 11:25:11 +11:00
clayjohn
793d065f8b
Avoid allocating instance buffer for PointLight2D shadows when there are no instances.
...
Also avoid the render loop if there are no occluders. We still have to open the render pass to do a clear though.
2024-12-19 09:45:51 -08:00
Antonio Caggiano
b6e5b4dde7
Convert resource usage to string
...
Improve error message by converting resource usage values to a
human-readable string.
2024-12-19 17:08:01 +01:00
Alex Threlfo
31add2602a
LightmapGI: fix crash during baking when sky is null
2024-12-19 16:16:33 +11:00
Hendrik Brucker
a3525bc015
Add transparency support for LightmapGI
...
Co-authored-by: Guerro323 <kaltobattle@gmail.com>
2024-12-18 19:36:16 +01:00
kobewi
ceefc0d38a
Implement 2D instance shader parameters
...
Co-authored-by: kobewi <kobewi4e@gmail.com>
Co-authored-by: yesfish <huwpascoe@users.noreply.github.com>
Co-authored-by: Álex Román Núñez <eirexe123@gmail.com>
2024-12-17 23:59:16 +01:00
Rémi Verschelde
190ae9f9dc
Merge pull request #100302 from clayjohn/light2d-optimize
...
Optimize PointLight2D shadow rendering by reducing draw calls and RD state changes
2024-12-17 22:59:54 +01:00
clayjohn
7c61252dd7
Optimize PointLight2D shadow rendering by reducing draw calls and RD state changes.
...
This dramatically reduces the CPU time spent on rendering shadows for PointLight2Ds
2024-12-17 07:41:09 -08:00
Rémi Verschelde
d60c0e21a6
Merge pull request #88313 from wagnerfs/run-time-anisotropic-filtering
...
Allow changing the anisotropic filter level at run-time per Viewport
2024-12-17 16:18:38 +01:00
Rémi Verschelde
d701bc0032
Merge pull request #83917 from Calinou/directionallight3d-add-specular
...
Implement per-light Specular property in DirectionalLight3D
2024-12-17 16:18:29 +01:00
Stayd
ed0e3d7da8
Scene Shaders - TBN Fixes
...
Fixes two errors related to the normal, tangent,
and bitangent vectors, namely normals not always
being inverted on backfaces, and normalization
being reversed from what MikkTSpace expects.
2024-12-16 22:36:23 -07:00
Andrew_Shobbrook
e42def12d0
Implement per-light Specular property in DirectionalLight3D
2024-12-16 19:18:18 +01:00
Alex Threlfo
34ebec3748
fix: crash in scenes with more than 8 shadowed directional lights
2024-12-15 19:13:07 +11:00
Rémi Verschelde
ffe53cba3c
Merge pull request #100374 from hpvb/fix-rendering-ubsan
...
Fix ubsan reported errors in rendering
2024-12-14 18:25:46 +01:00
Rémi Verschelde
e271b2ca08
Merge pull request #99145 from dsnopek/xr-lock-camera
...
XR: Allow locking the camera to the `XROrigin3D` for benchmarking or automated testing
2024-12-14 18:25:21 +01:00
Thaddeus Crews
dc5f1b7a28
Merge pull request #100319 from Flarkk/fix_light_shadow_range
...
Fix shadows of long range `OmniLight3D` and `SpotLight3D`
2024-12-13 16:19:39 -06:00
Thaddeus Crews
9ecdeb3723
Merge pull request #98747 from tetrapod00/standardize-renderer-strings
...
Standardize terms for renderers in error strings
2024-12-13 16:19:37 -06:00
Thaddeus Crews
6594a6364e
Merge pull request #100213 from DarioSamo/pipeline-hash-map-thread-safety
...
Improve thread-safety of pipeline hash map.
2024-12-13 16:19:34 -06:00
Thaddeus Crews
9f0c6231c7
Merge pull request #100236 from Flarkk/fix_spot_clustering
...
Fix wide `SpotLight3D` clustering
2024-12-13 16:19:26 -06:00
Thaddeus Crews
f2c8f17906
Merge pull request #100325 from hpvb/fix-rendering-alignment
...
Fix several ubsan reported misaligned accesses
2024-12-13 16:19:20 -06:00
HP van Braam
062d74bb9c
Fix ubsan reported errors in rendering
...
This allows the TPS demo to run without an ubsan reports from any of the
rendering code.
2024-12-13 21:27:37 +01:00
HP van Braam
e674379764
Fix several ubsan reported misaligned accesses
...
These misaligned accesses are shown in all of our CI hooks. It turned
out to not be difficult to fix.
It is likely that this will improve performance for aarch64.
2024-12-13 15:32:35 +01:00
Florent Guiocheau
02f05cf0ac
Fix wide angle spotlight clustering
2024-12-13 11:28:42 +01:00
clayjohn
356fa37f89
Small fixups for the new reflection probe blending
2024-12-12 17:29:21 -08:00
Thaddeus Crews
bfc66f0608
Merge pull request #100282 from devloglogan/motion-vectors-openxr
...
Add renderer motion vectors API for use with OpenXR
2024-12-12 16:13:36 -06:00
Thaddeus Crews
7c015a768f
Merge pull request #99958 from lander-vr/reflection-probe-blend-property
...
Add Blend Distance property to ReflectionProbe
2024-12-12 16:13:32 -06:00
Thaddeus Crews
b7501d219c
Merge pull request #100322 from darksylinc/matias-tf-comment-fix
...
Fix grammar / spelling in comments
2024-12-12 16:13:25 -06:00
Matias N. Goldberg
a1b44ec7a7
Fix grammar / spelling in comments
...
Minor fixes for changes introduced in #99257 that could not be fixed in
time as the PR needed to be expedited.
2024-12-12 12:47:08 -03:00
Florent Guiocheau
5125adf40b
Fix large range point lights shadows
2024-12-12 15:37:38 +01:00
Rémi Verschelde
562dd1ad85
Merge pull request #100305 from clayjohn/directional-light-2d-mask
...
Remove positional light mask from directional lights in Canvas Item shaders.
2024-12-12 14:10:24 +01:00
Rémi Verschelde
0e5c337453
Merge pull request #85653 from BlueCube3310/lightmap-gi-shadowmask
...
Implement LightmapGI shadowmasks
2024-12-12 14:09:30 +01:00