Commit graph

602 commits

Author SHA1 Message Date
Lukas Tenbrink
e34f1f504c Use std::size instead of sizeof(a) / sizeof(a[0]) pattern throughout the codebase. 2025-02-07 14:57:48 +01:00
Chaosus
7cc0bf79dd Fix mouse filter on visual shader node previews 2025-02-01 13:25:28 +03:00
Lukas Tenbrink
27665436cd Fix float constant descriptions not translating on macOS. 2025-01-17 09:33:41 +01:00
Rémi Verschelde
524cbec858 Merge pull request #100309 from Chaosus/vs_prevent_invalid_boolean_varying
Prevent using boolean varyings in vertex function of visual shaders
2025-01-13 20:21:43 +01:00
Yuri Rubinsky
0aede87b67 Add derivative functions to sky shader mode in visual shader 2025-01-10 10:28:02 +03:00
Rémi Verschelde
6c6e74408c
Merge pull request #94616 from Chaosus/vs_fix_vec4_constant
Change `VisualShaderNodeVec4Constant` type to vec4
2025-01-03 02:01:09 +01: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
kobewi
9a96393f46 Add warped panning to every ViewPanner instance 2024-12-20 17:40:27 +01:00
Markus Sauermann
4887172a59 Fix ViewPanner panning mouse warp
Currently the mouse cursor jumps in unexpected ways, when a `ViewPanner`
is used in SubViewports or embedded Windows.

This is caused by providing wrong coordinate systems to
Input::warp_mouse_motion.

This PR replaces the use of `Input::warp_mouse_motion` with
`Viewport::wrap_mouse_in_rect` and makes sure, that the correct
coordinate systems are used.

This change makes it necessary, that all classes, that currently
use ViewPanner, need to provide the correct Viewport to ViewPanner.
2024-12-20 00:28:49 +01:00
Chaosus
059ed731f5 Prevent using boolean varyings in vertex function of visual shaders 2024-12-12 14:35:49 +03:00
Chaosus
ba39b078f5 [Scene] Add SceneStringName::FlatButton 2024-12-10 11:12:26 +03:00
Rémi Verschelde
e6125ef51b
Merge pull request #98763 from AThousandShips/more_sname_uses
Use `SceneStringName` in more places
2024-12-02 15:50:44 +01:00
A Thousand Ships
af56d6e8e8
Use SceneStringName in more places 2024-12-02 14:39:16 +01:00
rune-scape
d58b2e879f Get rid of easily removable uses of const_cast 2024-12-01 17:50:13 -08:00
Rémi Verschelde
6d4bb8fbda
Merge pull request #94721 from ckaiser/animation-blend-tree-tweaks
Improve blend tree contrast/margins
2024-11-29 22:45:47 +01:00
Rémi Verschelde
88e81ee730
Fix various typos and code style issues 2024-11-28 17:40:42 +01:00
Thaddeus Crews
9e259ef061
Merge pull request #97884 from passivestar/list-variations
Add theme type variations for secondary Trees and ItemLists
2024-11-27 10:47:14 -06:00
Thaddeus Crews
0ee60dd543
Merge pull request #99516 from KoBeWi/quantum_entanglement_of_source_files
Untangle ColorPicker includes
2024-11-26 13:04:54 -06:00
Thaddeus Crews
7faad0cc7a Merge pull request #97388 from tetrapod00/visualshader-linear-srgb
VisualShader: Add LinearToSRGB and SRGBToLinear to ColorFunc node
2024-11-22 14:54:47 -06:00
kobewi
289e548e34 Untangle ColorPicker includes 2024-11-22 21:42:50 +01:00
Christian Kaiser
5559075844 Fix graph node sizing regression, improve blend tree contrast/margins 2024-11-22 16:11:28 -03:00
passivestar
0ff5d5fd04 Add theme type variations for secondary Trees and ItemLists 2024-11-19 18:33:30 +04:00
Chaosus
a64b3fd3f8 Allow SCREEN_UV to be used in light function of spatial shader 2024-11-19 11:39:49 +03:00
Thaddeus Crews
313fe08e19
Merge pull request #99177 from Chaosus/vs_swap_connections
Add swap connection option to visual shader graph
2024-11-15 10:42:35 -06:00
Chaosus
ce833a3885 Add swap connection option to visual shader graph 2024-11-15 13:02:09 +03:00
Chaosus
5a856a6896 Fix error emitting when reset a visual shader preview parameter 2024-11-15 12:39:07 +03:00
Chaosus
485e7f899b Add copy/paste options to preview material parameters in visual shader 2024-11-12 22:04:44 +03:00
rune-scape
a47daa0a44 Avoid const_cast in List::erase by requiring mutable elements 2024-11-08 00:10:08 -08:00
Yuri Rubinsky
ef8d981267
Merge pull request #98303 from Chaosus/vs_transparency_preview
Add alpha channel display to vec4 previews of visual shader nodes
2024-10-31 11:17:34 +03:00
Aaron Franke
562c666e3d
Rename internal Button icon to button_icon to match exposed methods 2024-10-29 16:23:03 -07:00
tetrapod00
2191df0cea VisualShader: Add LinearToSRGB and SRGBToLinear to ColorFunc node 2024-10-19 12:18:34 -07:00
Chaosus
43a99fba3d Add alpha channel display to vec4 previews of visual shader nodes 2024-10-18 20:00:10 +03:00
A Thousand Ships
79f654ced5
[Core] Fix sorting of Dictionary keys
`StringName` keys were sorted as `StringName` which is unstable.
2024-10-18 08:47:05 +02:00
aryan-11825114
b4460c6ba3 Add cut_nodes_request signal to GraphEdit 2024-09-27 08:47:11 +05:30
tetrapod00
eb5a9c3b33 Visual Shader: Add vector operations to Remap node 2024-09-22 11:25:36 -07:00
Haoyu Qiu
14321b8ed5 Set auto translate mode for drag previews
- Controls
  - `LineEdit`, `TextEdit`: Always disabled since it's dragging user input.
  - `TabBar`: Use the same auto translate mode as the node.
  - `RichTextLabel`: Always disable since auto translation is done
    differently from other controls (selection text you get
    programmatically is always after auto translation).
