Commit Graph

199 Commits

Author SHA1 Message Date
sotaro
77ea89c3a7 Bug 1335335 - Manually call DidComposite() when transaction was dropped because of obsoleted command r=nical
The patch fixes a problem on windows. Before the patch, there was a case that moved tab was not re-rendered. When WebRenderBridgeParent reveived obsolted transaction, DidComposite() was not returned to a client side. It stopped nsRefreshDriver to trigger a next transaction.
2017-06-29 18:06:31 -07:00
sotaro
55343dcb33 Bug 1335335 - Tab move between different windows does not work when e10s is enabled r=nical
When the tab move happens, related non-root WebRenderBridgeParent is updated as to render to different webrender instance. webrender does not support of sharing resources and keys yet. Then when the tab move happens, the patch just removes all keys and resources that belongs to previous webrender. Ideally all resources that belong to WebRenderBridgeParent should be reallocated in an update webrender. But the patch does not do it, instead it just request WebRenderBridgeChild to re-allocate all resources again for simplicity. Performance improvement will happen in a future patch.

This patch support only tab move that uses only raw data external images. Support of native texture external images will happen in a future patch.
2017-06-29 18:06:11 -07:00
Sebastian Hengst
47b6b8ba11 Backed out changeset ac18f9244933 (bug 1335335) for build bustage: version control conflict in maker file at WebRenderBridgeParent.h:235. r=backout on a CLOSED TREE 2017-06-29 22:02:16 +02:00
Sebastian Hengst
a56282d8cf Backed out changeset c5dbfdc1892e (bug 1335335) 2017-06-29 22:01:19 +02:00
sotaro
e364c11354 Bug 1335335 - Manually call DidComposite() when transaction was dropped because of obsoleted command r=nical
The patch fixes a problem on windows. Before the patch, there was a case that moved tab was not re-rendered. When WebRenderBridgeParent reveived obsolted transaction, DidComposite() was not returned to a client side. It stopped nsRefreshDriver to trigger a next transaction.
2017-06-29 12:45:29 -07:00
sotaro
af0d40cb32 Bug 1335335 - Tab move between different windows does not work when e10s is enabled r=nical
When the tab move happens, related non-root WebRenderBridgeParent is updated as to render to different webrender instance. webrender does not support of sharing resources and keys yet. Then when the tab move happens, the patch just removes all keys and resources that belongs to previous webrender. Ideally all resources that belong to WebRenderBridgeParent should be reallocated in an update webrender. But the patch does not do it, instead it just request WebRenderBridgeChild to re-allocate all resources again for simplicity. Performance improvement will happen in a future patch.

This patch support only tab move that uses only raw data external images. Support of native texture external images will happen in a future patch.
2017-06-29 12:44:53 -07:00
sotaro
b86b77c60c Bug 1377024 - Add support of device reset test from about:support r=kats,dvander 2017-06-29 11:46:36 -07:00
Carsten "Tomcat" Book
dff92b2a3c merge mozilla-inbound to mozilla-central a=merge 2017-06-29 15:47:04 +02:00
Ryan Hunt
319c8bc0eb Bug 1376997 - Use the correct focus target in WebRenderBridgeParent::UpdateAPZ. r=kats
MozReview-Commit-ID: AXt28gZ3jdi
2017-06-28 20:00:48 -04:00
Carsten "Tomcat" Book
2ac538b0f1 Merge mozilla-central to autoland 2017-06-28 13:47:29 +02:00
Kartikaya Gupta
9234e5ed6c Bug 1375497 - Implement some more PLayerTransaction testing APIs in PWebRenderBridge. r=pchang
MozReview-Commit-ID: Em4VROmcUx0
2017-06-27 20:29:06 -04:00
Kartikaya Gupta
d6edadcff8 Bug 1375497 - Make sure the WebRenderBridgeParent respects the testing time set in the CompositorBridgeParent. r=pchang
This allows testing code control over the animation steps running over in the
compositor, which is needed for the OMTA mochitests.

