Bug 231010 - Cocoa GraphicsContextGLOpenGL should not be used by GraphicsContextGLCVANGLE
Summary: Cocoa GraphicsContextGLOpenGL should not be used by GraphicsContextGLCVANGLE
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebGL (show other bugs)
Version: WebKit Local Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Kimmo Kinnunen
URL:
Keywords: InRadar
Depends on:
Blocks: 226504 231009
  Show dependency treegraph
 
Reported: 2021-09-30 01:30 PDT by Kimmo Kinnunen
Modified: 2021-10-01 05:54 PDT (History)
8 users (show)

See Also:


Attachments
Patch (58.82 KB, patch)
2021-09-30 06:33 PDT, Kimmo Kinnunen
no flags Details | Formatted Diff | Diff
Patch (58.55 KB, patch)
2021-09-30 07:05 PDT, Kimmo Kinnunen
no flags Details | Formatted Diff | Diff
Patch (58.54 KB, patch)
2021-09-30 10:01 PDT, Kimmo Kinnunen
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kimmo Kinnunen 2021-09-30 01:30:51 PDT
Cocoa GraphicsContextGLOpenGL should not be used by GraphicsContextGLCVANGLE.
Makes it more complex to develop features related to compositor platform layers, as GraphicsContextGLOpenGL "draws to" a platform layer
but GraphicsContextGLCVANGLE shouldn't have one.
Comment 1 Kimmo Kinnunen 2021-09-30 06:33:30 PDT
Created attachment 439731 [details]
Patch
Comment 2 Kimmo Kinnunen 2021-09-30 07:05:14 PDT
Created attachment 439732 [details]
Patch
Comment 3 Kimmo Kinnunen 2021-09-30 10:01:05 PDT
Created attachment 439747 [details]
Patch
Comment 4 Kenneth Russell 2021-09-30 12:00:16 PDT
Comment on attachment 439747 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=439747&action=review

Since the underlying ANGLE context relationships haven't changed - still creating a separate shared context for video uploads, with the same parameters - this looks good to me. Agree this is just a refactor. The win failure looks like an unrelated flake. r+

> Source/WebCore/platform/graphics/cocoa/ANGLEUtilitiesCocoa.h:37
> +void* createPbufferAndAttachIOSurface(EGLDisplay, EGLConfig, GLenum target, EGLint usageHint, GLenum internalFormat, GLsizei width, GLsizei height, GLenum type, IOSurfaceRef, GLuint plane);

Would it be helpful to put these two free functions in another namespace or as static methods on a class, just to have a little better scoping?
Comment 5 EWS 2021-10-01 05:53:57 PDT
Committed r283362 (242371@main): <https://commits.webkit.org/242371@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 439747 [details].
Comment 6 Radar WebKit Bug Importer 2021-10-01 05:54:31 PDT
<rdar://problem/83762759>