-
Notifications
You must be signed in to change notification settings - Fork 15
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
Allow data to be accessed directly by the GPU #4
Comments
Have you run any experiments of running physics with the CPU using this feature? If the performance is fine and it allows new experiences, we should have it. |
The prototype I have as of now relies on the roundabout way of exposing the data to the GPU (i.e. manually calling gl.TexImage2D() on the buffer returned from the API) and I was consistently getting 30FPS on the Pixel 3 I'm using for testing (note that we're limiting FPS to 30 in our current ARCore implementation). Another approach we could take here is to allow some kind of configuration knob for the devs to opt out of CPU access by extending XRSessionInit dictionary. Something like: navigator.xr.requestSession('immersive-ar', {
requiredFeatures: ['depth-sensing'],
depthSensing: { gpuOnly: true }
}); UAs could treat the |
I think you'd have to put the |
Hm, I was going by the precedent set by the DOM Overlay feature, but we can iron out the specifics once I start drafting the specification for the API. I'll keep this issue open for the time being, we can keep the conversation going if there are still some concerns around efficient GPU access to the depth data. |
Sorry, I overlooked the '|'. Your proposal is fine :-) |
Closing, should be addressed by the latest explainer (by passing |
Splitting @cabanier's question into a new issue:
To me, the main question to answer here is: do we want the data to be accessible by the CPU as well? I'd expect so, because if not, we'll lose out on most (all?) use cases for physics.
The text was updated successfully, but these errors were encountered: