Doing this every frame causes issues for older GPUs with the extra bitmap
creation, copy and destruction. Instead the TextureRecorded now only takes a
snapshot when it is going to cache a data surface to improve getting data back
at the start of a frame.
Differential Revision: https://phabricator.services.mozilla.com/D108500
The parts stay in gradient_shared.glsl are specific to the gradient brushes, dont build without outside of the brsuh infrastructure and will be removed along with the brush gradients. The parts that go into gradient.glsl will be shared between the different gradient render task shaders.
Depends on D108464
Differential Revision: https://phabricator.services.mozilla.com/D108465
It's possible that DMABufSurface::CreateDMABufSurface() fails, for instance when we're running out of file descriptors. In such case mSurface is null
and we need to check it before we use it.
Also implement DMABUFTextureHostOGL::IsValid() to claim mSurface state.
Depends on D107976
Differential Revision: https://phabricator.services.mozilla.com/D107977
There is a bug where if the stride of the default framebuffer is not tightly
packed, such as when we are mapping a smaller dirty region of a larger output
buffer, we can erroneously clear a region of the larger output buffer that
should not be overwritten. This limits the optimization to only happen when
the stride is tightly packed.
Differential Revision: https://phabricator.services.mozilla.com/D108534
This cleans up two issues related to delayed clearing of the default framebuffer.
Firstly, we might accidentally not have resolved the color buffer by the time we
go to actually commit it, so that any delayed clears of the default framebuffer
might get missed. We need to force the color buffer to resolve before we commit
to guarantee there are no delayed clears left.
Secondly, there is a bug where if the stride of the default framebuffer is not
tightly packed, such as when we are mapping a smaller dirty region of a larger
output buffer, we can erroneously clear a region of the larger output buffer
that should not be overwritten. This limits the optimization to only happen
when the stride is tightly packed.
Differential Revision: https://phabricator.services.mozilla.com/D108534
This test is not actually run in CI (disabled via mochitest.ini), so
this has zero effect. Even if it did run, the call to
synthesizeNativeWheelAndWaitForWheelEvent is not passing in a callback
function; it runs the following rAF line immediately. So calling the
function that "waits for the wheel event" is pointless, we can just
call the version that synthesizes the native wheel input and it is
functionally identical.
Depends on D108441
Differential Revision: https://phabricator.services.mozilla.com/D108442
These tests are too annoying to restructure completely, so I'm just
doing a local inlining of the function here.
Depends on D108438
Differential Revision: https://phabricator.services.mozilla.com/D108439
This restructures the test from a callback-style test into an async/await-style
test that is functionally equivalent.
Depends on D108437
Differential Revision: https://phabricator.services.mozilla.com/D108438
This restructures the test from a callback-style test into an async/await-style
test that is functionally equivalent.
Depends on D108436
Differential Revision: https://phabricator.services.mozilla.com/D108437
This restructures the test from a callback-style test into an async/await-style
test that is functionally equivalent.
Depends on D108435
Differential Revision: https://phabricator.services.mozilla.com/D108436
This lets each ModularTransform contain only the data that needs
instead of all of the possible data and will allow for removing
some of the Option wrappers.
Differential Revision: https://phabricator.services.mozilla.com/D108357
This makes things a little simpler at the cost of the Vec<> allocation.
However, it lets us switch to using trait objects because we don't
need a common next_transform field.
Differential Revision: https://phabricator.services.mozilla.com/D108356
When the ID namespace changes for a WebRenderBridgeChild, all bindings
from that namespace are now invalid. We already drop any outstanding
async animation holds on surfaces for recycling, but we still would try
to send out async resource updates that were already queued before the
namespace was changed. This patch forces us to drop those now defunct
transactions.
Differential Revision: https://phabricator.services.mozilla.com/D108481
I think this is what's supposed to happen, otherwise this can cause
invalidation issues because UpdateDrawResult etc for fallback images
becomes a no-op...
Differential Revision: https://phabricator.services.mozilla.com/D108197
Fission without WebRender is an unsupported configuration and enrolls
users based on their compositor. However because of our own rollout of
WebRender, a user might start in early beta with WebRender and lose it
in late beta, while they remain enrolled in the Fission experiment.
Also, a user could lose WebRender because of crashes or device reset,
and we may fall back to Basic.
This patch forces Software WebRender as available (but does not override
Hardware WebRender) if Fission is enabled for users enrolled in the
Fission experiment. It also prevents fallback to Basic layers when
disabling acceleration due to crashes and runtime errors, so the user
will be stuck with Software WebRender at a minimum. It also enables
Software WebRender for Windows popups with transparency.
Differential Revision: https://phabricator.services.mozilla.com/D107661
On some Adreno 3xx devices we have observed that the driver does not
pack varyings in to vectors as efficiently as the spec mandates. This
results in some of our shaders using a greater number of varying
vectors than GL_MAX_VARYING_VECTORS (which 16 on this device), leading
to shader compilation errors at run time.
Work around this by manually packing our varyings in to fewer
vectors. Additionally, add a test to ensure that we never use more
than 16 vectors even if the driver were to perform no additional
packing.
Differential Revision: https://phabricator.services.mozilla.com/D107929
Creating an event with type NSEventTypeSmartMagnify does not work with either NSEvent mouseEventWithType or NSEvent otherEventWithType (they both hit an assert in the appkit code). So the best we can do is call the same function.
Differential Revision: https://phabricator.services.mozilla.com/D107792
We already have a pref for double tap to zoom with is already enabled by default so it's kind of awkward to add another pref.
Differential Revision: https://phabricator.services.mozilla.com/D107389
Bug 1357785 accidentally omitted the flag on the interface itself. This patch makes thing consistent to prevent potential confusion in feature detection.
Differential Revision: https://phabricator.services.mozilla.com/D107742
Windows users on Basic / without D3D11 compositing, with the GPU
process, and with small screens may get Software WebRender on the
late beta and release channel.
Differential Revision: https://phabricator.services.mozilla.com/D107920
Only using sRGB will limit the gamut of XYZ that we explore
which seems to prevent us from finding bug 1697787. Also using the
identity XYZD50 profile should hopefully fix that.
Differential Revision: https://phabricator.services.mozilla.com/D108060
This will allow us to not change these files if we need to change the
rayon version to fix stability issues like bug 1694671.
Differential Revision: https://phabricator.services.mozilla.com/D108042
On some Adreno 3xx devices we have observed that the driver does not
pack varyings in to vectors as efficiently as the spec mandates. This
results in some of our shaders using a greater number of varying
vectors than GL_MAX_VARYING_VECTORS (which 16 on this device), leading
to shader compilation errors at run time.
Work around this by manually packing our varyings in to fewer
vectors. Additionally, add a test to ensure that we never use more
than 16 vectors even if the driver were to perform no additional
packing.
Differential Revision: https://phabricator.services.mozilla.com/D107929
Using `dlsym` for `gdk_wayland_display_get_type` is a cleaner solution
to bug 1696319, allowing running with a GTK that lacks the Wayland
backend.
Also adds a symmetric implementation for `gdk_x11_display_get_type`,
which should help running without X11.
Differential Revision: https://phabricator.services.mozilla.com/D107406
When an offscreen surface establishes a raster root, this code
was causing incorrect snapping / rounded (even on non-inflated
surfaces), resulting in test failures in some cases.
In theory, this should not be necessary, since scroll offsets are
snapped, and primitives are already snapped during scene building.
Additionally, the picture surface allocation code expects surfaces
with fractional offsets and handles this case (by rounding out the
allocation size, and creating a UV set that samples from the subpixel
offsets of the surface).
In practice, there may be content that relies on this which isn't
tested by CI, so let's land this as a separate patch and see if it
causes any real-world content regressions, before landing the
changes that rely on this.
Differential Revision: https://phabricator.services.mozilla.com/D107768