MozReview-Commit-ID: CXJcieSEoRl
2017-06-27 20:29:05 -04:00
Ryan Hunt
3eb832e2a9 Bug 1351783 part 11 - Sync FocusTarget with WebRenderLayerManager. r=kats
MozReview-Commit-ID: LxWt22XY5IE
2017-06-13 02:43:59 -04:00
sotaro
cbeb0b9987 Bug 1372512 - Fix webrender Key leaks of WebRenderBridgeParent on abnormal shutdown r=kats
This bug handles abnormal client shut down case and Tab move between different windows.

Abnormal client shut down case, WebRenderBridgeParent does not receive IPC messages that are sent during WebRenderLayerManager and WebRenderBridgeChild destruction. In this case, webrender keys except keys of external images are not removed from webrender. Abnormal shut down could happen when content process was crashed or content process was killed by ContentParent if shutdown takes too long time.

In the tab move case, the WebRenderBridgeParent will need to be re-bound to a different CompositorBridgeParent and webrender, and so will need to clear all its related keys from the old webrender. This will happen in a future patch.
2017-06-16 15:31:01 +09:00
Sebastian Hengst
520b34f142 merge mozilla-inbound to mozilla-central. r=merge a=merge
MozReview-Commit-ID: HYo8pUZXJ8Z
2017-06-15 20:12:28 +02:00
Kartikaya Gupta
54c871714b Bug 1372603 - Move the clip rect for async images outside the iframe item. r=jrmuizel,sotaro
The async images codepath is a bit different in that it pushes an iframe
item to the WR display list and updates it asynchronously. However in
this case it still makes sense to push the layer's local clip
outside the iframe, and just populate the iframe with the image and not
worry about clips inside the iframe. As mentioned in part 1 of this
patchset, this will be needed to properly handle async scrolling.

This patch makes the necessary changes to push the clip outside the
iframe and simplifies what happens in WebRenderCompositableHolder to
generate the display list for the iframe itself.

MozReview-Commit-ID: DeZElH4p4rc
2017-06-14 15:43:16 -04:00
sotaro
72190b99b4 Bug 1372066 - Fix animations leak on abnormal shutdown and tab move between different windows r=kats
This bug handles abnormal client shut down case and Tab move between different windows.

Abnormal client shut down case, WebRenderBridgeParent does not receive IPC messages that are sent during WebRenderLayerManager and WebRenderBridgeChild destruction. In this case, animations under the WebRenderBridgeChild are not removed from CompositorAnimationStorage. Abnormal shut down could happen when content process was crashed or content process was killed by ContentParent if shutdown takes too long time.

In the tab move case, the WebRenderBridgeParent will need to be re-bound to a different CompositorBridgeParent and CompositorAnimationStorage, and so will need to clear all its active animations from the old CompositorAnimationStorage and add animations into the new CompositorAnimationStorage. This will happen in a future patch.
2017-06-15 16:36:03 +09:00
sotaro
cd02396043 Bug 1372816 - Send WebRenderParentCommands When EmptyTransaction is aborted r=jrmuizel 2017-06-15 13:38:22 +09:00
Nicholas Nethercote
9ae0762bf5 Bug 1370329 (part 1) - Clean up the profiler's RAII classes. r=mstange.
This patch does the following renamings, which increase consistency.

- GeckoProfilerInitRAII -> AutoProfilerInit
- GeckoProfilerThread{Sleep,Wake}RAII -> AutoProfilerThread{Sleep,Wake}
- GeckoProfilerTracingRAII -> AutoProfilerTracing
- AutoProfilerRegister -> AutoProfilerRegisterThread
- ProfilerStackFrameRAII -> AutoProfilerLabel
- nsJSUtils::mProfilerRAII -> nsJSUtils::mAutoProfilerLabel

Plus a few other minor ones (e.g. local variables).

The patch also add MOZ_GUARD_OBJECT macros to all the profiler RAII classes
that lack them, and does some minor whitespace reformatting.
2017-06-07 12:33:19 +10:00
peter chang
b4956218d2 Bug 1371114 - Add gecko profiler labels for WebRender, r=kats
MozReview-Commit-ID: 4TRZgV8X1Ml
2017-06-09 11:56:13 +08:00
sotaro
c48002f084 Bug 1370093 - Add mDestroyed checks r=nical 2017-06-05 15:41:21 +09:00
Kartikaya Gupta
5ff3df5354 Bug 1369840 - Support content-side APZ test data in WebRenderLayerManager. r=botond
This mostly just copies the functional parts of the APZTestData code from
ClientLayerManager into WebRenderLayerManager, and propagates the paint sequence
number over to the compositor using the existing WebRenderScrollData machinery.

