immersive-web / webxr

Repository for the WebXR Device API Specification.
https://immersive-web.github.io/webxr/
Other
3k stars 386 forks source link

Ultrawide-angle camera access? #1336

Open gabrielwebphy opened 1 year ago

gabrielwebphy commented 1 year ago

It seems that WebXR on mobile is only supported on the primary camera. Enabling the developer to choose which camera (if avaiable) to get the values from would help in different applications that need these special cameras to work properly.

Manishearth commented 1 year ago

AIUI this is an implementor problem, not with the standard, the standard allows implementors to pick the camera however they wish, and they may show a prompt if they want to let the user pick.

We could add camera hints to the session initialization option, but we should get a clear understanding of what axes this should vary along.

gabrielwebphy commented 1 year ago

Wait, so is it possible to let the user (or the developer) pick the camera of their choosing? Or are you saying that it is possible to implement it somehow in the near future? Sorry, I am relatively new to WebXR and didnt fully understand it.

Manishearth commented 1 year ago

It is currently allowed for implementors (web browsers) to let the user pick the camera of their choosing. Whether or not implementors do this is not in the control of the WebXR specification (which is this group), and you should talk to the people who implement the browsers.

If we want to give webapp developers this power to influence the camera that is automatically selected, that could potentially be work this group could do if there was sufficient interest.

AdaRoseCannon commented 1 year ago

It would be possible for a WebXR implementer such as a browser to implement if they chose to. There may still be limits from the platform the browser is on, after a quick search I don't think that right now it's even possible for the wide angle camera to be used with ARCore so it wouldn't be available to WebXR either.