1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-05 12:10:55 +00:00
Commit Graph

177 Commits

Author SHA1 Message Date
Rémi Verschelde
0332cee3d4 Merge pull request #101404 from ryevdokimov/mouse-enter-signal-to-notification
Change editor viewports gizmos mouse enter/exit from using signals to notifications
2025-01-10 23:06:47 +01:00
Robert Yevdokimov
a8f3c9727e Add ability to cancel rotation from viewport rotation gizmo 2025-01-10 15:41:06 -05:00
Robert Yevdokimov
d17cf852e3 Change editor viewports gizmos mouse enter/exit from using signals to notificatons 2025-01-10 13:41:49 -05:00
Aaron Franke
0ab3dc273e Rename internal EditorPlugin icon/name to match exposed methods 2024-12-15 17:31:01 -08:00
Thaddeus Crews
c5f0d571b5 Merge pull request #97985 from RobProductions/add-tablet-nav-preset
Add `Tablet/Trackpad` 3D navigation preset
2024-12-12 16:13:24 -06:00
Robert Yevdokimov
e2ed286d2d Add measure mode to 3D 2024-12-10 10:30:49 -05:00
Matt Enad
bd47e4f1ba Add Tablet/Trackpad nav preset
This commit adds a new navigation preset called `Tablet/Trackpad` which enables "Emulate 3 Button Mouse" to more quickly set up good default keys for tablet users.

It also adds support for mouse buttons 4 and 5 in the navigation settings which will be helpful if users want to customize 3D navigation further for specific pens/mice.
2024-12-04 13:02:11 -05:00
Geekotron
6ad82aba3b Allow tool scripts to alter transform of Node3DEditorViewport camera 2024-11-29 18:48:01 +01:00
Thaddeus Crews
30ab612e35 Merge pull request #90778 from timothyqiu/cam-preview
Add Camera3D preview in Inspector
2024-11-27 10:46:59 -06:00
Michael Alexsander
16524a8a01 Add "Game" editor for better runtime debugging 2024-10-30 11:42:17 -03:00
Robert Yevdokimov
fb768a7118 Use collision detection ray to reposition an object already in the scene 2024-10-04 17:13:46 -04:00
Rémi Verschelde
21353460f7 Merge pull request #88511 from ryevdokimov/offset-drag-to-instantiate-scene
Offset drag instantiated scenes that result in a collision by its bounds to mitigate overlap
2024-10-04 22:42:52 +02:00
Adam Scott
9d735b0904 Fix issue where editable children of 3D nodes would be selected 2024-09-09 14:39:09 -04:00
Rémi Verschelde
48645f3d70 Merge pull request #87793 from ryevdokimov/hide-transform-gizmo
Add ability to hide editor transform gizmo
2024-08-28 00:10:32 +02:00
Rémi Verschelde
109203d472 Merge pull request #85331 from RobProductions/customize-navigation-controls
Add full customization of 3D navigation controls
2024-08-28 00:10:19 +02:00
Juan Pablo Arce
45f6110e26 Fix gizmos without visible geometry not being selectable
The issue was that Node3DEditorViewport was using the render server's BVH to filter out nodes,
which is not correct for gizmos that have no renderable components,
or have collision triangles that exceed the bounds of their renderable components.
2024-07-21 13:56:13 -03:00
Matt Enad
9d343ced58 Add customizable 3D navigation settings
This commit adds 3 new editor settings for orbit, pan, and zoom mouse buttons, and 6 new shortcuts which act as modifiers for the navigation controls. These new shortcuts replace the old orbit, pan, and zoom modifier settings.

The `navigation_scheme` setting now acts as a preset which changes the new options added above, and the new settings are what drives 3D navigation instead. A new struct is used for ordering the navigation logic so that actions with fewer shortcuts are checked first. When the editor starts, the preset detection will run to automatically update user settings from old Godot versions. When the setting is changed, the hint values for the mouse buttons are dynamically updated to show the user the corresponding shortcut values.

