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

41286 Коммитов

Автор SHA1 Сообщение Дата
Jon Bauman bacfba2091 Bug 1725056 - qcms: avoid undefined behavior when handling CICP values. r=jrmuizel,tsmith
Differential Revision: https://phabricator.services.mozilla.com/D122318
2021-08-16 23:13:36 +00:00
Hiroyuki Ikezoe 10263485a1 Bug 1691358 - Add a test to make sure nsIDOMWindowUtils.setResolutionAndScaleTo properly delivered to OOP iframes. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D122661
2021-08-16 21:52:05 +00:00
Jonathan Kew f1d0b4bbe4 Bug 1725940 - patch 2 - Move nsFontCache from the device context to the prescontext. r=emilio
To look up/instantiate platform fonts based on CSS font properties, we create a gfxFontGroup from an nsFont and other attributes; this is currently cached in an nsFontCache attached to the nsDeviceContext.

However, this assumes that the mapping to platform fonts will be the same for all documents using the given device context. In a world where visibility of platform fonts to the page may be restricted, and may depend on the individual document (e.g. if the user disables tracking protection for a particular site), the mapping represented by nsFontCache may vary, and determining how to resolve a given font request will need access to the requesting document in order to know what visibility it is allowed.

To support this, this patch moves the nsFontCache from nsDeviceContext to nsPresContext. In itself, this should cause no visible change in behavior, but it provides a basis for the patches that will follow in bug 1715501.

It's likely that this will have some effects on individual performance tests, depending on the exact content and sequencing of page loads, because of changed caching behavior. E.g. having a per-presContext cache may sometimes mean that we no longer take advantage of a cached gfxFontGroup that a previously-loaded page created; but on the other hand the caches will tend to be smaller and have faster lookups.

My testing so far suggests that we will see some apparent regressions, alongside some improvements, but that overall there should be little change. I'd like to get this change landed separately, before any of the actual font-visibility behavior changes, so that we can more clearly see and isolate any unexpected effects.

Differential Revision: https://phabricator.services.mozilla.com/D122715
2021-08-16 13:58:03 +00:00
Jonathan Kew 6ab15bd8a1 Bug 1725940 - patch 1 - Extract nsFontCache from nsDeviceContext.cpp to its own file. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D122714
2021-08-16 13:58:03 +00:00
Butkovits Atila 5d19838121 Backed out 2 changesets (bug 1692609) for causing failures at test_getUserMedia_addTrackRemoveTrack. CLOSED TREE
Backed out changeset ce4b4f786c4d (bug 1692609)
Backed out changeset d36f5f4ece1e (bug 1692609)
2021-08-16 07:53:47 +03:00
Jeff Gilbert dbf7829bd5 Bug 1692609 - Force 60hz for RFP and use that as the time-atom r=tjr
Differential Revision: https://phabricator.services.mozilla.com/D122045
2021-08-16 03:39:25 +00:00
Glenn Watson 2ae662cff6 Bug 1724846 - Split DL spatial tree to separate payload r=gfx-reviewers,nical
This will allow experimenting with different representations of
the spatial tree (such as interning and/or providing stable
indices during display list building). It may also simplify
future changes to the public API to expose the spatial tree
directly.

As part of these changes, refactor how the debug representation
for the capture format is (de)serialized, to make it simpler to
add different payload vector types in future.

Differential Revision: https://phabricator.services.mozilla.com/D122183
2021-08-15 20:44:03 +00:00
Jeff Gilbert 16e47c00fa Bug 1725714 - Load glTexSubImage3DOES for texture_3D. r=gfx-reviewers,jrmuizel
Also drop support for the 1996 ext EXT_texture3D, particularly since
GLFeature::texture_3D is core in GL1.2.

Differential Revision: https://phabricator.services.mozilla.com/D122644
2021-08-14 00:07:19 +00:00
Markus Stange 193a8de121 Bug 1724433 - Remove special CG text drawing code from DrawTargetSkia. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D122399
2021-08-13 23:08:02 +00:00
Glenn Watson c4ae6a4095 Bug 1723665 - Move coordinate mapping and snapping from scene building to display list building r=aosmond,gfx-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D121591
2021-08-12 23:44:55 +00:00
Andrew Osmond ddabc1b810 Bug 1725388 - Remove pref/envvars that can disable WebRender. r=jrmuizel
MOZ_WEBRENDER=0 now does nothing -- you will either get HW-WR or SW-WR
depending on the platform configuration. The pref
gfx.webrender.force-legacy-layers is removed. This leaves no
configuration option to disable WebRender.

MOZ_WEBRENDER=1 will continue to force WR on, which will ensure in CI we
get HW-WR unless gfx.webrender.software is true.

Differential Revision: https://phabricator.services.mozilla.com/D122474
2021-08-12 20:28:53 +00:00
Iulian Moraru 68dacf122d Backed out 2 changesets (bug 1725388) for causing multiple failures. CLOSED TREE
Backed out changeset cb961c255c8c (bug 1725388)
Backed out changeset 4ee9abeebd43 (bug 1725388)
2021-08-12 19:21:05 +03:00
Andrew Osmond 43a2a6d05e Bug 1725388 - Remove pref/envvars that can disable WebRender. r=jrmuizel
MOZ_WEBRENDER=0 now does nothing -- you will either get HW-WR or SW-WR
depending on the platform configuration. The pref
gfx.webrender.force-legacy-layers is removed. This leaves no
configuration option to disable WebRender.

MOZ_WEBRENDER=1 will continue to force WR on, which will ensure in CI we
get HW-WR unless gfx.webrender.software is true.

Differential Revision: https://phabricator.services.mozilla.com/D122474
2021-08-12 13:54:25 +00:00
Nicolas Silva 2966ad7b5b Bug 1724968 - Make WR profiler less confusing when there was no sample for a while. r=gfx-reviewers,kvark
Before this patch the embedded profiler would show the last avg/max values for a profile counter if it hasn't had samples for a long time. After this patch the counter shows 0 if there was no sample.

For example when no glyphs are rasterized there are no 'Rasterized glyphs' samples. If no glyphs are rasterized for multiple seconds then we are currently still showing the average and max number of rasterized glyphs from seconds ago which makes it look like we are constantly rasterizing glyphs. With this patch the counter goes back to zero after half a second of not rasterizing glyphs.

Differential Revision: https://phabricator.services.mozilla.com/D122263
2021-08-12 12:09:50 +00:00
Lee Salzman 8f08c21f09 Bug 1725304 - Fix tracking of late surfaces for debug overlays in SW-WR. r=gw
Differential Revision: https://phabricator.services.mozilla.com/D122410
2021-08-12 03:37:06 +00:00
Jeff Gilbert 1ab2048d63 Bug 1657189 - Avoid GetFragDataLocation('gl_*') on Mesa. r=gfx-reviewers,lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D122406
2021-08-12 01:35:15 +00:00
Mike Hommey 0b4372e828 Bug 1721968 - Remove support for lucetc for rlbox. r=firefox-build-system-reviewers,shravanrn,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D120700
2021-08-11 21:58:52 +00:00
Andrew Osmond 4a288852e3 Bug 1724794 - Remove Software WebRender allow/blocklist plumbing. r=gfx-reviewers,jrmuizel
We don't use this anymore for anything.

Differential Revision: https://phabricator.services.mozilla.com/D122254
2021-08-11 14:07:02 +00:00
stransky e9207013f4 Bug 1722450 [Wayland] Pause compositor when screen scale changes and content is not updated yet, r=sotaro
We need to track window compositor state in various cases, when compositor is paused after window creation,
when compositor is paused for hidden window (EGLSurface is missing) and paused compositor when layout is not updated yet
and drawing will lead to incorrect / obsoleted window content.

