Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 574389090c0720faaa03ebe3d431960e05a1dbf3
https://github.com/WebKit/WebKit/commit/574389090c0720faaa03ebe3d431960e05a1dbf3
Author: Carlos Garcia Campos <[email protected]>
Date: 2026-06-19 (Fri, 19 Jun 2026)
Changed paths:
M Source/WebCore/platform/TextureMapper.cmake
M Source/WebCore/platform/graphics/GraphicsLayerContentsDisplayDelegate.cpp
M Source/WebCore/platform/graphics/GraphicsLayerContentsDisplayDelegate.h
M
Source/WebCore/platform/graphics/skia/ImageBufferSkiaAcceleratedBackend.cpp
M Source/WebCore/platform/graphics/skia/SkiaPaintingEngine.h
M
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedImageBackingStore.cpp
M
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedImageBackingStore.h
M
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedPlatformLayer.cpp
M
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedPlatformLayer.h
M
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedPlatformLayerBuffer.h
A
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedPlatformLayerBufferSkiaImage.cpp
A
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedPlatformLayerBufferSkiaImage.h
M
Source/WebCore/platform/graphics/texmap/coordinated/GraphicsLayerAsyncContentsDisplayDelegateCoordinated.cpp
M
Source/WebCore/platform/graphics/texmap/coordinated/GraphicsLayerCoordinated.cpp
M Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.cpp
Log Message:
-----------
[GTK][WPE] Skia compositor: use promise images for layers having a native
image as content
https://bugs.webkit.org/show_bug.cgi?id=317478
Reviewed by Alejandro G. Castro.
For accelerated images we can use a promise image instead of rewrapping,
and for non-accelerated images we can pass the image to the compositor
directly and skia will upload the pixels and reuse internally. This
patch introduces CoordinatedPlatformLayerBufferSkiaImage that is used
instead of CoordinatedPlatformLayerBufferNativeImage when a thread safe
gr context is available.
* Source/WebCore/platform/TextureMapper.cmake:
* Source/WebCore/platform/graphics/GraphicsLayerContentsDisplayDelegate.cpp:
(WebCore::GraphicsLayerContentsDisplayDelegate::setThreadSafeGrContext):
(WebCore::GraphicsLayerContentsDisplayDelegate::threadSafeGrContext const):
* Source/WebCore/platform/graphics/GraphicsLayerContentsDisplayDelegate.h:
* Source/WebCore/platform/graphics/skia/ImageBufferSkiaAcceleratedBackend.cpp:
(WebCore::ImageBufferSkiaAcceleratedBackend::prepareForDisplay):
* Source/WebCore/platform/graphics/skia/SkiaPaintingEngine.h:
(WebCore::SkiaPaintingEngine::threadSafeGrContext const):
*
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedImageBackingStore.cpp:
(WebCore::CoordinatedImageBackingStore::CoordinatedImageBackingStore):
(WebCore::CoordinatedImageBackingStore::create):
(WebCore::CoordinatedImageBackingStore::isSameNativeImage):
*
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedImageBackingStore.h:
*
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedPlatformLayer.cpp:
(WebCore::CoordinatedPlatformLayer::threadSafeGrContext const):
*
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedPlatformLayer.h:
*
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedPlatformLayerBuffer.h:
*
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedPlatformLayerBufferSkiaImage.cpp:
Copied from
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedImageBackingStore.cpp.
(WebCore::CoordinatedPlatformLayerBufferSkiaImage::create):
(WebCore::CoordinatedPlatformLayerBufferSkiaImage::CoordinatedPlatformLayerBufferSkiaImage):
(WebCore::m_image):
(WebCore::CoordinatedPlatformLayerBufferSkiaImage::paintToTextureMapper):
*
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedPlatformLayerBufferSkiaImage.h:
Copied from
Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedPlatformLayerBufferNativeImage.h.
*
Source/WebCore/platform/graphics/texmap/coordinated/GraphicsLayerAsyncContentsDisplayDelegateCoordinated.cpp:
(WebCore::GraphicsLayerAsyncContentsDisplayDelegateCoordinated::tryCopyToLayer):
*
Source/WebCore/platform/graphics/texmap/coordinated/GraphicsLayerCoordinated.cpp:
(WebCore::GraphicsLayerCoordinated::setContentsDisplayDelegate):
(WebCore::GraphicsLayerCoordinated::createAsyncContentsDisplayDelegate):
* Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.cpp:
(WebKit::LayerTreeHost::imageBackingStore):
Canonical link: https://commits.webkit.org/315529@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications