New issue
Advanced search Search tips

Issue 848839 link

Starred by 3 users

Issue metadata

Status: Fixed
Owner:
Closed: Sep 18
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug



Sign in to add a comment

Fixed-position object with PaintOffsetTranslation doesn't repeat in printing

Project Member Reported by wangxianzhu@chromium.org, Jun 1 2018

Issue description

Test case:
<!DOCTYPE html>
<script>
if (window.testRunner)
  testRunner.setPrinting();
</script>
<div style="height: 3000px">
  <div style="position: fixed; will-change: transform">FIXED</div>
</div>

 
Cc: wangxianzhu@chromium.org
 Issue 848734  has been merged into this issue.

Comment 2 Deleted

Summary: Fixed-position object with PaintOffsetTranslation doesn't repeat in printing (was: Composited fixed-position object without transform doesn't repeat in printing)
Project Member

Comment 4 by bugdroid1@chromium.org, Sep 18

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/29f57056b2ce47b0a0a46e460cb74b36e92fb129

commit 29f57056b2ce47b0a0a46e460cb74b36e92fb129
Author: Xianzhu Wang <wangxianzhu@chromium.org>
Date: Tue Sep 18 23:41:39 2018

[PE] Fix repeating fixed-position with PaintOffsetTranslation

Previously PaintLayerPainter and PaintLayerClipper assumed that all
fragments of an object share the same transform state. This is not true
for repeating fixed-position objects with PaintOffsetTranslation: The
fragments have different PaintOffsetTranslations. Previously we use
infinite clip rect to avoid the problem of incorrect cull rects for
repeated fragments. However, that also caused we painted too much for
each page because of the infinite cull rects, causing slow printing
and too much memory usage.

Changed the following places to calculate correct cull rects for
repeating fixed-position objects:
1. PaintLayerFragment now saves root_fragment_data to indicate its
   coordinate space;
2. PaintLayerPainter::AdjustForPaintProperties() no longer uses
   infinite cull rect when printing;
3. In PaintLayerPainter before painting the LayoutObject,
   cull_rect is adjusted from the border box space of
   |fragment.root_fragment_data| to the containing transform's space;
4. In PaintLayer::CollectFragments(), for each fragment, the input
   dirty rect is adjusted to the current root fragment's border box
   space;
5. PaintLayerClipper::CalculateRectsWithGeometryMapper() is simplified
   to just map using transform states.

