Commit Graph

151 Commits

Author SHA1 Message Date
lawnjelly
4f1f6633e1 Fix Viewport interpolation mode
Viewport interpolation mode is a special case, which should be set to ON instead of INHERIT.
2024-07-14 08:40:21 +02:00
150b8e5c02 Update theme item names for pandemonium. 2024-07-14 08:29:21 +02:00
Haoyu Qiu
410029c9e0 Fix theme item parameter completion 2024-07-14 08:27:13 +02:00
3b84801274 Added a group for the toplevel property in Node2D. 2024-05-11 10:37:52 +02:00
1b14af3a98 Moved the y_sort property from YSort to Node2D. Node2d has it off by default while YSort has it on by default. 2024-05-10 17:23:52 +02:00
789e640b9d Fix build. 2024-04-21 14:54:17 +02:00
Paweł Fertyk
2154c87432 Fix AudioStreamPlayer not paused on pause mode change
Fixes #58543.
2024-04-21 14:27:49 +02:00
Haoyu Qiu
9f75f7dfc0 Fix SceneTree not respecting virtual process methods
Co-authored-by: Raul Santos <raulsntos@gmail.com>
2024-04-21 14:15:45 +02:00
Haoyu Qiu
1d18b076de Add Node.is_node_ready 2024-04-14 16:35:04 +02:00
lawnjelly
909acac329 Discrete Level of Detail
Add scene side discrete level of detail.

New node `LOD` for UI, and `LODManager` within `World` for automatically updating child visibilities based on distance from cameras.
2024-04-06 12:06:01 +02:00
272ae15993 Now tooltips won't get scaled to their original control's scale anymore by default. Added a new gui_scale_tooltips property to Viewport to be able to use the previous behaviour when it's desired. 2024-03-13 16:55:47 +01:00
105115dbb3 Removed clips_input() method and _clips_input() virtual method from Control. Made clip_contents to also have an input clipping effect, since I couldn't think any single instance where keeping them separated would be useful.
This fixes LayeredTileMap's editors clipping input while being invisible, and likely other smaller issues.
2024-03-12 17:29:22 +01:00
c3c6d64a50 Portred: Add MergeGroup node to simplify merging Meshes at runtime.
- lawnjelly
8b79135538
2024-02-08 21:00:07 +01:00
ae7409bf52 Ported: Fix signed distance field font rendering
This fix works in both GLES3 and GLES2.
The rendering formula in the shader was adjusted to further improve the
sharpness/antialiasing quality balance.
- lawnjelly and Calinou
bc607fb607
2024-02-08 19:11:34 +01:00
5d2a594843 Ported: Shadow volume culling and tighter shadow caster culling
Existing shadow caster culling using the BVH takes no account of the camera. This PR adds the highly encapsulated class VisualServerLightCuller which can cut down the casters in the shadow volume to only those which can cast shadows on the camera frustum.
This is used to:
* More accurately defer dirty updates to shadows when the shadow volume does not intersect the camera frustum.
* Tighter cull shadow casters to the view frustum.
Lights dirty state is now automatically managed:
* Continuous (tighter caster culling)
* Static (all casters are rendered)
- lawnjelly
8ca631a466
2024-02-08 18:40:44 +01:00
Micky
d1621245e6 Add Editor Description group
Backport from 4.0
2024-02-08 14:56:04 +01:00
5133ef182d File copyright header updates pt10. 2023-12-18 00:31:04 +01:00
98912a89e8 File copyright header updates pt9. 2023-12-18 00:25:33 +01:00
88e9ad04f2 Moved back the servers and resources from core. 2023-12-10 23:11:07 +01:00
11945d7f1d Split material.h. 2023-12-10 21:26:28 +01:00
053f083e17 Moved the Physics 2d server to core. 2023-12-10 19:42:57 +01:00
dbcc6e33da Moved the physics server to core. 2023-12-10 19:36:00 +01:00
238bf1b331 Moved the RenderingServer to core. 2023-12-10 19:04:24 +01:00
3902cf1924 Moved ScneeStringNames and PropertyUtils into scene/main. 2023-12-10 18:01:51 +01:00
191e9e152e Added quote_style argument to get_argument_options(). 2023-12-10 16:02:08 +01:00
9df5649c1b Moved CanvasItem, Control, Node2D and Spatial under scene/main. 2023-12-10 15:50:54 +01:00
763f662263 Moved meshes to a new subfolder. 2023-12-10 15:22:09 +01:00
deccaed2cc Moved materials into a new subfolder. 2023-12-10 14:59:22 +01:00
08160fd63f Moved fonts into a new subfolder. 2023-12-10 14:42:30 +01:00
cc012d3f92 Ported from godot: 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.
- lawnjelly
3e19cf834a
2023-10-02 17:49:41 +02:00
cf2e53ebc3 Also remove now unnecessary if. 2023-09-09 04:01:26 +02:00
f592c170d1 Go back to using no context Nodes directly to save on lookup, as Nodes shouldn't be deleted like this. 2023-09-09 04:00:47 +02:00
93f4077e73 Stop processing no context node inputs when the input gets handled. Also use ObjectIDs in case Nodes get deleted. 2023-09-09 03:41:19 +02:00
4637f73099 Backported the shortcut context system from godot4. 2023-09-07 12:57:34 +02:00
9a2bf73280 Backported _shortcut_input() virtual from godot4. 2023-09-07 09:56:16 +02:00
66e080d766 Fix typo. 2023-09-07 07:55:48 +02:00
7fcc653a0e Backported the CallInputType parameter for SceneTree::_call_input_pause() from godot4. 2023-09-07 07:40:45 +02:00
6be43d2ec6 Backported SceneTree::get_first_node_in_group() from godot4. 2023-09-06 08:54:55 +02:00
1e5f9895e7 Backported from godot4: Remove SceneTree debug avoidance hint
Removes SceneTree debug avoidance hint.
- smix8
f1d8ddd9bd
2023-09-04 21:43:06 +02:00
62c5bfbc36 Backported from godot4: Remove legacy navigation debug materials
Removes legacy navigation debug materials.
- smix8
1b506cd49c
2023-09-02 13:18:16 +02:00
8467cf9e94 Backported from godot4: Keep NavigationServer active while SceneTree is paused.
- smix8
4b0dee080e
2023-09-02 12:57:35 +02:00
eb8943a4f6 Backported from godot4: Add Path2D/3D debug options
- smix8
e12e239ab4
2023-09-02 11:38:01 +02:00
d977ed360e Ported: 2D Fixed Timestep Interpolation
Adds support to canvas items and Camera2D.
- lawnjelly
5162efbfe9
2023-08-27 18:48:25 +02:00
87b91721da Ported: Physics interpolation - Move out of Scenario
Move VisualServer interpolation data out of Scenario and into VisualServerScene, so the interpolation data and enabled status is now common to all Scenarios.

