Bug 237883

Summary: [GTK][WPE] Use GBMBufferSwapchain in GraphicsContextGLTextureMapperANGLE
Product: WebKit Reporter: Zan Dobersek <zan>
Component: New BugsAssignee: Zan Dobersek <zan>
Status: RESOLVED FIXED    
Severity: Normal CC: alex, cmarcelo, dino, ews-watchlist, glenn, jbedard, kondapallykalyan, luiz, webkit-bug-importer, zdobersek
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on: 238322    
Bug Blocks: 237649    
Attachments:
Description Flags
WIP patch
none
WIP patch
none
WIP patch
none
WIP patch
none
Patch
none
Patch for landing none

Zan Dobersek
Reported 2022-03-15 04:20:08 PDT
For each ANGLE-produced WebGL frame, we'd want to retrieve a dmabuf buffer via GBMBufferSwapchain, impose it as the backing for the texture that's being used as the default framebuffer color attachment, and finally push it into the rendering pipeline once the frame is complete. Upon the next frame the swapchain would provide a different buffer, and the cycle repeats.
Attachments
WIP patch (18.07 KB, patch)
2022-03-15 04:21 PDT, Zan Dobersek
no flags
WIP patch (20.82 KB, patch)
2022-03-23 02:07 PDT, Zan Dobersek
no flags
WIP patch (22.75 KB, patch)
2022-03-24 05:19 PDT, Zan Dobersek
no flags
WIP patch (21.14 KB, patch)
2022-03-28 04:36 PDT, Zan Dobersek
no flags
Patch (23.99 KB, patch)
2022-03-28 07:01 PDT, Zan Dobersek
no flags
Patch for landing (24.09 KB, patch)
2022-03-28 22:41 PDT, Zan Dobersek
no flags
Zan Dobersek
Comment 1 2022-03-15 04:21:38 PDT
Created attachment 454692 [details] WIP patch Early, but functions on the most basic WebGL content. It still needs cleanup, proper understanding of what's used in different configurations sharing this code, and how other things like preserved-drawing-buffer affect this.
Zan Dobersek
Comment 2 2022-03-23 02:07:53 PDT
Created attachment 455475 [details] WIP patch
Zan Dobersek
Comment 3 2022-03-24 05:19:45 PDT
Created attachment 455633 [details] WIP patch
Zan Dobersek
Comment 4 2022-03-28 04:36:25 PDT
Created attachment 455901 [details] WIP patch
Zan Dobersek
Comment 5 2022-03-28 07:01:19 PDT
Alejandro G. Castro
Comment 6 2022-03-28 12:55:08 PDT
Comment on attachment 455914 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=455914&action=review LGTM! Just check the unguarded line to make sure we do not break other compilations. > Source/WebCore/platform/graphics/texmap/GraphicsContextGLTextureMapperANGLE.cpp:476 > + m_swapchain.displayBO = WTFMove(m_swapchain.drawBO); This needs to be guarded with the TEXTURE_MAPPER_DMABUF. It is causing the wincairo failure.
Zan Dobersek
Comment 7 2022-03-28 22:41:01 PDT
Created attachment 455994 [details] Patch for landing
EWS
Comment 8 2022-03-29 01:00:44 PDT
Committed r292025 (248968@main): <https://commits.webkit.org/248968@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 455994 [details].
Radar WebKit Bug Importer
Comment 9 2022-03-29 01:01:18 PDT
Note You need to log in before you can comment on or make changes to this bug.