Граф коммитов

42701 Коммитов

Автор SHA1 Сообщение Дата
Nicolas Silva 5810368294 Bug 1761744 - Better tag frames coming from the async image pipeline manager. r=gfx-reviewers,aosmond
We schedule additional composites as long as there is a CompositeUntil timestamp. These composites need a special tag and shouldn't carry the tags of whatever led us to check the timestamps. In addition, we should add the ASYNC_IMAGE tag when GetAndResetWillGenerateFrame returns true even if some other reason led us to check it.

Depends on D142233

Differential Revision: https://phabricator.services.mozilla.com/D142234
2022-03-29 09:30:56 +00:00
Nicolas Silva 84b0ae8f89 Bug 1761744 - Tag frames caused by the start of observe vsync. r=gfx-reviewers,aosmond
Also tag frames from FlushGenerateFrames.

Depends on D142232

Differential Revision: https://phabricator.services.mozilla.com/D142233
2022-03-29 09:30:55 +00:00
Nicolas Silva 7b8485e486 Bug 1761744 - Tag frames coming from skipped composites. r=gfx-reviewers,aosmond
Also differentiate between skipped composites (too many pending frames) and discarded composites (paused or no display list).

Differential Revision: https://phabricator.services.mozilla.com/D142232
2022-03-29 09:30:55 +00:00
Botond Ballo 5e29e2eee3 Bug 1755490 - Increase POLYGON_CLIP_VERTEX_MAX from 16 to 32. r=gw
Differential Revision: https://phabricator.services.mozilla.com/D142260
2022-03-29 03:12:32 +00:00
sotaro a85bae612a Bug 1760724 - Let video overlay ride the trains to release on intel GPU on Windows r=gfx-reviewers,lsalzman
pref gfx.webrender.dcomp-video-overlay-win-force-enabled was added to enable video overlay even when it is blocked.

Differential Revision: https://phabricator.services.mozilla.com/D141712
2022-03-29 02:47:18 +00:00
Botond Ballo 644d1c7d9d Bug 1761872 - Remove APZSampler::GetGeckoFixedLayerMargins(). r=hiro
APZCTreeManager::GetGeckoFixedLayerMargins() is also removed,
but the field mGeckoFixedLayerMargins is kept as it's used internally
in WebRender codepaths.

Differential Revision: https://phabricator.services.mozilla.com/D142292
2022-03-29 00:33:18 +00:00
Daniel Holbert 88e7f564ee Bug 1761804: Remove checks for NS_COORD_IS_FLOAT, and its associated VERIFY_COORD() function. r=jrmuizel
This patch just assumes NS_COORD_IS_FLOAT is undefined (which in practice it
always is), and deletes dead code accordingly.

It's unlikely we'll migrate nscoord to float anytime soon, so this code isn't
serving much of a purpose at this point.  If we do someday make that migration,
the code that this macro is guarding would only represent a small step in that
migration, anyway; and at that point we can start by adding back the code that
this patch is removing.

In the meantime, it's not worth keeping this complexity and the untested/dead
code in the tree.

Differential Revision: https://phabricator.services.mozilla.com/D142246
2022-03-28 22:20:59 +00:00
Andrew Osmond dfd75c103a Bug 1761832 - Protect GLLibraryEGL singleton against race conditions. r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D142257
2022-03-28 21:16:58 +00:00
David Shin 093b63fe3c Bug 1755770 - Ensure `TextRenderedRun::GetRunUserSpaceRect` casts float to int without invoking Undefined Behavior r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D142223
2022-03-28 21:07:58 +00:00
Marian-Vasile Laza 6080eee972 Backed out changeset 6a067384b1c0 (bug 1751693) for causing wr bustages on Cargo.toml. CLOSED TREE 2022-03-28 00:44:57 -07:00
Bas Schouten 3f4629d024 Bug 1751693: Add telemetry probe to measure glyph rasterization time and the required plumbing for WR. r=nical
Differential Revision: https://phabricator.services.mozilla.com/D140681
2022-03-28 07:21:14 +00:00
Lee Salzman d9a80ab175 Bug 1761685 - Check for negative step in blendTextureNearestRepeat. r=gfx-reviewers,jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D142175
2022-03-28 01:47:58 +00:00
Hiroyuki Ikezoe 90fe3bc201 Bug 1760222 - Test cases for `Ignore unchanged property value for scroll-linked effect detector`. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D141458
2022-03-27 23:40:25 +00:00
Hiroyuki Ikezoe 6b7b8b0942 Bug 1760222 - Detect scroll-linked effects only in the same refresh driver's timestamp. r=botond
With this change, `has-scroll-linked-effect` flag won't persist so that we can
avoid choosing either the one-frame delayed scroll offset or the latest scroll
offset in cases where there's no longer effective scroll linked effect. It will
mitigate scroll jittering.

