Crate bevy_picking_ui
source ·Expand description
A picking backend for bevy_ui
.
§Usage
This backend does not require markers on cameras or entities to function. It will look for any pointers using the same render target as the UI camera, and run hit tests on the UI node tree.
§Important Note
This backend completely ignores FocusPolicy
. The design of bevy ui’s
focus systems and the picking plugin are not compatible. Instead, use the Pickable
component
to customize how an entity responds to picking focus.
§Implementation Notes
- Bevy ui can only render to the primary window
- Bevy ui can render on any camera with a flag, it is special, and is not tied to a particular camera.
- To correctly sort picks, the order of bevy UI is set to be the camera order plus 0.5.
Modules§
- Commonly used imports for the
bevy_picking_ui
crate.
Structs§
- Adds picking support for
bevy_ui
. - Main query from bevy’s
ui_focus_system
- Automatically generated [
WorldQuery
] item type forNodeQuery
, returned when iterating over query results. - Automatically generated [
WorldQuery
] type for a read-only variant ofNodeQuery
. - Automatically generated [
WorldQuery
] item type forNodeQueryReadOnly
, returned when iterating over query results.
Functions§
- Computes the UI node entities under each pointer.