summaryrefslogtreecommitdiff
path: root/scene/main/viewport.cpp
AgeCommit message (Collapse)Author
2021-07-29Add `auto_translate` toggle for automatic translationMichael Alexsander
2021-07-27Multiple cosmetic fixes for embedded windowsMichael Alexsander
2021-07-26Use Ref<T> references as iterators where relevantRémi Verschelde
And const when possible.
2021-07-23Use C++ iterators for Lists in many situationsAaron Franke
2021-07-23Show tooltips even when paused or time_scale is 0kobewi
2021-07-22Make `MenuButton`'s `switch_on_hover` work againMichael Alexsander
2021-07-20Merge pull request #38317 from verdog/get-cam-2d-4.0Rémi Verschelde
add viewport.get_camera_2d()
2021-07-20Editor StringName and Viewport optimizationsJoan Fons
* Added explicit return type to the SNAME macro. * Add some extra SNAME usages. * Change some ClassDB methods to use const StringName & arguments. * Cache the Window parent in Control because it's used in is_layout_rtl(), which is called often. * Only enable internal processing for viewports that need it. * Change CanvasItem::group to be a StringName because it's only used as that.
2021-07-19Merge pull request #50566 from reduz/optimize-stringname-usageRémi Verschelde
Optimize StringName usage
2021-07-19Merge pull request #48186 from EricEzaM/PR/tooltip-improvementsRémi Verschelde
Made default tooltips (non-custom ones) disappear on mouse enter.
2021-07-18Optimize StringName usagereduz
* Added a new macro SNAME() that constructs and caches a local stringname. * Subsequent usages use the cached version. * Since these use a global static variable, a second refcounter of static usages need to be kept for cleanup time. * Replaced all theme usages by this new macro. * Replace all signal emission usages by this new macro. * Replace all call_deferred usages by this new macro. This is part of ongoing work to optimize GUI and the editor.
2021-07-16Merge pull request #47395 from sygi/shape_idx_collisionHugo Locurcio
Add shape_idx to CollisionObject2D mouse_entered signal
2021-07-03add viewport.get_camera_2d()Josh Chandler
* there is now a more clear distinction between camera_2d and camera_3d functions in the engine code * simplified camera2d's exported interface - now everything happens directly with the 'current' variable and make_current and clear_current are no longer exposed- there were some situations where calling one instead of set_current would result in incomplete results * rebased to current godot master
2021-07-03Fix Render Inforeduz
* Fixed and redone the process to obtain render information from a viewport * Some stats, such as material changes are too difficult to guess on Vulkan, were removed. * Separated visible and shadow stats, which causes confusion. * Texture, buffer and general video memory can be queried now. * Fixed the performance metrics too.
2021-07-02Add mouse_shape_entered and mouse_shape_exited signals to CollisionObject2D.sygi
Co-authored-by: Hugo Locurcio <hugo.locurcio@hugo.pro>
2021-06-29Fixes to 2D viewportreduz
* Editor 2D viewport now uses embedded subwindows (windows no longer pop up) * Restored the ability to disable 3D on the 2D viewport (makes 3D not display on 2D when there is a camera on the scene)
2021-06-29Merge pull request #49719 from LightningAA/rename-node-is-ancestor-ofRémi Verschelde
Rename `is_a_parent_of()` to `is_ancestor_of()`
2021-06-25Remove clips_input() method and use clip_contentkobewi
2021-06-21Rename `is_a_parent_of()` to `is_ancestor_of()`Lightning_A
2021-06-20Use mouse and joypad enums instead of plain integersAaron Franke
Also MIDIMessage
2021-06-19Rename `instance()`->`instantiate()` when it's a verbLightning_A
2021-06-17Add PROPERTY_USAGE_NONE and use itAaron Franke
2021-06-16Refactor VisibilityNotifier3Dreduz
* This is the 3D counterpart to #49632 * Implemented a bit different as 3D works using instancing After merged, both 2D and 3D classes will most likely be renamed in a separate PR to DisplayNotifier2D/3D.
2021-06-16Refactor VisibilityNotifierreduz
* Works from RenderinServer * Accurately tells when on or off-scren, its no longer approximate. * VisibilityEnabler also simplified to use the process mode instead.
2021-06-13Fix Viewport crashes when not in treeHaoyu Qiu
2021-06-05Rename GI Classesreduz
* GIProbe is now VoxelGI * BakedLightmap is now LightmapGI As godot adds more ways to provide GI (as an example, SDFGI in 4.0), the different techniques (which have different pros/cons) need to be properly named to avoid confusion.
2021-06-03Rename Transform to Transform3D in coreAaron Franke
2021-05-25Tweak dozens of editor property hints for consistencyHugo Locurcio
- Update Viewport MSAA property hints to match the currently exposed values. - Add some performance hints to property hints.
2021-05-07Rename "Control" key to "Ctrl" and add "_pressed" suffix to all ↵Lightning_A
InputEventWithModifiers properties/methods
2021-05-06Tweak CanvasItem/material sampling property hints for readabilityHugo Locurcio
The "Anisotropic" term is abbreviated as spelling it out would cause the PopupMenu to overflow the editor window when using the default inspector width.
2021-05-04Merge pull request #48182 from ↵Rémi Verschelde
EricEzaM/PR/fix-viewport-not-updating-mouse-pos-on-click
2021-05-01Move XR flag from subviewport into viewportBastiaan Olij
2021-04-26Made default tooltips (non-custom ones) disappear on mouse enter.EricEzaM
Matches 3.X behaviour, but does not break custom tooltips where mouse interaction is needed.
2021-04-25Fix viewport not updating mouse pos on click.EricEzaM
Closes #47594. See further discussion there. Thanks to @Bhu1-V for the investigation which led to this fix.
2021-04-23Implement occlusion cullingjfons
Added an occlusion culling system with support for static occluder meshes. It can be enabled via `Project Settings > Rendering > Occlusion Culling > Use Occlusion Culling`. Occluders are defined via the new `Occluder3D` resource and instanced using the new `OccluderInstance3D` node. The occluders can also be automatically baked from a scene using the built-in editor plugin.
2021-04-11Use Array for node configuration warningsNathan Franke
Previously, the warnings were passed as a string and delimitation of which were hard coded at each implementation.
2021-04-08Merge pull request #44456 from univeous/allow_input_echo_in_ui_focusRémi Verschelde
allow input echo when changing ui focus
2021-04-05Style: Apply clang-tidy's `readability-braces-around-statements`Rémi Verschelde
2021-04-05Fix crashes in *_input functionsRafał Mikrut
2021-03-28Rename Texture.get_data() to get_image()Marcel Admiraal
2021-03-23Rename ButtonList enum and members to MouseButtonAaron Franke
2021-03-15Allow Navigation to be more flexibleGilles Roudière
2021-03-12Fixes small typos and grammar correctionAnshul7sp1
2021-02-24Fix crash during drag if user freed the drag previewDelf Neumärker
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).