Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Conversation

@bdero
Copy link
Member

@bdero bdero commented May 22, 2023

CP for #42069

@bdero bdero requested a review from zanderso May 22, 2023 19:16
…2069)

Resolves flutter/flutter#126487.

Increases the 2-pass blur quality and distribution limit.

It turns out sigma was breaking down beyond ~255 (moderately high, but
not unreasonable for users to rely on). The Gaussian function computes
sigma^2, and half precision floats only have 5 bit exponents and
overflow for numbers above 65k.

Coincidentally, this also returns us to a state where we look a lot more
like Skia's blurs for larger blur sigmas. Medium blurs have much less
visual banding (although it's still there if you look closely). I
suspect half precision isn't really enough for tracking the integral.

Unfortunately, this means our SIMD pipelining isn't going to be as good.
I'll be interested in watching the blur-driven benchmarks for the perf
hit.

(cherry picked from commit 87a03e1)
@bdero bdero force-pushed the bdero/gaussian-function-cp branch from 3f64879 to 5fa7922 Compare May 22, 2023 19:17
@bdero bdero changed the title [Impeller] Use 32 bit Gaussian function in the 2-pass blur (#42069) [CP] [Impeller] Use 32 bit Gaussian function in the 2-pass blur (#42069) May 22, 2023
@itsjustkevin itsjustkevin added the autosubmit Merge PR when tree becomes green via auto submit App label May 23, 2023
@auto-submit auto-submit bot merged commit d616645 into flutter:flutter-3.10-candidate.1 May 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

autosubmit Merge PR when tree becomes green via auto submit App e: impeller

Projects

No open projects
Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants