Closed
Bug 903460
Opened 11 years ago
Closed 11 years ago
AsyncCompositionManager applies async transform and CSS transform in the wrong order
Categories
(Core :: Graphics: Layers, defect)
Tracking
()
RESOLVED
DUPLICATE
of bug 732971
mozilla26
People
(Reporter: kats, Assigned: kats)
References
Details
Attachments
(1 file)
9.72 KB,
patch
|
BenWa
:
review+
|
Details | Diff | Splinter Review |
If you have a point P and you want to transform it by gfx3DMatrix A and then by gfx3DMatrix B, it is equivalent to transform it by gfx3DMatrix C, where C = A * B. That is, matrix transformations are applied in the same order as the multiplication order. The code in AsyncCompositionManager combines the async transform from the APZC with the CSS transform on the layer, and sets that as the transform on the shadow layer. However, it does the multiplication in the reverse order, so that the async transform is applied first, when in fact we want the async transform to be applied last.
Assignee | ||
Updated•11 years ago
|
Blocks: multi-apzc
Assignee | ||
Comment 1•11 years ago
|
||
I don't think the fix here is just as simple as reversing the matrices; for an APZC-transformed layer at high resolution, the CSS transform will be 1/resolution, and then the APZC transform will be resolution (plus possibly a translation). Currently the effective cumulative transform is: translation (in layer pixels) * resolution * 1/resolution but swapping the order would make it this: 1/resolution * translation (in layer pixels) * resolution so the translation will need to be changed to LayoutDevicePixels instead of LayerPixels to account for this. I'm currently building a patch to verify that what I'm thinking is correct.
Assignee | ||
Comment 2•11 years ago
|
||
Based on behaviour I saw on the B2G device, I believe my explanation above was correct. This patch fixes it up.
Attachment #788265 -
Flags: review?(bgirard)
Assignee | ||
Comment 3•11 years ago
|
||
https://tbpl.mozilla.org/?tree=Try&rev=995b9da6a130
Updated•11 years ago
|
Attachment #788265 -
Flags: review?(bgirard) → review+
Assignee | ||
Comment 4•11 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/9813b854b713
Comment 5•11 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/9813b854b713
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla26
Assignee | ||
Comment 6•11 years ago
|
||
I must have tested the wrong build on Android or something, because this breaks panning behaviour on Android. It's not obvious to me why yet so I backed out the patch from central. https://hg.mozilla.org/mozilla-central/rev/9ab28833eda0 Unfortunately today's nightly is pretty bad.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 7•11 years ago
|
||
Oh, I think this is because of how on Fennec the resolution is applied on the root layer whereas the scrolling is done on the primary scrollable layer. If the resolution were on the primary scrollable layer it would work, but that needs bug 732971 to be fixed first. Sigh.
Assignee | ||
Comment 8•11 years ago
|
||
I moved this patch over to bug 732971 as they go hand in hand and must be fixed together in order to not regress Fennec behaviour.
Status: REOPENED → RESOLVED
Closed: 11 years ago → 11 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•