Differential Revision: https://phabricator.services.mozilla.com/D141457
2022-03-27 23:40:24 +00:00
Timothy Nikkel a87e2f808f Bug 1761239. Use an EnumSet for nsIScrollableFrame::IsScrollAnimating. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D141960
2022-03-26 02:22:57 +00:00
Glenn Watson 7da10101cb Bug 1761299 - Fix raster spatial node indices being out of sync r=gfx-reviewers,nical
When the max surface size is exceeded, the raster spatial node
for a given surface is adjusted in `get_surface_rects`. However
a locally cached variable of the old raster spatial node index
was being used as a parameter when creating the render task.

Instead, only retrieve the raster spatial node after the call to
`get_surface_rects`, ensuring that it gets the updated value.

Also add support to wrench reftests to set the maximum surface
size, so that we can exercise this code path in reftests.

Differential Revision: https://phabricator.services.mozilla.com/D142015
2022-03-25 10:27:38 +00:00
Kelsey Gilbert 5362a1dd62 Bug 1449575 - Don't attempt ColorMask elision in WebGL. r=gfx-reviewers,aosmond
* Always use DoColorMask(u32?, u8) in webgl code.
* Handle OES_draw_buffers_indexed ColorMaski in GLBlitHelper.

Differential Revision: https://phabricator.services.mozilla.com/D141543
2022-03-24 19:39:06 +00:00
Jonathan Kew 6bbbf58763 Bug 1756468 - Add locking to gfxFont, to allow worker threads to do text shaping. r=lsalzman
We protect the shaped-word cache in each font with a RWLock, so that multiple threads can
shape in parallel using cached data; only when a new entry needs to be cached will we need
to take a write lock.

(To improve clarity, this patch also constifys a bunch of methods that do not mutate the
font instance.)

Differential Revision: https://phabricator.services.mozilla.com/D141473
2022-03-24 18:58:00 +00:00
alwu 68dd7e07df Bug 1759033 - no longer start or shutdown MediaFoundation explictly, and ensure the media foundation's life cycle long enough. r=bryce
According to [1], `MFShutdown` will shutdown the media foundation for every other call of `MFStartup`, which means it's possible to shutdown the media foundation even if other components are still using that.

Therefore, we should consider make the media foundation alive when the first time any component wants to use it, and shutdown it when the whole process destroys.

We already did similar thing on the RDD process [2] so it makes sense to do it as well on other places. Especially considering we will move the MFT decoder into the RDD process in the future, we definitely don't want an encoder incorrectly shutdown the media foundation the decoder is using.

Also, it saves time to call `MFStartup` if the media foundation is already started.

[1] https://docs.microsoft.com/en-us/windows/win32/api/mfapi/nf-mfapi-mfshutdown
[2] https://searchfox.org/mozilla-central/rev/eeeba8183d3268e0d563c2becf9f4adc21a37368/dom/media/ipc/RDDParent.cpp#111,303,315

Differential Revision: https://phabricator.services.mozilla.com/D140757
2022-03-24 18:56:16 +00:00
Brad Werth 66f5f1c938 Bug 1751217 Part 2: Change nsDeviceContext::GetDepth to eliminate the outparam. r=emilio
This function always succeeds so there's no reason to maintain an nsresult.

