Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 774fd3dddd84bda499316f2f8ab5d28b42147e23
https://github.com/WebKit/WebKit/commit/774fd3dddd84bda499316f2f8ab5d28b42147e23
Author: Nikolas Zimmermann <[email protected]>
Date: 2024-11-18 (Mon, 18 Nov 2024)
Changed paths:
M Source/WebCore/platform/graphics/ImageBuffer.cpp
M Source/WebCore/platform/graphics/ImageBuffer.h
M Source/WebCore/platform/graphics/ImageBufferBackend.h
M Source/WebCore/platform/graphics/NativeImage.cpp
M Source/WebCore/platform/graphics/NativeImage.h
M
Source/WebCore/platform/graphics/skia/ImageBufferSkiaAcceleratedBackend.cpp
M Source/WebCore/platform/graphics/skia/ImageBufferSkiaAcceleratedBackend.h
M Source/WebCore/platform/graphics/skia/NativeImageSkia.cpp
Log Message:
-----------
[GTK][WPE][Skia] Add GPU synchronization primitives to
NativeImage/ImageBuffer for Skia
https://bugs.webkit.org/show_bug.cgi?id=283286
Reviewed by Said Abou-Hallawa.
Prepare for threaded GPU rendering: add Skia specific functions
to ImageBuffer(Backend)/NativeImageBackend:
- finishAcceleratedRenderingAndCreateFence()
Used to notify the underlying SkSurface, that it should flush
all pending rendering operations and submit the work to the GPU.
Afterwards inject a fence into the GL command stream, so that we
we can wait upon completion at a later point, before attempting
to use the ImageBuffer/NativeImage.
- waitForAcceleratedRenderingFenceCompletion()
Performs a 'serverWait()' operation on the GLFence, previously
created by finishAcceleratedRenderingAndCreateFence(). This
instructs to GPU to await completion of the previous rendering.
finishAcceleratedRenderingAndCreateFence() will be used during
DisplayList recording, whenever an ImageBuffer/NativeImage resource
is used, upon entering the DisplayList::ResourceHeap cache.
waitForAcceleratedRenderingFenceCompletion() will be used during
DisplayList replaying, whenever an ImageBuffer/NativeImage resource
is extracted from the DisplayList::ResourceHeap cache.
This PR only contains the Skia specific ImageBuffer/NativeImage related
changes -- the hooks in the DisplayList code that make use of these
methods will be added in a separated PR.
No change in functionality for existing tests.
* Source/WebCore/platform/graphics/ImageBuffer.cpp:
(WebCore::ImageBuffer::finishAcceleratedRenderingAndCreateFence):
(WebCore::ImageBuffer::waitForAcceleratedRenderingFenceCompletion):
* Source/WebCore/platform/graphics/ImageBuffer.h:
* Source/WebCore/platform/graphics/ImageBufferBackend.h:
(WebCore::ImageBufferBackend::finishAcceleratedRenderingAndCreateFence):
(WebCore::ImageBufferBackend::waitForAcceleratedRenderingFenceCompletion):
* Source/WebCore/platform/graphics/NativeImage.cpp:
* Source/WebCore/platform/graphics/NativeImage.h:
(WebCore::NativeImageBackend::finishAcceleratedRenderingAndCreateFence):
(WebCore::NativeImageBackend::waitForAcceleratedRenderingFenceCompletion):
* Source/WebCore/platform/graphics/skia/ImageBufferSkiaAcceleratedBackend.cpp:
(WebCore::ImageBufferSkiaAcceleratedBackend::finishAcceleratedRenderingAndCreateFence):
(WebCore::ImageBufferSkiaAcceleratedBackend::waitForAcceleratedRenderingFenceCompletion):
* Source/WebCore/platform/graphics/skia/ImageBufferSkiaAcceleratedBackend.h:
* Source/WebCore/platform/graphics/skia/NativeImageSkia.cpp:
(WebCore::PlatformImageNativeImageBackend::finishAcceleratedRenderingAndCreateFence):
(WebCore::PlatformImageNativeImageBackend::waitForAcceleratedRenderingFenceCompletion):
Canonical link: https://commits.webkit.org/286767@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes