Repository navigation
fix(webgpu): Blend acrylic in Luminosity and Color modes - #26303
Merged
MartinZikmund merged 1 commit intoNov 11, 2026
Merged
MartinZikmund merged 1 commit into
MartinZikmund merged 1 commit into
Conversation
The acrylic composite mixed the luminosity colour over the blurred backdrop and drew the tint as a second SrcOver quad, so the dark-theme luminosity (0.96 opaque) flattened any content behind into grey. Apply the Luminosity and Color blends in the composite shader, as Skia does, and share the blend helpers with the generic blend module. Fixes unoplatform#25357 Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Contributor
|
This pull request is merged. |
Contributor
|
🤖 Your WebAssembly Sample App stage site is ready! Visit it here: |
Contributor
|
The build 245313 found UI Test snapshots differences: Details
|
2 of 5 tasks
MartinZikmund
approved these changes
Nov 11, 2026
MartinZikmund
left a comment
Member
There was a problem hiding this comment.
LGTM. Same fix as #26290 (closed in favour of this one), with the blend helpers shared rather than duplicated. The Managed Binaries failure is the WebAssemblyRuntime PackageDiff check, which is unrelated; a rebase or re-run should clear it.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
GitHub Issue: closes #25357
PR Type:
🐞 Bugfix
What changed? 🚀
With the WebGPU backend, a translucent acrylic over colourful content rendered as a flat, dark grey (most visibly with
AcrylicInAppFillColorDefaultBrushin the dark theme, e.g. the DrawingBackends sample in unoplatform/Uno.Samples#966). Skia and WinUI keep the hue of the content behind.Cause:
AcrylicMaterialBrushbuildsBlend(Blend(Blur(backdrop), luminosity, Luminosity), tint, Color). The WebGPU acrylic composite replaced both blends with plain alpha mixes:mix(blurred, luminosity, luminosity.a). The dark-theme luminosity colour is 0.96 opaque, so the backdrop's colour was almost entirely replaced by grey;Fix:
m0slot (only read by the colour-matrix path), so the separate tint quad (DrawBackdropTint) is gone: acrylic is one textured quad after the blur.lum/clipColor/setLumhelpers move out ofCompositeBlendWgslinto a sharedNonSeparableBlendWgslsnippet, prepended to both modules instead of duplicated.For a pure red backdrop under the dark-theme acrylic: before ≈
#302929(grey), after ≈#871818(dark red), matching Skia.Validation
net11.0-desktop):Given_AcrylicBrush6/6 on Skia and 6/6 withUNO_WEBGPU=1;Given_EffectBrush_Parity5/5 on WebGPU. The new test fails on master with WebGPU.PR Checklist ✅
When_AcrylicBrush_Over_Saturated_Content_Keeps_Its_HueScreenshots Compare Test Runresults.🤖 Generated with Claude Code