Skip to content

WebGPU backend: AcrylicBrush loses the backdrop's hue because Luminosity/Color blends are replaced by SrcOver #25357

Closed

Description

@MartinZikmund

GitHub Issue: n/a

Current behavior

With the WebGPU drawing backend, a translucent AcrylicBrush (here AcrylicInAppFillColorDefaultBrush) over colourful content renders as a dark, nearly flat grey with only a faint hint of the colours behind it. The backdrop is blurred, but the blurred colours are lost. With the default Skia backend the same XAML shows a saturated, blurred version of the shapes behind the panel.

Verified at runtime on Windows desktop (net10.0-desktop SamplesApp, master 0599dad) by screenshot: default backend vs UNO_WEBGPU=1.

Expected behavior

Acrylic should look the same on both backends: blur, then a Luminosity blend with the luminosity colour, then a Color blend with the tint colour (the effect tree AcrylicMaterialBrush builds). WinUI acrylic keeps the hue of the content behind it.

How to reproduce it

  1. Build SamplesApp for net10.0-desktop (it references the WebGPU backend by default).
  2. Add a sample page with this content:
<Grid Background="White" Width="600" Height="300">
    <Rectangle Width="200" Height="200" Fill="Red" HorizontalAlignment="Left" Margin="40,40,0,0" VerticalAlignment="Top" />
    <Ellipse Width="200" Height="200" Fill="Blue" HorizontalAlignment="Left" Margin="200,60,0,0" VerticalAlignment="Top" />
    <Rectangle Width="200" Height="200" Fill="Green" HorizontalAlignment="Left" Margin="360,40,0,0" VerticalAlignment="Top" />
    <Border Width="520" Height="100" Margin="40,100,0,0" HorizontalAlignment="Left" VerticalAlignment="Top"
            Background="{ThemeResource AcrylicInAppFillColorDefaultBrush}" />
</Grid>
  1. Run it with no env var: the panel shows saturated red/blue/green blurred together.
  2. Run it with UNO_WEBGPU=1: the panel is a dark grey with barely visible tint.

Workaround

None known. AlwaysUseFallback gives a flat colour on both backends.

Works on UWP/WinUI

Yes, hue-preserving blurred acrylic.

Environment

Skia Desktop (Win32), WebGPU backend, master 0599dad.

Anything else

Root cause (confirmed by reading the source, matching the runtime result):

  • AcrylicMaterialBrush builds Blend(Blend(Blur(backdrop), lum, Luminosity), tint, Color). Skia applies both blend modes via SkiaDrawingSession.
  • The WebGPU effect lowering throws the blend modes away: WebGpuDrawingFactory.Effects.cs Walk only records the two colours (LumColor, Color) and the blur sigma.
  • The acrylic shader then does mix(blurred.rgb, tint.rgb, tint.a) (a SrcOver) instead of the Luminosity blend, and DrawBackdropTint draws the tint as another SrcOver rect instead of a Color blend. The generic blend shader in the same file already implements modes 25 (Color) and 26 (Luminosity), so they are not wired to the acrylic path.
  • Noise is also a procedural hash (Noise = 0.02f) rather than the acrylic noise texture, and the docs list the noise texture and rounded-corner mask as open gaps for translucent acrylic (doc/uno-drawing-backend-abstraction.md, "Parity gaps").

Suggested fix: apply Luminosity then Color blend (with the existing setLum/setSat helpers) in the acrylic composite instead of SrcOver mixes.

Related WebGPU backend issues: #25330, #25336.

Activity

  1. added
    kind/bug
    triage/untriaged
    area/skia ✏️
    project/shapes-brushes 🔶
    difficulty/medium 🤔
    platform/desktop 🖥️
    7.1
    on Oct 12, 2026
  2. removed
    7.1
    on Oct 29, 2026
  3. added a commit that references this issue on Nov 11, 2026
    8fb1159
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/skia ✏️area/skia/composition ✏️difficulty/medium 🤔kind/bugplatform/desktop 🖥️project/shapes-brushes 🔶triage/untriaged

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions