stride3d / stride3d/stride

No input/pointer events for touch devices via UWP

Open
#582 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

area-Input bug
Dominant language
C#
Stars
7.8k
Forks
1.2k
Avg merge
2d 17h
Merged PRs (30d)
49

Description

Release Type: Official Release

Version: 3.1.0.1

Platform(s): Windows 10 UWP (x64 on Win 10 Pro 1909)

Describe the bug
Obviously touch events are not processed correctly in Xenko.Input, even though these should be handled via PointerEvents.

To Reproduce
Steps to reproduce the behavior:

  1. Create new project with Xenko Studio. Choose Samples > Input > Sample: Touch Inputs
  2. At least in my case with Visual Studio 2019 [16.4.2] on Windows 10 1909 I have to set the UWP project's target version to 1809 or 1903, otherwise Microsoft.UniversalCRT dependency cannot be resolved. (The generated project targets 1803 and build fails with "Cannot find SDK "Microsoft.UniversalCRT.Debug", Version=10.0.17134.0")
  3. Build UWP project.
  4. Run TouchInputs app as-is.

Mouse (or track pad) creates all events as expected and shows green (when moving mouse), blue (mouse down) and red dots (mouse up) as well as text for mouse position, events and gestures.
Unfortunately using a touch device (e.g. touch screen of a tablet or 2-in, such as Surface Pro) nearly nothing happens.

When tapping the screen, only a mouse position is generated when releasing the pointer.
No dots at all, no gestures are detected.
Input.PointerEvents is always empty and has only a single entry with PointerEventType.Canceled when releasing the pointer/finger.

This way controlling a game via touch screen is currently completly impossible on Windows 10 UWP.
Double checked with the 3D game sample. Here the button to start game can also be pressed through mouse interaction only. Nothing happens via touch screen.

Expected behavior

Expected behavior would be getting correct pointer/input events also via touch.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Run the Samples > Input > Sample: Touch Inputs project as a UWP app on Windows 10 and compare touch behavior with mouse input. Start by tracing the UWP path around Input.PointerEvents and the sample's event display, then verify that touch taps, movement, release, and gestures produce the expected events in both the touch and 3D game samples.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
game-dev, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.