summaryrefslogtreecommitdiff
path: root/scene/main/viewport.cpp
AgeCommit message (Collapse)Author
2021-02-14[CTL] Add missing font outline drawing routines and theme constants.bruvzg
2021-02-10Merge pull request #45845 from qarmin/cppcheck_scene_2Rémi Verschelde
Initialize class variables with default values in scene/ [2/2]
2021-02-10Make Servers truly Thread Safereduz
-Rendering server now uses a split RID allocate/initialize internally, this allows generating RIDs immediately but initialization to happen later on the proper thread (as rendering APIs generally requiere to call on the right thread). -RenderingServerWrapMT is no more, multithreading is done in RenderingServerDefault. -Some functions like texture or mesh creation, when renderer supports it, can register and return immediately (so no waiting for server API to flush, and saving staging and command buffer memory). -3D physics server changed to be made multithread friendly. -Added PhysicsServer3DWrapMT to use 3D physics server from multiple threads. -Disablet Bullet (too much effort to make multithread friendly, this needs to be fixed eventually).
2021-02-09Fix contact points debug for 3D PhysicsPouleyKetchoupp
Setting each point's position was missing for 3D. Now enabling collision render debug will display contact points for 3D physics, the same way it does for 2D physics. Note: Multimesh rendering seems not to work in this scenario on master, but it's working fine on 3.2.
2021-02-09Initialize class variables with default values in scene/ [2/2]Rafał Mikrut
2021-02-07Implement pause-aware pickingPedro J. Estébanez
This changes the way 2D & 3D physics picking behaves in relation to pause: - When pause is set, every collision object that is hovered or captured (3D only) is released from that condition, getting the relevant mouse-exit callback., unless its pause mode makes it immune from pause. - During the pause. picking only considers collision objects immune from pause, sending input events and enter/exit callbacks to them as expected. - When pause is left, nothing happens. This is a big difference with the classic behavior, which at this point would process all the input events that have been queued against the current state of the 2D/3D world (in other words, checking them against the current position of the objects instead of those at the time of the events).
2021-01-24Shadow map rendering optimizationreduz
-All shadow rendering is done with raster now (no compute) -All shadow rendering is done by rendering directly to the shadow atlas -Improved how buffer clearing is done to optimize the above. -Ability to set shadows as 16 bits.
2021-01-19Added GPU based cluster builderreduz
Clustering is now GPU based, uses an implementation based on the Activision algorithm.
2021-01-07Make tooltips appear on the same display as the editorAberrantWolf
The `current_screen` field was never being set on tooptip windows, leading to scenarios where, if the editor wasn't on screen 0, tooltips may not appear in the right place, especially when your screens have different resolutions.
2021-01-05Tooltips: Fix unassigned strip_edges() call on textRémi Verschelde
Fixes #43940, was a regression from #43280.
2021-01-01Update copyright statements to 2021Rémi Verschelde
Happy new year to the wonderful Godot community! 2020 has been a tough year for most of us personally, but a good year for Godot development nonetheless with a huge amount of work done towards Godot 4.0 and great improvements backported to the long-lived 3.2 branch. We've had close to 400 contributors to engine code this year, authoring near 7,000 commit! (And that's only for the `master` branch and for the engine code, there's a lot more when counting docs, demos and other first-party repos.) Here's to a great year 2021 for all Godot users 🎆
2021-01-01Merge pull request #44276 from YeldhamDev/tooltip_position_embedded_fixRémi Verschelde
Fix tooltip position in main embedded window
2020-12-28Rename empty() to is_empty()Marcel Admiraal
2020-12-23Rename Control margin to offsetMarcel Admiraal
2020-12-18Implement automatic LOD (Level of Detail)reduz
-Happens on import by default for all models -Just works (tm) -Biasing can be later adjusted per node or per viewport (as well as globally) -Disabled AABB.get_support test because its broken
2020-12-15Rename neighbour in Control to neighborDaniel Ting
This keeps things consistent with the rest of Godot, which uses the American English spelling of Color.
2020-12-10Fix tooltip position in embedded windowMichael Alexsander
2020-12-10Rename Viewport::ClearMode::CLEAR_MODE_ONLY_NEXT_FRAME to CLEAR_MODE_ONCEMarcel Admiraal
2020-11-28Merge pull request #42109 from EricEzaM/PR/input-and-shortcuts-reworkRémi Verschelde
Shortcuts rework - fixed issues with input propagation and triggering of unwanted shortcuts.
2020-11-28Merge pull request #41100 from bruvzg/ctl_text_server_interfaceRémi Verschelde
[Complex Text Layouts] Implement TextServer interface.
2020-11-26Implement signed distance fields for 2D shadersreduz
2020-11-26[Complex Text Layouts] Refactor Font class, default themes and controls to ↵bruvzg
use Text Server interface. Implement interface mirroring. Add TextLine and TextParagraph classes. Handle UTF-16 input on macOS and Windows.
2020-11-23Implement new shortcuts system.Eric M
unhandled_key_input changed to unhandled_button_input. Controls can set a 'shortcut_context' which they can then use to determine if their shortcuts should be triggered or not, based on if the viewport's focused GUI control is a child of their 'shortcut context'.
2020-11-16Remove empty lines around braces with the formatting scriptAaron Franke
2020-11-07Reorganized core/ directory, it was too fatty alreadyreduz
-Removed FuncRef, since Callable makes it obsolete -Removed int_types.h as its obsolete in c++11+ -Changed color names code
2020-11-03Merge pull request #39635 from Meriipu/master_nodropRémi Verschelde
do not drop mouseover on WM_MOUSE_EXIT
2020-11-03Tooltips: Improve code clarity and docsRémi Verschelde
The return type for `_make_custom_tooltip` is clarified as Control, and users should make sure to return a visible node for proper size calculations. Moreover in the current master branch, a PopupPanel will be added as parent to the provided tooltip to make it a sub-window. Clarifies documentation for `Control._make_custom_tooltip`, and shows how to use the (until now undocumented) "TooltipPanel" and "TooltipLabel" theme types to style tooltips. Fixes #39677.
2020-10-30Refactor pixel snapping.reduz
-Rename pixel_snap to snap_2d_to_vertices -Added snap_2d_to_transforms which is more useful Fixes #41814 Solves proposal https://github.com/godotengine/godot-proposals/issues/1666 Supersedes #35606, supersedes #41535, supersedes #41534
2020-10-24Refactored 2D shader and lighting systemreduz
-Removed normal/specular properties from nodes -Create CanvasTexture, which can contain normal/specular channels -Refactored, optimized and simplified 2D shaders -Use atlas for light textures. -Use a shadow atlas for shadow textures. -Use both items aboves to make light rendering stateless (faster). -Reorganized uniform sets for more efficiency.
2020-10-19Merge pull request #38097 from Calinou/add-viewport-debandingJuan Linietsky
Add a debanding property to Viewport
2020-10-02Merge pull request #42451 from Duroxxigar/rename-toplevelRémi Verschelde
Renamed toplevel to be top_level
2020-10-01Merge pull request #38743 from arrowinaknee/node-config-warningsRémi Verschelde
Update all get_configuration_warning() to retrieve warnings from the parent
2020-10-01Renamed toplevel to be top_levelDuroxxigar
2020-09-29Merge pull request #41895 from 11thPenguin/masterRémi Verschelde
Fix minor typo, gui_hid -> gui_hide
2020-09-28Make the currently hovered control get updated on mouse-releaseMeriipu
Previously, when the mouse was released after dragging a scrollbar, its highlight was not dropped (if the mouse cursor was still inside the viewport). This seems to be because the currently hovered control only gets updated when the mouse is moved. This commit fixes the dropping of the cosmetic highlight by running the check for whether the currently hovered control has changed on mouse-clicks, in addition to to the existing mouse-movements.
2020-09-15Tooltip flickering and targeting fixes.Eric M
2020-09-08Fixed minor typo, gui_hid -> gui_hide.Jonah Stich
2020-09-07If the mouse is held on notification_wm_mouse_exit, do not drop focusMeriipu
This fixes a bug where users of the scrollbar had to be very careful not to move the mouse outside the viewport, otherwise the scrollbar would drop its drag-action and stop scrolling until clicked again. The existing behaviour had the side-effect of also dropping the cosmetic highlighting of the scrollbar (in addition to the dragging), for the specific case where the mouse was move outside the window. The previous behaviour did nothing to remove the highlight if the mouse was released (but not moved) inside the viewport. This separate issue with the lingering highlight of the scrollbar (until a mouse-movement action is performed inside the viewport) is fixed in an immediate followup to this commit. Closes bug #39634
2020-08-14Add a debanding property to ViewportHugo Locurcio
It can be enabled in the Project Settings (`rendering/quality/screen_filters/use_debanding`). It's disabled by default as it has a small performance impact and can make PNG screenshots much larger (due to how dithering works). It will also slightly brighten the scene's dark areas. As a result, it should be enabled only when banding is noticeable enough. This closes #17006.
2020-07-27Fix input after removing multilevel callsGeorge Marques
2020-07-24Remove multilevel callsGeorge Marques
In general they are more confusing to users because they expect inheritance to fully override parent methods. This behavior can be enabled by script writers using a simple super() call.
2020-07-02Ensure cursor shape changes when exiting window, fixes #37724Juan Linietsky
2020-07-02Merge pull request #40020 from reduz/fix-tree-edit-focusRémi Verschelde
Fix doubleclick on tree item, restore input focus on previous windows.
2020-07-01Add ability to clamp embedded subwindows to parent, fixes #37792Juan Linietsky
2020-07-01Fix doubleclick on tree item, restore input focus on previous windows.Juan Linietsky
Closes #37335
2020-07-01Ensure embedded mode works againJuan Linietsky
Also implemented application in/out notifications in X11.
2020-06-30Add a separate application focus/in notification out from Window focus ↵Juan Linietsky
notification.
2020-06-26Addition of SDFGI for open world global illuminationJuan Linietsky
Move GI to a deferred pass
2020-05-16Update all get_configuration_warning to retrieve warnings from the parentArrowInAKnee
2020-05-14Style: Enforce braces around if blocks and loopsRémi Verschelde
Using clang-tidy's `readability-braces-around-statements`. https://clang.llvm.org/extra/clang-tidy/checks/readability-braces-around-statements.html