This varying's precision being reduced to mediump in bug bug 1823411
is causing rendering glitches on certain Mali devices. It should never
have been reduced in the first place, as calculations regarding
positions may require the extra precision. This patch therefore
reverts it to highp.
Differential Revision: https://phabricator.services.mozilla.com/D188984
The repeated if-statements in the existing shader code appear to be
miscompiled on certain Adreno 3xx devices. Replacing them with a mix()
statement appears to avoid the bug.
Depends on D188818
Differential Revision: https://phabricator.services.mozilla.com/D188819
Add support for drawing clip masks in the same reference frame as
the raster space without the perspective transform, which fixes
some complex edge cases with nested complex perspective transforms.
Differential Revision: https://phabricator.services.mozilla.com/D187864
This patch removes use of the legacy clip-mask paths for picture
primitives. It makes use of render task sub-pass functionality
to apply the mask directly on top of the picture primitive when
the coordinate systems match (the common case). In the case of
complex transforms it renders them to a screen-space mask which
can be applied by the old clip-mask sampling code. In future,
we'll likely apply these as a sub-pass too.
Differential Revision: https://phabricator.services.mozilla.com/D186638
This adds support for sub-passes to individual render tasks, which
allow subsequent rendering to be configured on top of an existing
render task.
This patch introduces no functional change, it's preparation for
follow up patches.
The follow up patches will make use of this to apply clip masks to
picture primitives directly, where applicable, rather than allocating
a screen-space clip mask and drawing to that.
Differential Revision: https://phabricator.services.mozilla.com/D186614
This switches mask rendering to use an exact local bounds when
the clip is the same coord system as the raster root, and a
conservative estimate when there is a complex transform.
This simplifies the next patch to allow using the new clip-mask
paths for picture rendering (which are always raster roots).
Differential Revision: https://phabricator.services.mozilla.com/D185520
In bug 1843749 we received reports of QCOM_tiled_rendering causing
glitches on Adreno 308 GPUs. As using this extension is a performance
win, especially on less powerful GPUs such as the Adreno 308, we
decided to block it only on the driver versions which we knew were
broken: V@331 and V@415.
However, we have now received a report that it is additionally broken
on version V@0502. As it now seems likely the bug affects all driver
versions, or at least more than originally hoped, this patch blocks
the extension on the Adreno 308 regardless of driver version.
Differential Revision: https://phabricator.services.mozilla.com/D185530
This is rearranging code only, no functional change here. Landing
as a separate patch to make it easier to review the follow up patches
that rely on this change.
Differential Revision: https://phabricator.services.mozilla.com/D185374
Update:
- Glean to v53.1.0
- UniFFI to v0.24.1
- application-services to a recent nightly that uses the above
versions
- Updated `rusqlite` in toolkit/library/rust/shared/Cargo.toml
- Updated `uniffi-bindgen-gecko-js` to work with the new UniFFI. Also
updated it's askama version.
- Vetted new cargo dependencies
Ran `mach uniffi generate` to regenerate the code.
Differential Revision: https://phabricator.services.mozilla.com/D181872
We started using this extension as an optimization on Adreno GPUs in
bug 1828248. At the time, we discovered that there was a driver bug in
version 0490 of the Adreno driver resulting in rendering errors on a
variety of Adreno GPUs. We therefore blocked the usage of the
extension on that driver version.
We have now discovered another bug causing even more apparent
rendering issues. This appears to only affect Adreno 308 GPUs running
driver versions 331 or 415. This patch therefore additionally blocks
the extension on such devices.
Differential Revision: https://phabricator.services.mozilla.com/D184388
Update:
- Glean to v53.1.0
- UniFFI to v0.24.1
- application-services to a recent nightly that uses the above
versions
- Updated `rusqlite` in toolkit/library/rust/shared/Cargo.toml
- Updated `uniffi-bindgen-gecko-js` to work with the new UniFFI. Also
updated it's askama version.
- Vetted new cargo dependencies
Ran `mach uniffi generate` to regenerate the code.
Differential Revision: https://phabricator.services.mozilla.com/D181872
There is still a remaining issue in some cases with the color of
the drop-shadow when moving the slider, but this seems to be a
different problem. This patch fixes the main issue.
Differential Revision: https://phabricator.services.mozilla.com/D183314
Due to quantization and rounding of the linear gradient deltas, if
the amount of stepping due to long horizontal spans exceeds the precision
of the delta, then this can cause calculations to overflow. To avoid this,
break the stepping up into segments that re-quantize the color every so
often.
Differential Revision: https://phabricator.services.mozilla.com/D183568
Add a regression test for picture cache invalidation caused by scrolling
content with opacity-filtered stacking contexts. This test ensures that
picture cache tiles are not invalidated by scrolling when such
sub-pictures are present, which was the problem in bug 1836063.
Depends on D181664
Differential Revision: https://phabricator.services.mozilla.com/D182496
When processing a picture-cache-tile we find the lowest common ancestor
clip of each primitive in the cache-tile and set that as the clip root.
Not only does this save separately applying the clip to each primitive,
it also means we actually draw the parts of the cache tile which are out
of view. This means we don't have to redraw the cache tile every time
more of it scrolls in to view.
This mechanism doesn't work when we have Picture primitives inside a
picture-cache-tile, e.g. for applying a filter. Primitives in the
sub-Picture still had the viewport clip applied and so when the
sub-Picture intersected with the viewport edge we had to redraw the
cache tile on every scroll event.
This diff copies the common-ancestor-clip logic to sub-Picture
primitives. On pages with lots of opacity filtered areas (e.g.
w3schools.com) this eliminates unnecessary cache-tile invalidation and
massively improves scrolling performance on systems with a weak GPU.
Differential Revision: https://phabricator.services.mozilla.com/D181664
Add a regression test for picture cache invalidation caused by scrolling
content with opacity-filtered stacking contexts. This test ensures that
picture cache tiles are not invalidated by scrolling when such
sub-pictures are present, which was the problem in bug 1836063.
Differential Revision: https://phabricator.services.mozilla.com/D182496
When processing a picture-cache-tile we find the lowest common ancestor
clip of each primitive in the cache-tile and set that as the clip root.
Not only does this save separately applying the clip to each primitive,
it also means we actually draw the parts of the cache tile which are out
of view. This means we don't have to redraw the cache tile every time
more of it scrolls in to view.
This mechanism doesn't work when we have Picture primitives inside a
picture-cache-tile, e.g. for applying a filter. Primitives in the
sub-Picture still had the viewport clip applied and so when the
sub-Picture intersected with the viewport edge we had to redraw the
cache tile on every scroll event.
This diff copies the common-ancestor-clip logic to sub-Picture
primitives. On pages with lots of opacity filtered areas (e.g.
w3schools.com) this eliminates unnecessary cache-tile invalidation and
massively improves scrolling performance on systems with a weak GPU.
Differential Revision: https://phabricator.services.mozilla.com/D181664