In this patch we track compositor state by WindowCompositorState atomic enum (because it can be accessed from Compositor thread)
and two private methods (PauseCompositorHiddenWindow and ResumeCompositorHiddenWindow) and two public ones (PauseCompositor() and ResumeCompositor).

Private interface is used by nsWindow when EGLSurface is missing so we can't render to window - it's initial compositor pause and
pause when window is hidden.

Public interface is used by nsWindow and WebRender compositor to disable/enable rendering when window content is updated.
When compositor is disabled by public interface it will be enabled automatically after a timeout (1s) or when content layout is updated.

Changes in the patch:

- Implement GtkCompositorWidget::RemoteLayoutSizeUpdated() to notify GtkCompositorWidget widget about layout size update in content process.
- Track nsWindow compositor state by WindowCompositorState
- Implement nsWindow::PauseCompositorHiddenWindow() and ResumeCompositorHiddenWindow() to handle internal nsWindow states.
- Implement nsWindow::PauseCompositor() and nsWindow::ResumeCompositor() to allow compositor pause/resume during content layout updates.
- Use timeout to resume compositor paused by public interface as a fallback when content is not updated or it takes too long.

Differential Revision: https://phabricator.services.mozilla.com/D121650
2021-08-11 07:48:53 +00:00
Butkovits Atila 538569c63f Backed out changeset 97813b0b7f35 (bug 1723665) as requested by dev. CLOSED TREE 2021-08-10 23:04:10 +03:00
Bob Owen 537f72decb Bug 1723214: If BorrowDrawTarget fails in GetTextureClient just return the current front buffer. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D122261
2021-08-10 17:19:29 +00:00
Emilio Cobos Álvarez 59692ca913 Bug 1724907 - Don't use system-ui as a fallback generic. r=jfkthame
As it's usually not very useful. I don't know how easily we can add a
reliable test for this, let me know if you come up with an idea to do
that.

Differential Revision: https://phabricator.services.mozilla.com/D122222
2021-08-10 14:19:04 +00:00
Jamie Nicol 0537af1fe9 Bug 1719345 - Don't invalidate render targets after use on PowerVR. r=gfx-reviewers,jrmuizel
On PowerVR devices we have seen reports of red lines and shapes
appearing randomly on the screen. What is happening is that clip masks
are being rendered in to the RGBA8 texture atlases that were the
previous pass' target, rather than the current R8 render target. Red
shapes therefore appear on top of the cached items in the RGBA texture
atlases, and parts of these subsequently get rendered to picture cache
tiles then the screen.

This appears to be due a bug with glInvalidateFramebuffer. We call
this function once we have finished using a render target for the
frame (ie we have rendered all items which need a clip mask). But
presumably, due to the asynchronicity of OpenGL, the draw calls to
render the clip masks to the render target are in fact still pending
at this point. Perhaps the driver incorrectly recycles the render
target's memory too early, and as a result the masks get written to
the wrong texture.

This patch therefore omits the calls to glInvalidateFramebuffer on
PowerVR devices. While this bug has been hard to reproduce reliably,
it appears to solve the issue.

Differential Revision: https://phabricator.services.mozilla.com/D122221
2021-08-10 13:52:21 +00:00
Jonathan Kew 1f7af5607b Bug 1724795 - Fix leak in cairo-cff-subset (patch from https://gitlab.freedesktop.org/cairo/cairo/-/merge_requests/192, already merged upstream). r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D122201
2021-08-10 13:41:34 +00:00
Matt Woodrow 47d3ec0f72 Bug 1724839 - Add 2d matrix equivalents for transform snapping functions. r=jrmuizel
Depends on D122174

Differential Revision: https://phabricator.services.mozilla.com/D122175
2021-08-10 03:38:42 +00:00
Matt Woodrow 16361eebae Bug 1724839 - Move transform snapping code into gfxUtils. r=jrmuizel
Depends on D122173

Differential Revision: https://phabricator.services.mozilla.com/D122174
2021-08-10 03:38:41 +00:00
Glenn Watson 75728e5f1e Bug 1723665 - Move coordinate mapping and snapping from scene building to display list building r=aosmond,gfx-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D121591
2021-08-10 01:18:52 +00:00
Matt Woodrow ec9b5dd838 Bug 1720152 - Recurse into replay for dependencies, rather than using a temp surface. r=jrmuizel,bobowen,emilio
Differential Revision: https://phabricator.services.mozilla.com/D120050
2021-08-09 22:07:36 +00:00
Mats Palmgren 14c9063444 Bug 1706080 - [css-fonts] Implement 'font-synthesis: small-caps'. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D114313
2021-08-09 21:41:34 +00:00
Glenn Watson af10111513 Bug 1724344 - Split DL cache data into separate payload vec r=gfx-reviewers,kvark
Move the extra_data to be a specific cache_data separate vec in
the display list payload.

This shouldn't change any functionality, but serves as a proof
of concept for future changes which will introduce several other
separated payload vectors.

Differential Revision: https://phabricator.services.mozilla.com/D121937
2021-08-09 21:15:20 +00:00
Gabriele Svelto 559377e821 Bug 1723934 - Remove useless nsExceptionHandler.h inclusions and crash reporter service definitions r=necko-reviewers,dragana
Differential Revision: https://phabricator.services.mozilla.com/D121708
2021-08-09 20:08:17 +00:00
Lee Salzman b164800498 Bug 1711553 - Avoid use of GetRecommendedRenderingMode in Skia. r=jrmuizel
This attempts to emulate the behavior of GetRecommendedRenderingMode without
actually calling it. In addition, it allows some Gecko-specific behavior
like overriding the render mode explicitly that allows some simplification
of the decision-making.

Inside GetRecommendedRenderingMode, natural is only allowed if <= 20 size.
This allows us to thus decide mostly based on whether the size is > 20 or
if an explicit mode was specified. In the remaining case where we need
to check a GASP table if available, we defer to the symmetric flag. If
there is no GASP, we assume natural.

Differential Revision: https://phabricator.services.mozilla.com/D122025
2021-08-09 19:16:16 +00:00
Jonathan Kew 55e3fc6f6e Bug 1723787 - Apply cairo quartz font/surface changes from Andrea Canciani's quartz-colored-glyphs branch at https://gitlab.freedesktop.org/ranma42/cairo/-/commits/quartz-colored-glyphs. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D121909
2021-08-09 14:28:42 +00:00
Brindusan Cristian 29dbbeca6a Backed out changeset b97f1ccfbb1f (bug 1720169) as requested on irc by jnicol for causing performance regressions (Bug 1724678, Bug 1724216).
CLOSED TREE
2021-08-09 13:35:15 +03:00
Nicolas Silva 936f9d9458 Bug 1723076 - Allow larger items in the color cache textures. r=gfx-reviewers,jrmuizel
Before this patch any item that is wider or taller than 512 pixels goes into its own standalone texture. However we often generate linear gradient tasks with a height of 1 pixels and a width between 512 and 1024. Having them in standalone textures wastes a lot of memory and breaks batches. 1024 pixels fits exactly in the linear color cache texture.

Differential Revision: https://phabricator.services.mozilla.com/D121362
2021-08-09 09:23:07 +00:00
Timothy Nikkel 5014725e77 Bug 1678771. Add test. r=hiro
We implement a new nsIDOMWindowUtils function sendNativeTouchpadPan to do this. It is only implemented on Windows here.

Depends on D122048

Differential Revision: https://phabricator.services.mozilla.com/D122049
2021-08-08 22:04:18 +00:00
Ben Hearsum 6f022eadd9 Bug 1714200: skip failing reftests on M1 machines. r=jmaher
Differential Revision: https://phabricator.services.mozilla.com/D121219
2021-08-06 19:16:53 +00:00
Lee Salzman 12a2833e45 Bug 1722054 - Restructure SwCompositeThread synchronization to not rely on job count. r=jrmuizel
This patch aims to address a worst-case theoretical possibility where the job count might for
some reason get out of sync, causing either the SwComposite thread or the main thread to deadlock
waiting on jobs that may never become available.

To this end, we get rid of the job count tracking entirely, and instead just track whether,
first, the SwComposite thread has completed all the jobs that have been queued for it, and,
second, that the main thread, having completed all jobs that were available, is waiting for
jobs to be available or completed such that the SwComposite thread would need to wake it up.
The main thread does not need to wait if it knows the SwComposite thread completed all jobs,
and the SwComposite thread does not need to signal if it knows the main thread is not waiting.

Otherwise stated, so long as both the main and SwComposite threads know there are no more
available jobs, then there is no way compositing can advance any further, and so compositing
must be finished. This avoids relying on having a job count that is always accurate to track
termination.

Differential Revision: https://phabricator.services.mozilla.com/D121821
2021-08-06 16:07:10 +00:00
Jonathan Kew da11a216cc Bug 1724421 - Use template argument deduction to simplify callsites when checking the standard font-family visibility lists. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D122003
2021-08-06 14:06:53 +00:00
Jonathan Kew e9124763a1 Bug 1723874 - Update the list of standard macOS fonts to be current/correct. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D121997
2021-08-06 13:08:15 +00:00
Hiroyuki Ikezoe a0acfbf244 Bug 1724327 - Replace nsLayoutUtils::GetCrossDocParentFrame in CreateAnimationData with nsLayoutUtils::GetCrossDocParentFrameInProcess. r=boris
It's non WebRender specific, so it will not be a problem on Fission,
additionally it's not used on non WebRender with retained display stuff
either.

Differential Revision: https://phabricator.services.mozilla.com/D121929
2021-08-06 00:00:50 +00:00
Jon Bauman 1fbcf87b11 Bug 1634741 - AVIF (AV1 Image File Format): proper color space support. r=aosmond
Differential Revision: https://phabricator.services.mozilla.com/D121764
2021-08-05 15:47:59 +00:00
Bob Owen d22dd863d9 Bug 1698946 p4: Remove remaining old ClearType parameters code. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D120599
2021-08-05 09:13:11 +00:00
Bob Owen b18cd4ec5a Bug 1698946 p3: Change existing code to use DWriteSettings. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D120598
2021-08-05 09:13:11 +00:00
Bob Owen 700da072c4 Bug 1698946 p2: Add DWriteSettings to be used to retrieve font settings. r=jfkthame
This provides settings, which are populated from gfxVars retrieved in the
parent, so that they can be used in all processes.
IDWriteRenderingParams are created lazily, so that we don't try and create them
in processes that have win32k locked down where the API calls will fail.

Differential Revision: https://phabricator.services.mozilla.com/D120597
2021-08-05 09:13:10 +00:00
Bob Owen b81850a8d7 Bug 1698946 p1: Add and maintain ClearType parameters gfxVars. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D120596
2021-08-05 09:13:09 +00:00
Timothy Nikkel 2ed45b7d85 Bug 1724138. Enable apz mochitests on fission + xorigin that are no longer failing. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D121824
2021-08-05 07:42:54 +00:00
Matt Woodrow 4b6db2ad05 Bug 1722258 - Convert more LayerManager usage to use WindowRenderer. r=miko
Differential Revision: https://phabricator.services.mozilla.com/D120920
2021-08-05 06:48:34 +00:00
Timothy Nikkel 86ce161043 Bug 1583955. Re-enable helper_overscroll_behavior_bug1425573.html. r=hiro
It no longer seems to be leaking.

Differential Revision: https://phabricator.services.mozilla.com/D121825
2021-08-05 05:44:58 +00:00
Jon Bauman ad9d5759ea Bug 1723253 - qcms: Add CICP (Coding-independent code points) support. r=jrmuizel
Add CICP-specific functionality

Differential Revision: https://phabricator.services.mozilla.com/D121452
2021-08-05 05:10:37 +00:00