Closed jonahwilliams closed 2 days ago
I added the compat mode because of https://github.com/flutter/flutter/issues/153964, now it seems to be all fine. Removing all of the compat mode.
The bug should not happen on. v0.4.2 since all of. that "compatibility mode" code was removed
Bug Description
Part of the mesh gradient shader appears to have some sort of either floating point or off by one error that occurs if the gradient is not perfectly aligned with physical pixel coordinates. Specifically this line that applies a color clamp:
Will fire for all of the edge pixels of an anti-aliased shape. I don't think its a floating point precision error, a much more likely explaination is that the bounds computed is slightly off. In fact, to misfire for a single pixel it really only needs to be ever so slightly off.
I'm not sure what this line is intended to do. It looks like the position of the mesh gradient, as determined by the vertex positions, is already correctly computed. But there may be other examples besides the repo ones where this becomes imporant?
I've found that if I just remove this line from the shader, everything with impeller renders fine without the workaround.
Reproduction Steps
Expected Behavior
No response
Screenshots
No response
Additional context
No response