question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[1.0.0][Chrome m79] Gyro not working - device orientation not taken into account

See original GitHub issue

Description:

Device orientation is not taken into account anymore in non-VR mode (aka magic window).

Works on Chrome m78, breaks in m79.

Tested on

  • Pixel 2 (Android 10) with Chrome m78.0
  • Pixel 2 (Android 10) with Chrome m79.0
  • FRD-L09 (Android 7) with Chrome m78.0
  • FRD-L09 (Android 7) with Chrome m79.0
  • Samsung S7 (Android 8) with Chrome m78.0
  • Samsung S7 (Android 8) with Chrome m79.0

Logging the deviceorientation event produces correct result.

document.addEventListener('deviceorientation', console.log);

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:8 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
manititocommented, Dec 18, 2019

If you disable flag “WebXR Device API” m79 - then gyro is working

0reactions
MK-LucidWebcommented, Dec 18, 2019

If you disable flag “WebXR Device API” m79 - then gyro is working

It works if you disable WebXR because then it uses the polyfill. It’s not a proper fix though as you just can’t ask all end users to disable the WebXR API. It’s also counter productive as the goal is to support the actual WebXR spec.

Read more comments on GitHub >

github_iconTop Results From Across the Web

GYRO-WEB: ACCESSING THE DEVICE ORIENTATION IN ...
In Javascript, you may access your device orientation data by listening to the deviceorientation event. It is as easy as the following: window....
Read more >
Gyroscope Issues with Device Orientation - Stack Overflow
The simplest way would be to rotate the resulting rotation matrix by -90 degrees about the x-axis. But you have to be careful...
Read more >
Screen Orientation (Gyroscope) not workin… - Apple Community
I just updated my iPad (9th Gen) to the latest version of iOS 15.5 (two days ago) and since then my Screen Orientation...
Read more >
Window: deviceorientation event - Web APIs | MDN
The deviceorientation event is fired when fresh data is available from an orientation ... This event is not cancelable and does not bubble....
Read more >
Device Orientation - Xamarin - Microsoft Learn
This article explains how to layout Xamarin.Forms applications that look great in portrait and landscape orientations.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found