Differential Revision: https://phabricator.services.mozilla.com/D141407
2022-03-24 18:19:49 +00:00
Jonathan Kew 40a7b7fbbd Bug 1759988 - Ensure InitializeCodepointsWithNoFonts() is always called during font-list initialization. r=gfx-reviewers,jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D141953
2022-03-24 14:23:34 +00:00
Cristian Tuns f0ccbd470c Backed out 4 changesets (bug 1760222) for causing reftest failures on disable-apz-for-sle-pages.html CLOSED TREE
Backed out changeset 1bf5e1ca3746 (bug 1760222)
Backed out changeset aff6bf37365d (bug 1760222)
Backed out changeset e9b3e3f52aec (bug 1760222)
Backed out changeset f65d2d719277 (bug 1760222)
2022-03-24 02:36:42 -04:00
Lee Salzman e1069f8d9b Bug 1759891 - Ensure shared font keys have a unique namespace per WebRender instance. r=gw,gfx-reviewers
The blob font tables in Moz2DImageRenderer are currently shared across all WebRender instances.
So if different blob fonts from different WebRender instances happen to share the same font keys,
in particular the same namespace, the font keys can thus accidentally collide and blob fonts can
end up getting shared across WebRender instances unintentionally.

To guard against this, we need to ensure that SharedFontResources is provided with a unique
namespace for the WebRender instance in which to allocate shared font keys so that collisions
can no longer occur.

Differential Revision: https://phabricator.services.mozilla.com/D141929
2022-03-24 03:14:35 +00:00
Butkovits Atila beeff2d22e Backed out changeset 8da43c1bdd49 (bug 1759891) causing Webrender busatges. CLOSED TREE 2022-03-24 05:06:15 +02:00
Lee Salzman e034aaf71b Bug 1759891 - Ensure shared font keys have a unique namespace per WebRender instance. r=gw,gfx-reviewers
The blob font tables in Moz2DImageRenderer are currently shared across all WebRender instances.
So if different blob fonts from different WebRender instances happen to share the same font keys,
in particular the same namespace, the font keys can thus accidentally collide and blob fonts can
end up getting shared across WebRender instances unintentionally.

To guard against this, we need to ensure that SharedFontResources is provided with a unique
namespace for the WebRender instance in which to allocate shared font keys so that collisions
can no longer occur.

Differential Revision: https://phabricator.services.mozilla.com/D141929
2022-03-24 02:42:59 +00:00
Hiroyuki Ikezoe f22d3daeb2 Bug 1760222 - Test cases for `Ignore unchanged property value for scroll-linked effect detector`. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D141458
2022-03-24 02:20:47 +00:00
Hiroyuki Ikezoe dfe4a7e735 Bug 1760222 - Detect scroll-linked effects only in the same refresh driver's timestamp. r=botond
With this change, `has-scroll-linked-effect` flag won't persist so that we can
avoid choosing either the one-frame delayed scroll offset or the latest scroll
offset in cases where there's no longer effective scroll linked effect. It will
mitigate scroll jittering.

Differential Revision: https://phabricator.services.mozilla.com/D141457
2022-03-24 02:20:46 +00:00
Butkovits Atila 131dd31758 Backed out changeset f26f836c1575 (bug 1756468) for causing leakes. CLOSED TREE 2022-03-24 03:28:12 +02:00
sotaro a75b92ee74 Bug 1760618 - Call NotifyChildCreated() after WebRenderBridgeParent::UpdateWebRender() in CompositorBridgeParent::RecvAdoptChild() r=gfx-reviewers,aosmond
In CompositorBridgeParent::RecvAdoptChild(), NotifyChildCreated() is called before WebRenderBridgeParent::UpdateWebRender().  The NotifyChildCreated() updates sIndirectLayerTrees[child].mParent. It affects to WebRenderBridgeParent::GetRootCompositorBridgeParent().

In the UpdateWebRender(), WebRenderBridgeParent::ClearAnimationResources() is called. But in ClearAnimationResources(), OMTASampler is got from new CompositorBridgeParent. In this case, OMTASampler needs to be got from old CompositorBridgeParent.