Bug:  848839 , 869554 
Cq-Include-Trybots: luci.chromium.try:linux_layout_tests_slimming_paint_v2;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: I6d86e3716e91dbe5422cbf5e58b99fa2282d94dd
Reviewed-on: https://chromium-review.googlesource.com/1090009
Commit-Queue: Xianzhu Wang <wangxianzhu@chromium.org>
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#592261}
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/compositing/massive-scale-interest-rect-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/compositing/overflow/nested-render-surfaces-with-rotation-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/compositing/overflow/scaled-overflow-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/compositing/visibility/visibility-composited-transforms-expected.png
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/compositing/visibility/visibility-composited-transforms-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/fast/frames/frame-set-rotation-hit-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/fast/frames/frame-set-scaling-centered-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/fast/frames/frame-set-scaling-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/fast/frames/frame-set-scaling-rotate-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/fast/frames/frame-set-scaling-skew-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/compositing/geometry/layer-due-to-layer-children-deep-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/compositing/geometry/transfrom-origin-on-zero-size-layer-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/compositing/overflow/scaled-mask-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/css3/blending/background-blend-mode-overlapping-accelerated-elements-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/fast/forms/placeholder-position-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/media/video-layer-crash-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/media/video-zoom-controls-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/svg/hixie/mixed/011-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/svg/transforms/svg-css-transforms-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/svg/zoom/page/zoom-foreignObject-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/svg/zoom/page/zoom-hixie-mixed-008-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/svg/zoom/page/zoom-hixie-mixed-009-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/transforms/2d/compound-transforms-vs-containers-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/transforms/3d/hit-testing/backface-no-transform-hit-test-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/transforms/3d/point-mapping/3d-point-mapping-2-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/transforms/3d/point-mapping/3d-point-mapping-deep-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/transforms/3d/point-mapping/3d-point-mapping-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/transforms/3d/point-mapping/3d-point-mapping-origins-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/transforms/3d/point-mapping/3d-point-mapping-overlapping-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/transforms/3d/point-mapping/3d-point-mapping-preserve-3d-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/transforms/svg-vs-css-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/transforms/transformed-focused-text-input-expected.txt
[delete] https://crrev.com/c341db6c8ccdd6c77c0d61f6379272bb6046ebe5/third_party/WebKit/LayoutTests/platform/linux/virtual/prefer_compositing_to_lcd_text/compositing/overflow/scaled-mask-expected.png
[delete] https://crrev.com/c341db6c8ccdd6c77c0d61f6379272bb6046ebe5/third_party/WebKit/LayoutTests/platform/linux/virtual/prefer_compositing_to_lcd_text/compositing/overflow/scaled-mask-expected.txt
[delete] https://crrev.com/c341db6c8ccdd6c77c0d61f6379272bb6046ebe5/third_party/WebKit/LayoutTests/platform/linux/virtual/video-surface-layer/media/video-layer-crash-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/linux/virtual/video-surface-layer/media/video-zoom-controls-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac-mac10.10/fast/forms/placeholder-position-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac-mac10.11/fast/forms/placeholder-position-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/compositing/geometry/layer-due-to-layer-children-deep-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/compositing/geometry/transfrom-origin-on-zero-size-layer-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/compositing/overflow/mask-with-filter-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/compositing/overflow/scaled-mask-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/css3/blending/background-blend-mode-overlapping-accelerated-elements-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/fast/forms/placeholder-position-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/media/video-layer-crash-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/media/video-zoom-controls-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/svg/hixie/mixed/011-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/svg/transforms/svg-css-transforms-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/svg/zoom/page/zoom-foreignObject-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/svg/zoom/page/zoom-hixie-mixed-008-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/svg/zoom/page/zoom-hixie-mixed-009-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/transforms/2d/compound-transforms-vs-containers-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/transforms/3d/hit-testing/backface-no-transform-hit-test-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/transforms/3d/point-mapping/3d-point-mapping-2-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/transforms/3d/point-mapping/3d-point-mapping-deep-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/transforms/3d/point-mapping/3d-point-mapping-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/transforms/3d/point-mapping/3d-point-mapping-origins-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/transforms/3d/point-mapping/3d-point-mapping-overlapping-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/transforms/3d/point-mapping/3d-point-mapping-preserve-3d-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/transforms/svg-vs-css-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/transforms/transformed-focused-text-input-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/mac/virtual/video-surface-layer/media/video-zoom-controls-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/compositing/geometry/layer-due-to-layer-children-deep-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/compositing/geometry/transfrom-origin-on-zero-size-layer-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/compositing/overflow/mask-with-filter-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/compositing/overflow/scaled-mask-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/css3/blending/background-blend-mode-overlapping-accelerated-elements-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/fast/forms/placeholder-position-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/media/video-layer-crash-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/media/video-zoom-controls-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/svg/hixie/mixed/011-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/svg/transforms/svg-css-transforms-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/svg/zoom/page/zoom-foreignObject-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/svg/zoom/page/zoom-hixie-mixed-008-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/svg/zoom/page/zoom-hixie-mixed-009-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/transforms/2d/compound-transforms-vs-containers-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/transforms/3d/hit-testing/backface-no-transform-hit-test-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/transforms/3d/point-mapping/3d-point-mapping-2-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/transforms/3d/point-mapping/3d-point-mapping-deep-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/transforms/3d/point-mapping/3d-point-mapping-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/transforms/3d/point-mapping/3d-point-mapping-origins-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/transforms/3d/point-mapping/3d-point-mapping-overlapping-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/transforms/3d/point-mapping/3d-point-mapping-preserve-3d-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/transforms/svg-vs-css-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/transforms/transformed-focused-text-input-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/platform/win/virtual/video-surface-layer/media/video-zoom-controls-expected.txt
[add] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/printing/fixed-positioned-composited-expected.html
[add] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/printing/fixed-positioned-composited.html
[add] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/printing/fixed-positioned-overflow-scroll-expected.html
[add] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/printing/fixed-positioned-overflow-scroll.html
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/WebKit/LayoutTests/svg/zoom/page/zoom-foreign-content-expected.txt
[delete] https://crrev.com/c341db6c8ccdd6c77c0d61f6379272bb6046ebe5/third_party/WebKit/LayoutTests/virtual/threaded/compositing/visibility/visibility-composited-transforms-expected.txt
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/blink/renderer/core/paint/fragment_data.cc
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/blink/renderer/core/paint/fragment_data.h
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/blink/renderer/core/paint/paint_layer.cc
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/blink/renderer/core/paint/paint_layer_clipper.cc
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/blink/renderer/core/paint/paint_layer_fragment.h
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/blink/renderer/core/paint/paint_layer_painter.cc
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/blink/renderer/core/paint/paint_layer_painter.h
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/blink/renderer/platform/graphics/paint/geometry_mapper.cc
[modify] https://crrev.com/29f57056b2ce47b0a0a46e460cb74b36e92fb129/third_party/blink/renderer/platform/graphics/paint/geometry_mapper.h

Status: Fixed (was: Assigned)

Sign in to add a comment