-
Notifications
You must be signed in to change notification settings - Fork 1.6k
[HDR] Gray background appears when switching from Safari tab overview to a tab with HDR images. #47211
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[HDR] Gray background appears when switching from Safari tab overview to a tab with HDR images. #47211
Conversation
EWS run on previous version of this PR (hash b58344e) |
During painting
across what? |
b58344e
to
8bec538
Compare
EWS run on current version of this PR (hash 8bec538) |
… to a tab with HDR images. https://bugs.webkit.org/show_bug.cgi?id=294998 <rdar://154230589> Reviewed by Simon Fraser and Mike Wyrzykowski. Content painted by WebKit gets tonemapped at paint time, so we never want it to be tonemapped again by the system. Changes GraphicContext/RemoteLayerBackingStore to track the max EDR headroom requested during painting, rather than just a bool of whether any draw exceeded the available headroom. Synchronize this value across to the UI process instead of the painted headroom, and set it as the contentHeadroom so that the system knows what the intended headroom is. Set CAToneMapModeNever for these layers, since tonemapping has already been applied. Also fixes a bug where GraphicsContextCG wouldn't call CGContextSetEDRTargetHeadroom if the clamped headroom was 1, even if the image had a higher source headroom. * Source/WebCore/platform/graphics/GraphicsContext.h: (WebCore::GraphicsContext::maxRequestedEDRHeadroom const): (WebCore::GraphicsContext::clearMaxEDRHeadrooms): (WebCore::GraphicsContext::hasPaintedClampedEDRHeadroom const): Deleted. (WebCore::GraphicsContext::clearMaxPaintedEDRHeadroom): Deleted. * Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp: (WebCore::GraphicsContextCG::drawNativeImageInternal): * Source/WebKit/Shared/RemoteLayerTree/RemoteLayerBackingStore.h: * Source/WebKit/Shared/RemoteLayerTree/RemoteLayerBackingStore.mm: (WebKit::RemoteLayerBackingStore::encode const): (WebKit::RemoteLayerBackingStoreProperties::dump const): (WebKit::RemoteLayerBackingStore::setNeedsDisplay): (WebKit::RemoteLayerBackingStore::setNeedsDisplayIfEDRHeadroomExceeds): (WebKit::RemoteLayerBackingStore::setDelegatedContents): (WebKit::RemoteLayerBackingStore::drawInContext): (WebKit::RemoteLayerBackingStoreProperties::applyBackingStoreToLayer): * Source/WebKit/Shared/RemoteLayerTree/RemoteLayerTree.serialization.in: * Source/WebKit/Shared/RemoteLayerTree/RemoteLayerTreePropertyApplier.mm: (WebKit::RemoteLayerTreePropertyApplier::applyPropertiesToLayer): * Source/WebKit/Shared/RemoteLayerTree/RemoteLayerWithRemoteRenderingBackingStore.mm: (WebKit::RemoteLayerWithRemoteRenderingBackingStore::dump const): * Source/WebKit/UIProcess/Cocoa/WebProcessPoolCocoa.mm: (WebKit::WebProcessPool::screenPropertiesChanged): * Source/WebKit/WebProcess/GPU/graphics/RemoteDisplayListRecorderProxy.cpp: (WebKit::RemoteDisplayListRecorderProxy::drawNativeImageInternal): * Source/WebKit/WebProcess/GPU/graphics/RemoteDisplayListRecorderProxy.h: Canonical link: https://commits.webkit.org/296647@main
8bec538
to
e29aed8
Compare
Committed 296647@main (e29aed8): https://commits.webkit.org/296647@main Reviewed commits have been landed. Closing PR #47211 and removing active labels. |
e29aed8
8bec538
🛠 wpe-cairo🧪 mac-AS-debug-wk2🛠 playstation