Differential Revision: https://phabricator.services.mozilla.com/D141819
2022-03-24 00:18:33 +00:00
Timothy Nikkel c2e46664d6 Bug 1695598. Add test. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D107043
2022-03-23 23:58:24 +00:00
Jonathan Kew 5a3bb65719 Bug 1756468 - Add locking to gfxFont, to allow worker threads to do text shaping. r=lsalzman
We protect the shaped-word cache in each font with a RWLock, so that multiple threads can
shape in parallel using cached data; only when a new entry needs to be cached will we need
to take a write lock.

(To improve clarity, this patch also constifys a bunch of methods that do not mutate the
font instance.)

Differential Revision: https://phabricator.services.mozilla.com/D141473
2022-03-23 23:17:34 +00:00
Ryan VanderMeulen d18a71361f Bug 1757738 - Update HarfBuzz to 4.1.0. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D140064
2022-03-23 20:13:18 +00:00
Butkovits Atila fbd6ad4819 Backed out 5 changesets (bug 1751217) for causing failures at dynamic-range.html. CLOSED TREE
Backed out changeset f0a4879c9709 (bug 1751217)
Backed out changeset 50b6310935d4 (bug 1751217)
Backed out changeset bfa455b8bb1a (bug 1751217)
Backed out changeset 277064a1facb (bug 1751217)
Backed out changeset 21e1650b12db (bug 1751217)
2022-03-23 22:22:54 +02:00
Andrew Osmond 3df496f168 Bug 1760887 - Expose FEATURE_VP8_HW_DECODE and FEATURE_VP9_HW_DECODE to the downloadable blocklist. r=gfx-reviewers,jnicol,media-playback-reviewers,alwu
This patch also exposes it as a gfxVar for cross process/thread-safe access.

Differential Revision: https://phabricator.services.mozilla.com/D141803
2022-03-23 19:28:57 +00:00
Brad Werth 09e7757ba7 Bug 1751217 Part 2: Change nsDeviceContext::GetDepth to eliminate the outparam. r=emilio
This function always succeeds so there's no reason to maintain an nsresult.

Differential Revision: https://phabricator.services.mozilla.com/D141407
2022-03-23 18:23:01 +00:00
Emilio Cobos Álvarez 79f3fe026d Bug 1759962 - Don't return the DPI override in devicePixelRatio to privileged code. r=nchevobbe,webdriver-reviewers
Chrome code should be able to rely on CSS pixel * devicePixelRatio =
device pixel.

Chrome code that cares about the override should use
BrowsingContext.overrideDPPX. We were exposing the no-override value in
WindowUtils but that's unneeded now.

Differential Revision: https://phabricator.services.mozilla.com/D141323
2022-03-23 17:03:04 +00:00
Marian-Vasile Laza 77029463ac Backed out 5 changesets (bug 1751217) for causing wpt(Screen-pixelDepth-Screen-colorDepth001.html) and mochitest(test_media_queries.html) failures. CLOSED TREE
Backed out changeset 60a4497fd1f5 (bug 1751217)
Backed out changeset 785f4c5f719d (bug 1751217)
Backed out changeset 81e41f7a1ee4 (bug 1751217)
Backed out changeset d35c5648c936 (bug 1751217)
Backed out changeset f16305c6ec83 (bug 1751217)
2022-03-23 10:11:53 -07:00
Brad Werth 1c5f34a179 Bug 1751217 Part 2: Change nsDeviceContext::GetDepth to eliminate the outparam. r=emilio
This function always succeeds so there's no reason to maintain an nsresult.

Differential Revision: https://phabricator.services.mozilla.com/D141407
2022-03-23 15:24:38 +00:00
Andrew Osmond 78afd0ab38 Bug 1760663 - Add blocklist support for WebGPU. r=gfx-reviewers,nical
This patch just adds the plumbing to allow for baked in blocklist rules
or the downloadable blocklist to prevent certain configurations from
getting WebGPU. It does not add any rules.