Fix physics interpolation in multithreaded mode by ensuring tick and pre-draw are called.
- lawnjelly
d2b1d29634
2023-08-27 17:25:38 +02:00
5861ad6485 Fix typos in _rpc_id_bind and _rpc_unreliable_id_bind. 2023-08-15 23:42:34 +02:00
01c3cd88d5 Make sure rpc binds can take both Strings and StringNames as method names. 2023-08-15 10:24:30 +02:00
5b869f8b54 Ported from godot: Canvas item hierarchical culling
Adds optional hierarchical culling to the 2D rendering (within VisualServer).
Each canvas item maintains a bound in local space of the item itself and all child / grandchild items. This allows branches to be culled at once when they don't intersect a viewport.
- lawnjelly
b777a9e5f9
2023-06-28 20:25:48 +02:00
decade59c8 Implemented a new ProcessGroup Node. It can be used to multithread scenes updates.
It was insipred by godot 4's ProcessGroup system, however while Godot 4's implementation tries to hide threaded processing as much as possible, this implementation focuses on making it explicitly known and obvious to the user, in a (hopefully) almost bolierplate free way.

Also with the available options this node can be used for other purposes, like multi threaded cron job like method calls when paired with a Timer in manual mode.
2023-06-13 15:08:35 +02:00
d4175f9676 Ported parts of : Refactor Node Processing
* Node processing works on the concept of process groups.
* A node group can be inherited, run on main thread, or a sub-thread.
* Groups can be ordered.
* Process priority is now present for physics.
This is the first steps towards implementing godotengine/godot-proposals#6424.
No threading or thread guards exist yet in most of the scene code other than Node. That will have to be added later.
- reduz
98c655ec8d
- Only got the smaller improvements, and the thread safety for Node and SceneTree. I'm planning to implement a similar system, but I have a different way of doing it in mind.
2023-06-12 21:13:26 +02:00
f058c87868 Backported from godot4: Rework Navigation Avoidance
Rework Navigation Avoidance.
- smix8
a6ac305f96
2023-06-10 20:58:49 +02:00