The new doc fields have been generated and the description for the new settings are filled out. The `navigation_scheme` entry now has more consistent styling and added control descriptions that were missing before.
2024-07-02 12:37:57 -04:00
passivestar
4201c7d75f Make the frame time and info boxes have same margins 2024-06-29 16:34:08 +04:00
Robert Yevdokimov
c9e9bd4a68 Add ability to Hide Editor Transform Gizmo 2024-06-27 21:01:15 -04:00
passivestar
a9ef6cd418 Improve viewport rotation gizmo drawing 2024-06-26 23:33:24 +04:00
Rémi Verschelde
25b17bd245 Merge pull request #92188 from SaracenOne/ownerless_node_select
Disallow selection of ownerless nodes
2024-05-28 15:48:54 +02:00
Saracen
596026a1ee Disallows selection of ownerless nodes:
Attempts to select first node owned by the edited scene instead.
2024-05-28 11:13:40 +01:00
Robert Yevdokimov
14f6c816ba Offset drag instantiated scenes that result in a collision by its bounds to prevent overlap
Co-Authored-By: Robbie Cooper <cooperra@users.noreply.github.com>
2024-05-25 12:39:21 -04:00
Hugo Locurcio
60084dcc2c Prevent label width from flickering rapidly in editor frametime panel
This also improves the background display by drawing a single background
for all 3 labels. This avoids visible corners between each label.
2024-05-23 20:50:25 +02:00
Haoyu Qiu
e5c321448e Create AudioStreamPlayer when dropping AudioStream
- Create AudioStreamPlayer if dropped in between nodes in the Scene dock
- Create AudioStreamPlayer2D if dropped into 2D editor
- Create AudioStreamPlayer3D if dropped into 3D editor
2024-05-19 20:26:04 +08:00
Rémi Verschelde
1069d7b7c6 Merge pull request #88343 from Riteo/warped-mouse-float
Handle warped mouse motion as floating point
2024-05-06 15:14:46 +02:00
Haoyu Qiu
75eacba5cd Add Camera3D preview in Inspector 2024-05-05 16:15:49 +08:00
Aaron Franke
1bcbbe96c4 Organize existing code for editor plugins 2024-04-27 11:59:58 -07:00
Rémi Verschelde
8516304b82 Merge pull request #89847 from GreenCrowDev/missing-bezier-handles
UX and stability improvements for `Path3D` node
2024-04-04 14:31:49 +02:00
jsjtxietian
20f4a5d03a Fix path3d's pick works incorrectly when viewport is in half resolution 2024-03-26 17:24:41 +08:00
matricola787
5c83d14698 UX and stability improvements for Path3D node 2024-03-25 16:51:37 +01:00
David Luevano Alvarado
71426d0f5c Fix wrong undo-redo action when dropping files containing circular dependencies 2024-03-07 12:20:49 -06:00
Muller-Castro
1638c1b28f Add const lvalue ref to editor/* container parameters 2024-02-26 15:28:15 -03:00
Rémi Verschelde
fd788d7df9 Merge pull request #88584 from ryevdokimov/hide_grid_per_viewport
Add ability to hide grid per viewport
2024-02-23 22:19:01 +01:00
Robert Yevdokimov
df431542c3 Add ability to hide grid per viewport 2024-02-23 10:25:29 -05:00
pohy
6efff2cd06 Use subgizmos instead of handles for Path3D curve points 2024-02-22 22:33:34 +01:00
Riteo
759a32eb0c Handle warped mouse motion as floating point
Fixes certain issues where sub-pixel motions would get discarded while
the mouse is captured, such as when free look is enabled in the editor
(at least when turned on while holding right click).

Very slightly compat breaking, as actual public APIs are changed,
although with "compatible" types (Point2i->Point2).
2024-02-14 22:37:51 +01:00
Robbie Cooper
30914c0434 Fix bounding boxes
Each time an AABB is rotated, it gets bigger. That means opposite rotations don't cancel out.

The previous implementation repeatedly rotates children AABBs as it climbs up the tree. This often resulted in selection boxes looking bigger than their contents.

This implementation calculates and applies a single final transformation to each AABB before it is merged with the others. After merging, there are no additional rotations, so AABBs remain accurate.

Co-Authored-By: Robert Yevdokimov <105675984+ryevdokimov@users.noreply.github.com>
2024-02-02 07:59:47 -05:00
Yuri Sizov
95b27fe8c7 Reorganize code related to editor theming
This change introduces a new EditorThemeManager class
to abstract theme generatio and its subroutines.

Logic related to EditorTheme, EditorColorMap, and editor
icons has been extracted into their respective files with
includes cleaned up.

All related files have been moved to a separate folder to
better scope them in the project. This includes relevant
generated files as well.
2024-01-16 11:57:45 +01:00
Rémi Verschelde
0cdb530c18 Merge pull request #83895 from clayjohn/origin-lines
Use screen-aligned quads for origin lines to avoid issues on NVidia
2024-01-04 16:39:42 +01:00
kleonc
74a35526e0 Fix some Node3DEditor snapping issues 2023-10-27 13:00:49 +02:00
clayjohn
5591f289d7 Uses screen-aligned quads for origin lines to avoid issues on NVidia
While we are add it, use alpha-antialised lines to make them look nice
2023-10-24 18:02:36 +02:00
Dario
057367bf4f Add FidelityFX Super Resolution 2.2 (FSR 2.2.1) support.
Introduces support for FSR2 as a new upscaler option available from the project settings. Also introduces an specific render list for surfaces that require motion and the ability to derive motion vectors from depth buffer and camera motion.
2023-09-25 10:37:47 -03:00
Yuri Sizov
f542dffb39 Improve the looks of 2D/3D viewport contextual toolbars 2023-09-13 13:04:55 +02:00
Ryan Roden-Corrent
d6a83a6bac Implement numeric blender-style transforms.
This allows the user to input numbers during an "instant" (blender
style) transform operation to specify exactly how far to transform the
object. For example:

g2.5xx: Translate 2.5 units along the local x-axis
ry-45: Rotate -45 degrees around the y-axis
s.25Z: Scale by a factor of .25 on the xy plane

Some shared code between the traslate/rotate/scale branches of update_transform
was refactored into apply_transform so numeric transforms could reuse it.

This removes any "{X,Y,Z}-Axis Transform" messages. These prevented the
"Transforming: (x,y,z)" messages from showing, and the latter are more
useful, as they tell you the actual units.

This also rearranges finish_transform to clear _edit before updating
the axis rendering, so an axis doesn't remain highlighted.

Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2023-08-10 07:18:18 -04:00
Ryan Roden-Corrent
90bddd21c8 Wrap mouse for blender-style transforms.
When performing a blender-style translate or scale (but not rotate),
wrap the mouse inside the bounds of the viewport. This allows moving the
mouse indefinitely for large translate or scale operations, and is
consistent with how blender works.

This enables global input processing during blender-style transforms, so
we can capture and wrap mouse events outside the bounds of the viewport.

Other wrapping operations use _sinput, which I assume is possible
because a mouse button is held, so the control receives input even when
the mouse exits the control.

This does not implement wrapping for regular (gizmo-driven) transforms,
though this could be done if desired.

Fixes godotengine/godot-proposals#4255.
2023-07-08 07:53:47 -04:00
Rémi Verschelde
6306eb4047 Merge pull request #76372 from sygi/dont_propagate_lock_view
Store lock view rotation whether its on or off
2023-06-12 17:09:38 +02:00
Bram Stolk
4bc513edbc Add missing initializations for Node3DEditor.
Do not try to format fields with garbage values in _snap_update()
Initialize grid_enable[] before use.
Initialize previewing_camera before use.
These are all cases found live, with valgrind.
Fixes #76925
2023-05-11 08:16:04 -07:00
Hendrik Brucker
dc46163b12 Improve editor state persistence 2023-05-11 04:17:03 +02:00
Jakub Sygnowski
07258c3984 Store lock view rotation whether its on or off 2023-04-23 15:18:22 +01:00