MozReview-Commit-ID: LHupFpqtWTX
2017-06-04 22:29:35 -04:00
Kartikaya Gupta
18c81fd561 Bug 1369840 - Support getting the compositor-side APZ test data over PWebRenderBridge. r=botond
This is fairly straightforward plumbing. The webrender equivalent of PLayerTransaction
is PWebRenderBridge and we can use that to get the compositor-side APZTestData.

MozReview-Commit-ID: Bn8WjKW5GoI
2017-06-04 22:29:35 -04:00
sotaro
971c53525d Bug 1345054 part 1 - Allocate pipleline for each video r=nical 2017-06-02 16:11:34 +09:00
sotaro
282f4dce52 Bug 1363958 - Fix WebRenderLayerManager::FlushRendering() r=nical 2017-06-02 08:07:59 +09:00
sotaro
a75e042e8b Bug 1368593 - Do not set background color if WebRenderBridgeParent is not root r=jrmuizel 2017-06-01 20:42:55 +09:00
sotaro
4f17b8b871 Bug 1363280 - Fix Updating sImageBridges handling r=dvander,nical 2017-05-31 09:11:53 +09:00
Kartikaya Gupta
e70ce777f4 Bug 1367911 - Extract a GetLayersId() helper. r=dvander
We're calling this often enough that it seems good to extract a named
helper method.

MozReview-Commit-ID: gIwdyfafOq
2017-05-28 07:51:53 -04:00
Kartikaya Gupta
9b5a22ab9b Bug 1367911 - Update APZCCallbackHelper to support WebRender. r=dvander
This allows APZCCallbackHelper to send the SetConfirmedTargetAPZC
message over PWebRenderBridge if webrender is enabled, rather than
assuming the layer manager is a ClientLayerManager and then crashing.

MozReview-Commit-ID: 57o9CaCcbTi
2017-05-28 07:51:51 -04:00
Kartikaya Gupta
d1a74b63a4 Bug 1367837 - Implement some APZ test util APIs for webrender. r=botond,dvander
This implements some methods exposed on DOMWindowUtils and used by
reftests, for the WebRender codepath. The implementation is very similar
to the implementation in LayerTransactionParent.

MozReview-Commit-ID: HP8OxzIzS7P
2017-05-28 07:48:36 -04:00
Kartikaya Gupta
95cf3cb792 Merge m-c to graphics, a=merge
MozReview-Commit-ID: 2pUMxaNAKCC
2017-05-24 08:14:30 -04:00
sotaro
4cb1795076 Bug 1366931 - Fix pipeline id handling of WebRenderBridgeParent::RecvDeleteCompositorAnimations() r=kats 2017-05-24 09:26:29 +09:00
sotaro
133486b089 Bug 1365196 - Throttle GenerateFrame() r=kats,nical 2017-05-19 09:21:38 +09:00
JerryShih
7da00c0549 Bug 1364922 - Create individual imageKey for each channel in the textureClient. v2. r=nical
WebRenderImageLayer will create the proper number of imageKey for different video format. Then, send the imageKey to The WebRenderBridgeParent.

MozReview-Commit-ID: HMp4KWCCFqU
2017-05-19 00:25:42 +08:00
JerryShih
048bee3a55 Bug 1362049 - Add AddWRImage() to call the proper WR commands for all TextureHost types. v3. r=nical
Different TextureHost type could use different WR commands. So, make a abstract interface for these different commands.