It also changes us from allowing WebGPU only in nightly, including
tests, to not release and not beta. This allows try to run the WebGPU
tests as expected, since even try builds forked from mozilla-central are
not considered nightly builds by CI (or so it seems).

Differential Revision: https://phabricator.services.mozilla.com/D141682
2022-03-22 15:22:39 +00:00
Emilio Cobos Álvarez 6804c933e0 Bug 1760567 - Explicitly look for NotoColorEmojiLegacy.ttf in Android font list. r=jfkthame
Unfortunately I couldn't verify this fix myself because the Android 13
image I got doesn't have the described fonts.xml change, nor the legacy
font in /system/fonts, but this should do.

Include the noto color fonts in the standard fonts for the legacy
codepaths too, and avoid a couple string copies and allocations while at
it.

Differential Revision: https://phabricator.services.mozilla.com/D141710
2022-03-22 12:05:05 +00:00
Matteo Ruello 09684f492a Bug 1756529 - Honor general.smoothScroll.[line|page|other] for keyboard scrolls with MSD physics r=botond,hiro
Differential Revision: https://phabricator.services.mozilla.com/D140090
2022-03-22 04:16:32 +00:00
Randell Jesup 08c4fc6891 Bug 1207753 - gfx/layers/apz thread-safety annotations r=botond
Differential Revision: https://phabricator.services.mozilla.com/D131845
2022-03-21 22:58:49 +00:00
Randell Jesup c1b9361c0e Bug 1207753 - gfx & image thread-safety annotations r=gfx-reviewers,aosmond
Differential Revision: https://phabricator.services.mozilla.com/D130600
2022-03-21 18:05:31 +00:00
Randell Jesup 1ca66b0f8c Bug 1207753 - gfx thread-safety annotations r=gfx-reviewers,lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D141608
2022-03-21 16:28:47 +00:00
Jonathan Kew e5cd5e7538 Bug 1756466 - Guard the global gfxFontCache with a RWLock, to allow use from worker threads. r=lsalzman
Replace the "fake" PlaceholderLock in gfxFontCacheExpirationTracker with an actual mutex,
in preparation for accessing the cache (and potentially retiring fonts from the main cache
to the expiration tracker) from worker threads.

Merge gfxFontCacheExpirationTracker into gfxFontCache instead of having it as a separately-
defined private base, which just clutters the code for no benefit.

Add an RWLock to guard the actual font-cache hashtable, to allow simultaneous read access
from multiple threads. We'll only need to take a write lock when updating the cache, but
most usage will just be looking up existing entries, so worker threads need not block each
other (or the main or stylo threads) to do that.

Differential Revision: https://phabricator.services.mozilla.com/D141472
2022-03-20 14:50:29 +00:00
Cristian Tuns b824530498 Backed out changeset 4be195c46471 (bug 1756529) for causing mochitest failures in test_group_keyboard.html CLOSED TREE 2022-03-19 08:40:08 -04:00
Matteo Ruello 2af73856a1 Bug 1756529 - Honor general.smoothScroll.[line|page|other] for keyboard scrolls with MSD physics r=botond,hiro
Differential Revision: https://phabricator.services.mozilla.com/D140090
2022-03-19 06:14:15 +00:00
Botond Ballo b830758f26 Bug 1760379 - Disable paint listener debugging in APZ mochitests. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D141545
2022-03-19 01:14:38 +00:00
sotaro 56ef111fbd Bug 1667303 - video scaling at VideoProcessor for overlay video if possible r=gfx-reviewers,jrmuizel
Video scaling by VideoProcessor is expected to reduce GPU usage.

Differential Revision: https://phabricator.services.mozilla.com/D91392
2022-03-18 14:46:05 +00:00
Botond Ballo 9f64c57d75 Bug 1759958 - Implement ScrollAnimationMSDPhysics::ApplyContentShift() correctly. r=hiro
The previous implementation did not actually change what PositionAt() returns.

Differential Revision: https://phabricator.services.mozilla.com/D141319
2022-03-18 05:13:59 +00:00