- Editor
  - Disable drag preview auto translation if the text is user input,
    filename, or class name.
  - Also disabled unexpected auto translation for audio bus effect names.
2024-09-19 19:21:29 +08:00
Rémi Verschelde
4d35402c1c
Merge pull request #96400 from Maran23/inputmap-usage-for-filter-and-corresponding-refactor
Use InputMap actions consistently across all LineEdit's that filter an underlying Tree or ItemList.
2024-09-16 13:34:38 +02:00
Giganzo
7d78d753b5 Fix Set Frame Title popup position 2024-09-04 01:52:07 +02:00
Marius Hanl
74f64aaf98 Use InputMap actions consistently across all LineEdit's that filter an underlying Tree or ItemList.
- Instead of checking for Key::UP, Key::DOWN, Key::PAGEUP, Key::PAGEDOWN etc., we rather check for the action like 'ui_up' or 'ui_down'.
- Also use AcceptDialog's 'register_text_enter' functionality to consistently close a dialog when ENTER is pressed while the LineEdit has focus (instead of redirecting ENTER keys to e.g. the underlying Tree).
- Unify the LineEdit filter behavior for the SceneTreeDialog and corresponding usages
- Improve OK Button disablement (something should be selected)
2024-08-31 21:10:27 +02:00
rune-scape
154049ce17 StringName Dictionary keys
also added 'is_string()' method to Variant
and refactored many String type comparisons to use it instead
2024-08-29 13:39:27 -07:00
Yuri Rubinsky
52889ab7ee [Scene] Add SceneStringName::toggled 2024-08-28 15:14:26 +03:00
Rémi Verschelde
18895b8aac
Merge pull request #93017 from Chaosus/vs_mesh_emitter_drag_and_drop
Allow drag & drop Mesh to create MeshEmitter in visual shaders
2024-08-28 00:11:01 +02:00
Rémi Verschelde
9dfc41568a
Merge pull request #95984 from timothyqiu/what-identifier
Add `String.is_valid_unicode_identifier()`
2024-08-27 16:55:06 +02:00
Rémi Verschelde
21bcff00e9
Merge pull request #95126 from Chaosus/shader_cubemap_fix
Allow setting a cubemap as default parameter to shader
2024-08-27 16:54:50 +02:00
Chaosus
db251a3f99 Allow setting a cubemap as default parameter to shader 2024-08-27 09:43:05 +03:00
Chaosus
f538376c3b Add CLIP_SPACE_FAR built-in to spatial shader 2024-08-27 08:48:46 +03:00
Haoyu Qiu
8bf4ecc026 Add String.is_valid_unicode_identifier()
- Adds `is_valid_unicode_identifier()`
- Adds `is_valid_ascii_identifier()`
- Deprecates `is_valid_identifier()`
- Renames `validate_identifier()` to `validate_ascii_identifier()`
2024-08-27 11:34:08 +08:00
Rémi Verschelde
0125b0eb03
Merge pull request #94215 from Chaosus/vs_preview_and_param_list
Add a material preview to visual shader editor
2024-08-26 23:28:46 +02:00
Yuri Rubinsky
eef236db63 Fix visual shader inputs to follow the alphabet order 2024-08-20 20:51:47 +03:00
aryan-11825114
3f7efd2291 Fix small graph editor pins at higher display scales 2024-08-17 15:01:05 +05:30