-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Open
Labels
A-PickingPointing at and selecting objects of all sortsPointing at and selecting objects of all sortsA-UIGraphical user interfaces, styles, layouts, and widgetsGraphical user interfaces, styles, layouts, and widgetsC-BugAn unexpected or incorrect behaviorAn unexpected or incorrect behaviorS-Needs-InvestigationThis issue requires detective work to figure out what's going wrongThis issue requires detective work to figure out what's going wrong
Description
Bevy version
0.16
What you did
Dragged a Pickable
.
What went wrong
The values of delta
from Pointer<Drag>
vs MouseMotion
are different when a drag starts on Pickable
.
The value via Pointer<Drag>
drifts away in the direction of the drag by a constant multiplier of window.scale_factor()/3.0
, i.e. the drift vanishes if the window.scale_factor
is set to 3
.
Additional information
I have a small demo for this, the code for which can be found here: https://github.com/yatinmaan/drag-test
Notice, in the top left, that the Diff (= drag_delta - mouse_motion) stays near zero when I drag outside the Pickable
.
But when I start the drag on the Pickable
the Diff accumulates error and the Scaled Diff (= drag_delta*window.scale_factor/3 - mouse motion) stays near zero.
drag-test.mp4
Metadata
Metadata
Assignees
Labels
A-PickingPointing at and selecting objects of all sortsPointing at and selecting objects of all sortsA-UIGraphical user interfaces, styles, layouts, and widgetsGraphical user interfaces, styles, layouts, and widgetsC-BugAn unexpected or incorrect behaviorAn unexpected or incorrect behaviorS-Needs-InvestigationThis issue requires detective work to figure out what's going wrongThis issue requires detective work to figure out what's going wrong