| Summary: | [WebXR] Provide a way to bind and unbind IOSurfaces to ANGLE Pbuffers | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Dean Jackson <dino> | ||||||
| Component: | WebXR | Assignee: | Dean Jackson <dino> | ||||||
| Status: | RESOLVED FIXED | ||||||||
| Severity: | Normal | CC: | ews-watchlist, graouts, kondapallykalyan, sam, webkit-bug-importer | ||||||
| Priority: | P2 | Keywords: | InRadar | ||||||
| Version: | WebKit Nightly Build | ||||||||
| Hardware: | Unspecified | ||||||||
| OS: | Unspecified | ||||||||
| Attachments: |
|
||||||||
|
Description
Dean Jackson
2021-05-29 13:34:34 PDT
Created attachment 430106 [details]
Patch
Comment on attachment 430106 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=430106&action=review > Source/WebCore/platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm:651 > + auto usageHintAngle = [&] () -> EGLint { > + if (usage == PbufferAttachmentUsage::Read) > + return EGL_IOSURFACE_READ_HINT_ANGLE; > + return EGL_IOSURFACE_WRITE_HINT_ANGLE; > + }(); Never both? > Source/WebCore/platform/graphics/opengl/GraphicsContextGLOpenGL.h:574 > + friend class WebXROpaqueFramebuffer; This is a layering violation. Platform level concepts should not be aware of things like WebXR. Why is this needed? Why not just make this public? > Source/WebCore/platform/graphics/opengl/GraphicsContextGLOpenGL.h:578 > + enum class PbufferAttachmentUsage { > + Read, > + Write > + }; I would put this all on one line. Comment on attachment 430106 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=430106&action=review >> Source/WebCore/platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm:651 >> + }(); > > Never both? Good point. I'll check if ANGLE handles that and add it if so. >> Source/WebCore/platform/graphics/opengl/GraphicsContextGLOpenGL.h:574 >> + friend class WebXROpaqueFramebuffer; > > This is a layering violation. Platform level concepts should not be aware of things like WebXR. Why is this needed? Why not just make this public? Duh, of course. Yeah, I'll make them public. >> Source/WebCore/platform/graphics/opengl/GraphicsContextGLOpenGL.h:578 >> + }; > > I would put this all on one line. ok! Created attachment 430146 [details]
Patch
Committed r278260 (238297@main): <https://commits.webkit.org/238297@main> |