| Summary: | Add support for MTLSharedTextures in WebXR | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Dean Jackson <dino> | ||||||||
| Component: | WebXR | Assignee: | Dean Jackson <dino> | ||||||||
| Status: | RESOLVED FIXED | ||||||||||
| Severity: | Normal | CC: | adachan, ews-watchlist, kondapallykalyan, thorton, webkit-bug-importer | ||||||||
| Priority: | P2 | Keywords: | InRadar | ||||||||
| Version: | WebKit Nightly Build | ||||||||||
| Hardware: | Unspecified | ||||||||||
| OS: | Unspecified | ||||||||||
| Attachments: |
|
||||||||||
|
Description
Dean Jackson
2021-06-21 19:21:15 PDT
Created attachment 431940 [details]
Patch
Comment on attachment 431940 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=431940&action=review > Source/WebCore/Modules/webxr/WebXROpaqueFramebuffer.cpp:143 > + auto size = data.surface->size(); Should we still do the size check for the single plane IOSurface case? > Source/WebCore/Modules/webxr/WebXROpaqueFramebuffer.cpp:198 > + gCGL->destroyPbufferAndDetachIOSurface(m_ioSurfaceTextureHandle); Should we set m_ioSurfaceTextureHandle to null and m_ioSurfaceTextureHandleIsShared to false after? Comment on attachment 431940 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=431940&action=review >> Source/WebCore/Modules/webxr/WebXROpaqueFramebuffer.cpp:143 >> + auto size = data.surface->size(); > > Should we still do the size check for the single plane IOSurface case? Yeah - good point. I'll put it back in. >> Source/WebCore/Modules/webxr/WebXROpaqueFramebuffer.cpp:198 >> + gCGL->destroyPbufferAndDetachIOSurface(m_ioSurfaceTextureHandle); > > Should we set m_ioSurfaceTextureHandle to null and m_ioSurfaceTextureHandleIsShared to false after? Agreed. Ultimately we should have a class that wraps these handles and calls the correct destroyer. I started on that but got annoyed that I'd have to keep a reference to the GraphicsContextGL as well as the handle. Created attachment 432288 [details]
EWS test
Created attachment 432289 [details]
EWS test 2
Committed r279298 (239174@main): <https://commits.webkit.org/239174@main> |