Commit Graph

85 Commits

Author SHA1 Message Date
Haoyu Qiu 9e1121a18c Add missing period for sentences in classref 2024-09-20 19:33:32 +08:00
Matias N. Goldberg 59d0422dcd Disable extra memory tracking by default
PR #90993 added several debugging utilities.

Among them, advanced memory tracking through the use of custom
allocators and VK_EXT_device_memory_report.

However as issue #95967 reveals, it is dangerous to leave it on by
default because drivers (or even the Vulkan loader) can too easily
accidentally break custom allocators by allocating memory through std
malloc but then request us to deallocate it (or viceversa).

This PR fixes the following problems:
 - Adds --extra-gpu-memory-tracking cmd line argument
 - Adds missing enum entries to
RenderingContextDriverVulkan::VkTrackedObjectType
 - Adds RenderingDevice::get_driver_and_device_memory_report
    - GDScript users can easily check via print(
RenderingServer.get_rendering_device().get_driver_and_device_memory_report()
)
- Uses get_driver_and_device_memory_report on device lost for appending
further info.

Fixes #95967
2024-08-24 20:52:39 -03:00
Matias N. Goldberg 364f916f3f
Add debug utilities for Vulkan
Features:
- Debug-only tracking of objects by type. See
get_driver_allocs_by_object_type et al.
 - Debug-only Breadcrumb info for debugging GPU crashes and device lost
 - Performance report per frame from get_perf_report
- Some VMA calls had to be modified in order to insert the necessary
memory callbacks

Functionality marked as "debug-only" is only available in debug or dev
builds.

Misc fixes:
 - Early break optimization in RenderingDevice::uniform_set_create

============================

The work was performed by collaboration of TheForge and Google. I am
merely splitting it up into smaller PRs and cleaning it up.
2024-08-21 23:48:08 +02:00
BlueCube3310 a20960bce4 Fix texture compression descriptions in RenderingDevice docs 2024-07-15 15:19:02 +02:00
Rémi Verschelde 9cba6ec216
Merge pull request #89491 from thimenesup/compute_dispatch_indirect
Expose bindings to compute dispatch indirect of rendering device
2024-04-09 10:42:22 +02:00
thimenesup 8017c8cf21 Expose bindings to compute dispatch indirect rendering device 2024-04-08 20:46:53 +02:00
Rémi Verschelde 6f6e8b15ce
Merge pull request #87082 from Mickeon/documentation-RenderingDevice-dynamic_state
Add descriptions to a few RenderingDevice's PipelineDynamicStateFlags
2024-04-08 11:19:42 +02:00
Micky f9a758772a Update many Deprecated/Experimental descriptions for consistency 2024-02-17 21:33:12 +01:00
Danil Alexeev af28f87791
Documentation: Add support for deprecated/experimental messages 2024-02-15 15:59:50 +03:00
Dario 73eff10c76 Finish splitting functionality of the Vulkan and D3D12 backends into RenderingDeviceDriver. 2024-02-12 10:02:18 -03:00
Micky 967a121c8b Add descriptions to a few RenderingDevice's PipelineDynamicStateFlags 2024-01-11 17:39:31 +01:00
Dario 80eacf1b7a Fix incorrect mapping of initial action as clear region continue to clear. 2024-01-09 22:03:21 -03:00
Dario cc4d39b0c1 Acyclic Command Graph for RenderingDevice.
Adds a new system to automatically reorder commands, perform layout transitions and insert synchronization barriers based on the commands issued to RenderingDevice.
2024-01-08 14:54:56 -03:00
Septian d3e7b8c8a8 Fix various typos in documentation 2024-01-05 15:47:58 +07:00
Pedro J. Estébanez 12a519bae2 Split RenderingDevice into API-agnostic and RenderingDeviceDriver parts
Credit and thanks to @bruzvg for multiple build fixes, update of 3rd-party items and MinGW support.

Co-authored-by: bruvzg <7645683+bruvzg@users.noreply.github.com>
2023-12-20 19:18:08 +01:00
detomon 48c2012dc2 Fix required parameter values for 2D textures in `RenderingDevice.texture_clear()` 2023-09-29 16:14:31 +02:00
Shawn Wallace b12ed82c04 Expose texture_create_from_extension to GDExtension 2023-09-23 16:57:12 -04:00
ARez bd4d43023d Add missing RenderingDevice method descriptions 2023-08-29 12:32:29 +02:00
Hugo Locurcio 469c462b76
Add missing tutorials to documentation classes 2023-08-19 20:29:24 +02:00
Haoyu Qiu 097c849395 Fix various typos in classref 2023-08-04 16:29:55 +08:00
Yuri Sizov cc1ee3e599 Merge pull request #79911 from BastiaanOlij/fix_barrier_breakage
Add exceptions for breakage introduced in RD barriers
2023-08-01 17:25:40 +02:00
Yuri Sizov 1c40263665 Merge pull request #79606 from clayjohn/ShaderRD-compilation-groups
Shader rd compilation groups
2023-08-01 17:25:16 +02:00
Bastiaan Olij 10f796dae3 Add exceptions for breakage introduced in RD barriers and prevent future breakage 2023-07-28 14:21:34 +10:00
Bastiaan Olij 63d6e9c557 Add custom texture create function 2023-07-26 20:46:34 +10:00
clayjohn e970f5249c Add Shader compile groups to RD Shader system
This allows us to specify a subset of variants to compile at load time and conditionally other variants later.

This works seamlessly with shader caching.

Needed to ensure that users only pay the cost for variants they use
2023-07-21 16:42:30 +02:00
Septian 2857b91385 Fix many typos in documentation 2023-07-19 19:56:06 +07:00
Bastiaan Olij a22f495a3c Split raster barrier into vertex and fragment barrier 2023-07-15 12:30:32 +10:00
Rémi Verschelde 81064cc239
Doctool: Remove version attribute from XML header
We don't use that info for anything, and it generates unnecessary diffs
every time we bump the minor version (and CI failures if we forget to
sync some files from opt-in modules (mono, text_server_fb).
2023-07-06 10:08:21 +02:00
Rémi Verschelde 346f1ab86b
Bump version to 4.2-dev
Keep on waitin'
2023-07-05 22:07:03 +02:00
Danil Alexeev eb391d3302
Display `BitField[Enum]` in docs to distinguish from `Enum` 2023-06-15 17:23:02 +03:00
Bastiaan Olij 6dd47e232b Expose RD::texture_native_handle 2023-06-14 09:58:08 +10:00
Hugo Locurcio 0f82a0f569
Document the InitialAction enum in RenderingDevice
This also improves the documentation for the FinalAction enum,
and fixes an incorrect comment in the RenderingDevice header.
2023-06-08 03:54:38 +02:00
RedworkDE 42ca35cfd7 Fix more issues with code tags in class reference 2023-05-29 15:46:34 +02:00
Rémi Verschelde 3e6a731904
Merge pull request #76418 from reduz/method-bind-validated-call
Add ValidatedCall to MethodBind
2023-05-08 13:52:42 +02:00
Rémi Verschelde b226f7e587
CI: Make codespell checks blocking, but only check changed files 2023-05-08 11:50:55 +02:00
Hugo Locurcio 5056c427d3
Improve RenderingServer, RenderingDevice, ShaderGlobalsOverride documentation
This brings the overall class reference completion percentage from 87% to 92%.
2023-05-06 22:40:32 +02:00
Juan Linietsky 1c93606e47 Add ValidatedCall to MethodBind
* This should optimize GDScript function calling _enormously_.
* It also should simplify the GDScript VM considerably.

NOTE: GDExtension calling performance has most likely been affected until going via ptrcall is fixed.
2023-04-30 20:01:26 +02:00
Pedro J. Estébanez 09aa1bbdb3 Fix unsupported sampler filter used for voxel GI 2023-04-26 20:54:06 +02:00
Hugo Locurcio 8eb0d0e665
Fix `compute_pieline` typo in `RenderingDevice.compute_pipeline_is_valid()` 2023-04-10 22:32:04 +02:00
Rémi Verschelde 1c1524a651
Bump version to 4.1-dev
Can't stop, won't stop, they said, huh?
2023-03-01 01:44:37 +01:00
Hugo Locurcio 42b7739321
Document unsupported features in Mobile and Compatibility rendering methods 2023-02-13 22:17:02 +01:00
Rémi Verschelde ed85a2c8ce
Merge pull request #70663 from EpEpDragon/feature_buffer_get_data_size_option
Add optional size parameter to the RenderDevice buffer_get_data method.
2023-02-10 18:49:28 +01:00
clayjohn 35d91b2e54 Document some RenderingServer and RenderingDevice methods and constants
Co-authored-by: Hugo Locurcio <hugo.locurcio@hugo.pro>
2023-01-24 11:35:39 -08:00
EpEpDragon 36d02882b9 Added optional offset and size parameter to RenderDevice buffer_get_data method 2023-01-06 17:08:37 +02:00
Yuri Rubinsky 807632a90c Changed `STORAGE_BUFFER_USAGE_DISPATCH_INDIRECT` type to enum flags 2022-12-15 14:10:37 +03:00
Yuri Rubinsky 6e48db69a3 Changed `RD::PipelineDynamicStateFlags` type to enum flags 2022-12-11 15:37:35 +03:00
Yuri Rubinsky 5934eef44c Changed `RenderingDevice::TextureUsageBits` type to enum flags 2022-11-26 13:08:07 +03:00
Rémi Verschelde e7418cac3d
Merge pull request #68942 from Chaosus/barrier_mask_flags
Expose `BarrierMask` as flags enum in `RenderingDevice`
2022-11-22 08:31:12 +01:00
Yuri Rubinsky acaf38cfbc Expose `BarrierMask` as flags enum in `RenderingDevice` 2022-11-22 09:45:20 +03:00
Patrick Dawson d7136f2d51 Add `offsets` parameter to RenderingDevice::vertex_array_create 2022-11-11 15:45:36 +01:00