-
Notifications
You must be signed in to change notification settings - Fork 508
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feedback: "Detect Windows 11 and CPU architecture using User-Agent Client Hints" #2579
Comments
Thank you for reporting the inaccuracy. Let me make sure this is tracked by the team. |
Apparently the latest Windows platform on Hololens 2 is now 15.0.0. Is it also the case for the Windows 11 desktop (no hololens platform). I'm currently relying on this platform version to detect edge is running on hololens, because since some version 112+ of Edge the user agent of Edge is the same for the Windows Hololens 2 platform and the regular Windows Desktop platform. However 15.0.0 is also the platform version when using Edge on the latest Windows 11 on a Desktop (Microsoft Surface), so I'm not able to detect Edge is running on Hololens from the HTTP headers anymore. |
Thank you for the additional detail on this. We have, unfortunately, not been able to work on this issue since you filed it, but this is very useful information. We'll keep it in mind when we find the time to tackle this issue. |
@captainbrosset Well the latest Edge version on Hololens 2 is 117.0.2045.43 while the Edge version on a regular laptop Windows 11 up to date is 117.0.2045.47. But relying on the "117.0.2045.43" version as a condition for "I'm Edge running on Hololens 2" is not a solution. |
Let me try to see if I can get you an answer. |
One thought, although I don't have a hololens device to test, is to test for WebXR support. There might be differences in how the API is implemented/supported across devices. Would the XRInputSource.hand property be available for example? |
That's a possible option, but Edge exists on Android smartphones which would probably have WebXR support. And I wonder if latest Microsoft Surface devices also support WebXR on Edge. But testing for |
Another lead, open https://webglreport.com/?v=2 on both devices and see if there are ways to differentiate the platform. |
Apparently XRInputSource.hand is not supported by any browser yet including Edge |
This OVR_multiview extension (and OVR_multiview2) is about stereo rendering, e.g per eye rendering, and could have been an option. But it's supported by chrome web browser on my workstation, so it's not an option. An Edge extension may allow my website to detect it's browsed from Edge on Hololens by using some part of the extension API, for example the enterprise_hardwarePlatform which is supported according to the Edge documentation. It would not be an ideal solution but better than nothing. Still I'm a bit confused about the user agent: is it possible for Edge to have a distinct user agent on Hololens? There was a difference before version 112. |
@captainbrosset any distinction in the HTTP header sent by Hololens Edge would be very nice. Indeed I really have no other solution than developing an Edge extension to detect it runs from Hololens. For example any specific string like |
@khelkun taking a step back, I never asked why you needed to detect Edge running on Hololens in the first place. It's usually much better to detect the presence of a feature on the web vs. detecting a particular device type. I assume that's not an option for you, but would love to understand why. |
@captainbrosset sorry that I've not explained that in the first place (I thought I did). We have a web portal in which you can click and open a 3D asset viewer implemented as a web app:
Sure, we could somehow put 2 distinct controls (buttons) to let the user choose to launch the web viewer or the hololens viewer in the web portal, but that's not nice, plus the fact that there's many places and shortcuts in the web portal to launch the viewer. So this alternative is not very user friendly in terms of UX. |
Good news. I'm not sure when this will be available in Edge (in theory, should be the next Canary build), but we're adding a new user agent model value for HoloLens. This means that this code: navigator.userAgentData.getHighEntropyValues(["model"]).then(values => {
console.log(values.model);
}); Will now print |
About this part fo the documentation, here is my usage about Hololens detection from Edge:
Afaik Windows platform version is 12.0.0 for "Windows Holographic for Business" which is the current Hololens 2 Windows edition.
Actually the values in "Detecting specific Windows versions" are not accurate. For example my Windows 21H2 Desktop as a value equal to
10.0.0
fornavigator.userAgentData.getHighEntropyValues(["platformVersion"]) .then(r => r.platformVersion)
.Also documenting the Hololens Windows edition would be nice: 12.0.0 for Hololens 2. What about Hololens 1 (11.0.0 ?). What about Windows phones ?
Document Details
⚠ Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.
AB#44527596
The text was updated successfully, but these errors were encountered: