backdrop-blur-wgpu — the wgpu backend for backdrop_blur_core's frosted-glass seam.
It implements [BackdropBlur] with a safe, WGSL pipeline: a separable Gaussian blur for
small radii and dual-Kawase (down/up-sample, the production-compositor algorithm) for large
radii, selected by a radius threshold, followed by a tinted, rounded-rect-masked composite. The
crate is #![forbid(unsafe_code)]; the only place that could want unsafe — the GPU-uniform
Pod impls — uses bytemuck derives.
What the host provides
The own-loop host renders its UI into an offscreen intermediate and hands it to prepare
as a [SourceView] — the texture view plus its size and color space, because a
wgpu::TextureView exposes neither and the backend needs both (the size to clip/scale, the
color space to know whether to sRGB-decode on sample — egui renders gamma-encoded, egui#3168).
The host owns the final Target; the backend owns only the internal
ping-pong scratch.
On error handling
wgpu resource creation (textures, buffers, pipelines) does not return Result — OOM and
validation faults surface through the device's error handler, not synchronously — so this
backend cannot map them to [BlurError::ResourceCreation] without an async error-scope pass
(a candidate refinement). The error it does return synchronously is
[BlurError::UnsupportedTarget], checked against an allowlist before any GPU call.