MozReview-Commit-ID: 63dnOJC2P9r
2017-05-18 22:59:07 +08:00
Andrew Osmond
0b9cd24de2 Bug 1363347 - Allow multiple external image IDs to be bound to the same image host if owned by the same WRBridge. r=sotaro 2017-05-18 06:50:03 -04:00
sotaro
b7bd95660d Bug 1354198 - Fix WebRenderBridgeParent::RecvShutdown() r=nical 2017-05-18 09:31:46 +09:00
sotaro
f425909489 Bug 1360701 - Remove sync wait during removing pipeline r=nical 2017-05-16 17:28:20 -07:00
sotaro
397ada8d04 Bug 1364302 - Fix HoldExternalImage() handling r=nical 2017-05-15 22:18:54 -07:00
Kartikaya Gupta
aad288ff8a Bug 1363683 - Update webrender to cset 7f37799d63ed80a07675ad599526290843394c99. r=jrmuizel
In addition to updating gfx/webrender and gfx/webrender_traits, this patch:
- Updates the webrender_bindings Cargo.toml file for version bumps
- Updates the Cargo.lock files and revendors the third-party rust dependecies
- Updates the webrender bindings for a change in the display list construction
  and finalization API in WR csets 425155a and 1eb84eb.
  We now have to pass around a content size parameter to construct a display list,
  and we get back a content size from finalizing the display list. Since we pass
  the finalization results over IPC to WebRenderBridgeParent, we need to update
  the IPDL as well to pass this around.
- Updates the webrender bindings for a change to scroll_node_with_id in WR cset
  48a098f.
- Updates the webrender bindings for a change to push_text in WR cset 3287c15.
2017-05-15 15:13:31 -04:00
Kartikaya Gupta
64c4ffcb4d Bug 1361497 - Add a mechanism to push the async scroll data from APZ to WR. r=jrmuizel,botond
This is the WR equivalent (but stripped down to the basics) of the code
in AsyncCompositionManager that advances APZ animations and applies the
async transform to the layer's shadow transform. Currently this doesn't
do anything fancy with the extra scrolling clips, or moving scrollbars,
etc.

MozReview-Commit-ID: BwbNRNHAc6G
2017-05-12 13:58:20 -04:00
Kartikaya Gupta
3ef3ab6d09 Bug 1361497 - Refactoring to simplify getting the root CompositorBridgeParent and APZCTreeManager. r=jrmuizel
This allows for some code reuse in upcoming patches where we need to get
a hold of the APZCTreeManager.

MozReview-Commit-ID: 8oGiGH07fnF
2017-05-12 13:58:17 -04:00
Alexis Beingessner
6ec49a9792 Bug 1361751 - Update gecko bindings to webrender to reflect changes in PR 1181. r=kats
MozReview-Commit-ID: Fxt4sNm4vxa
2017-05-08 13:52:16 -04:00
sotaro
55b75dc83b Bug 1360717 - Make WebRenderCompositableHolder could generate WrImageKey r=nical 2017-05-09 01:19:48 -07:00
peter chang
ab262ee631 Bug 1358437 - pass layer's transform/opacity to compositor, r?kats
Need to pass the default transform/opacity to compositor if animations
exist because it is possible that gecko fails to get animated value
after animation sampling, like an animation with delay.

MozReview-Commit-ID: IK06hWvaSPf
2017-05-02 10:38:22 +08:00
peter chang
fdde04da9f Bug 1357320 - Dispatches the discarded compositor animations id list in one async call, r?kats
MozReview-Commit-ID: 8cCNCzxMKpY
2017-05-02 10:26:13 +08:00
peter chang
da7e930e78 Bug 1357320 - Deal with the lifetime of compositor animations, r?kats
First, hook the Layer's ClearAnimation API to delete unnecessary
animations in next layer transaction. Second, add another async
DeleteCompositorAnimations API to delete animations on the compositor,
especially calling this API before WebRenderLayerManager got destroyed.

MozReview-Commit-ID: 4mbj5IgsXYa
2017-05-02 10:26:13 +08:00
sotaro
11ec0449d5 Bug 1359206 - Fix CompositionTime and CompositeUntil handling of WebRenderImageHost r=nical 2017-04-27 09:34:54 -07:00
Kartikaya Gupta
ed6e5a8d25 Bug 1359842 - Add a StackingContextHelper to reduce duplicated code. r=nical
This class is a RAII class that can be used to push a stacking context
with properties from a WebRenderLayer. It can also then be used to
convert rects in the layer coordinate system to be relative to the
stacking context, which is what we want for passing to WR.

MozReview-Commit-ID: 1WVrfRYqLqc
2017-04-27 12:04:25 -04:00
Lee Salzman
cc97aeac73 Bug 1357952 - update WebRenderAPI to allow index in add_raw_font. r=jrmuizel 2017-04-21 11:50:21 -04:00