Commit 1f006a4f authored by alokp@chromium.org's avatar alokp@chromium.org

Mark GraphicsLayers as opaque when possible

https://bugs.webkit.org/show_bug.cgi?id=70634

Reviewed by Simon Fraser.

Source/WebCore:

Mark layers as opaque in a very simple case - any child renderer has an opaque background and covers the entire composited bounds. It is important to note that since we only consider the background, the only layer that can be marked opaque is the primary GraphicsLayer of a RenderLayer.

Tests: compositing/contents-opaque/background-clip.html
       compositing/contents-opaque/background-color.html
       compositing/contents-opaque/body-background-painted.html
       compositing/contents-opaque/body-background-skipped.html
       compositing/contents-opaque/layer-opacity.html
       compositing/contents-opaque/layer-transform.html

* rendering/RenderBox.cpp:
(WebCore::skipBodyBackground):
(WebCore):
(WebCore::RenderBox::paintBackground):
(WebCore::RenderBox::backgroundIsKnownToBeOpaqueInRect):
* rendering/RenderBox.h:
(RenderBox):
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::backgroundIsKnownToBeOpaqueInRect):
(WebCore):
(WebCore::RenderLayer::listBackgroundIsKnownToBeOpaqueInRect):
* rendering/RenderLayer.h:
(RenderLayer):
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
* rendering/RenderLayerModelObject.h:
(RenderLayerModelObject):
(WebCore::RenderLayerModelObject::backgroundIsKnownToBeOpaqueInRect):

LayoutTests:

* compositing/absolute-inside-out-of-view-fixed-expected.txt:
* compositing/backing/no-backing-for-clip-expected.txt:
* compositing/backing/no-backing-for-clip-overlap-expected.txt:
* compositing/backing/no-backing-for-perspective-expected.txt:
* compositing/clip-child-by-non-stacking-ancestor-expected.txt:
* compositing/columns/composited-in-paginated-expected.txt:
* compositing/contents-opaque/background-clip-expected.txt: Copied from LayoutTests/platform/chromium/compositing/geometry/limit-layer-bounds-positioned-transition-expected.txt.
* compositing/contents-opaque/background-clip.html: Added.
* compositing/contents-opaque/background-color-expected.txt: Copied from LayoutTests/compositing/geometry/limit-layer-bounds-positioned-expected.txt.
* compositing/contents-opaque/background-color.html: Added.
* compositing/contents-opaque/body-background-painted-expected.txt: Copied from LayoutTests/platform/chromium/platform/chromium/virtual/softwarecompositing/layer-creation/fixed-position-out-of-view-expected.txt.
* compositing/contents-opaque/body-background-painted.html: Added.
* compositing/contents-opaque/body-background-skipped-expected.txt: Copied from LayoutTests/platform/chromium/platform/chromium/virtual/softwarecompositing/layer-creation/fixed-position-out-of-view-expected.txt.
* compositing/contents-opaque/body-background-skipped.html: Added.
* compositing/contents-opaque/layer-opacity-expected.txt: Copied from LayoutTests/compositing/clip-child-by-non-stacking-ancestor-expected.txt.
* compositing/contents-opaque/layer-opacity.html: Added.
* compositing/contents-opaque/layer-transform-expected.txt: Copied from LayoutTests/compositing/clip-child-by-non-stacking-ancestor-expected.txt.
* compositing/contents-opaque/layer-transform.html: Added.
* compositing/filters/sw-layer-overlaps-hw-shadow-expected.txt:
* compositing/filters/sw-shadow-overlaps-hw-layer-expected.txt:
* compositing/geometry/bounds-ignores-hidden-composited-descendant-expected.txt:
* compositing/geometry/bounds-ignores-hidden-dynamic-expected.txt:
* compositing/geometry/bounds-ignores-hidden-dynamic-negzindex-expected.txt:
* compositing/geometry/bounds-ignores-hidden-expected.txt:
* compositing/geometry/clip-expected.txt:
* compositing/geometry/clip-inside-expected.txt:
* compositing/geometry/fixed-position-composited-switch-expected.txt:
* compositing/geometry/flipped-writing-mode-expected.txt:
* compositing/geometry/layer-due-to-layer-children-deep-switch-expected.txt:
* compositing/geometry/layer-due-to-layer-children-switch-expected.txt:
* compositing/geometry/limit-layer-bounds-clipping-ancestor-expected.txt:
* compositing/geometry/limit-layer-bounds-fixed-expected.txt:
* compositing/geometry/limit-layer-bounds-fixed-positioned-expected.txt:
* compositing/geometry/limit-layer-bounds-overflow-root-expected.txt:
* compositing/geometry/limit-layer-bounds-positioned-expected.txt:
* compositing/geometry/limit-layer-bounds-positioned-transition-expected.txt:
* compositing/geometry/limit-layer-bounds-transformed-expected.txt:
* compositing/geometry/limit-layer-bounds-transformed-overflow-expected.txt:
* compositing/geometry/preserve-3d-switching-expected.txt:
* compositing/iframes/become-composited-nested-iframes-expected.txt:
* compositing/iframes/become-overlapped-iframe-expected.txt:
* compositing/iframes/composited-parent-iframe-expected.txt:
* compositing/iframes/connect-compositing-iframe-delayed-expected.txt:
* compositing/iframes/connect-compositing-iframe-expected.txt:
* compositing/iframes/connect-compositing-iframe2-expected.txt:
* compositing/iframes/connect-compositing-iframe3-expected.txt:
* compositing/iframes/enter-compositing-iframe-expected.txt:
* compositing/iframes/iframe-resize-expected.txt:
* compositing/iframes/invisible-nested-iframe-hide-expected.txt:
* compositing/iframes/invisible-nested-iframe-show-expected.txt:
* compositing/iframes/overlapped-iframe-expected.txt:
* compositing/iframes/overlapped-iframe-iframe-expected.txt:
* compositing/iframes/overlapped-nested-iframes-expected.txt:
* compositing/iframes/page-cache-layer-tree-expected.txt:
* compositing/iframes/scrolling-iframe-expected.txt:
* compositing/layer-creation/animation-overlap-with-children-expected.txt:
* compositing/layer-creation/fixed-position-and-transform-expected.txt:
* compositing/layer-creation/fixed-position-change-out-of-view-in-view-expected.txt:
* compositing/layer-creation/fixed-position-out-of-view-expected.txt:
* compositing/layer-creation/fixed-position-out-of-view-scaled-expected.txt:
* compositing/layer-creation/fixed-position-out-of-view-scaled-scroll-expected.txt:
* compositing/layer-creation/fixed-position-under-transform-expected.txt:
* compositing/layer-creation/no-compositing-for-preserve-3d-expected.txt:
* compositing/layer-creation/overflow-scroll-overlap-expected.txt:
* compositing/layer-creation/overlap-animation-clipping-expected.txt:
* compositing/layer-creation/overlap-animation-expected.txt:
* compositing/layer-creation/overlap-child-layer-expected.txt:
* compositing/layer-creation/overlap-clipping-expected.txt:
* compositing/layer-creation/overlap-transformed-3d-expected.txt:
* compositing/layer-creation/overlap-transformed-and-clipped-expected.txt:
* compositing/layer-creation/overlap-transformed-layer-expected.txt:
* compositing/layer-creation/overlap-transformed-preserved-3d-expected.txt:
* compositing/layer-creation/overlap-transforms-expected.txt:
* compositing/layer-creation/spanOverlapsCanvas-expected.txt:
* compositing/layer-creation/stacking-context-overlap-expected.txt:
* compositing/layer-creation/translatez-overlap-expected.txt:
* compositing/masks/mask-layer-size-expected.txt:
* compositing/overflow-trumps-transform-style-expected.txt:
* compositing/overflow/clip-descendents-expected.txt:
* compositing/overflow/composited-scrolling-creates-a-stacking-container-expected.txt:
* compositing/overflow/textarea-scroll-touch-expected.txt:
* compositing/plugins/no-backing-store-expected.txt:
* compositing/repaint/invalidations-on-composited-layers-expected.txt:
* compositing/rtl/rtl-absolute-expected.txt:
* compositing/rtl/rtl-absolute-overflow-expected.txt:
* compositing/rtl/rtl-absolute-overflow-scrolled-expected.txt:
* compositing/rtl/rtl-fixed-expected.txt:
* compositing/rtl/rtl-fixed-overflow-expected.txt:
* compositing/rtl/rtl-fixed-overflow-scrolled-expected.txt:
* compositing/rtl/rtl-iframe-absolute-expected.txt:
* compositing/rtl/rtl-iframe-fixed-expected.txt:
* compositing/rtl/rtl-iframe-relative-expected.txt:
* compositing/rtl/rtl-relative-expected.txt:
* compositing/tiled-layers-hidpi-expected.txt:
* compositing/tiling/backface-preserve-3d-tiled-expected.txt:
* compositing/tiling/crash-reparent-tiled-layer-expected.txt:
* compositing/tiling/huge-layer-add-remove-child-expected.txt:
* compositing/tiling/huge-layer-with-layer-children-expected.txt:
* compositing/tiling/huge-layer-with-layer-children-resize-expected.txt:
* compositing/tiling/rotated-tiled-clamped-expected.txt:
* compositing/tiling/rotated-tiled-preserve3d-clamped-expected.txt:
* compositing/tiling/tile-cache-zoomed-expected.txt:
* compositing/tiling/tiled-layer-resize-expected.txt:
* compositing/visible-rect/2d-transformed-expected.txt:
* compositing/visible-rect/3d-transform-style-expected.txt:
* compositing/visible-rect/3d-transformed-expected.txt:
* compositing/visible-rect/animated-expected.txt:
* compositing/visible-rect/animated-from-none-expected.txt:
* compositing/visible-rect/clipped-by-viewport-expected.txt:
* compositing/visible-rect/clipped-visible-rect-expected.txt:
* compositing/visible-rect/iframe-and-layers-expected.txt:
* compositing/visible-rect/iframe-no-layers-expected.txt:
* compositing/visible-rect/nested-transform-expected.txt:
* compositing/visible-rect/scrolled-expected.txt:
* css3/filters/filtered-compositing-descendant-expected.txt:
* platform/chromium-linux-x86/compositing/geometry/bounds-ignores-hidden-composited-descendant-expected.txt:
* platform/chromium-linux-x86/compositing/geometry/bounds-ignores-hidden-dynamic-negzindex-expected.txt:
* platform/chromium-linux-x86/platform/chromium/virtual/softwarecompositing/rtl/rtl-fixed-overflow-scrolled-expected.txt:
* platform/chromium-linux-x86/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-absolute-expected.txt:
* platform/chromium-linux-x86/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-fixed-expected.txt:
* platform/chromium-linux-x86/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-relative-expected.txt:
* platform/chromium-linux/compositing/geometry/bounds-ignores-hidden-composited-descendant-expected.txt:
* platform/chromium-linux/compositing/geometry/bounds-ignores-hidden-dynamic-negzindex-expected.txt:
* platform/chromium-linux/compositing/iframes/become-overlapped-iframe-expected.txt:
* platform/chromium-linux/compositing/iframes/composited-parent-iframe-expected.txt:
* platform/chromium-linux/compositing/iframes/connect-compositing-iframe-delayed-expected.txt:
* platform/chromium-linux/compositing/iframes/connect-compositing-iframe-expected.txt:
* platform/chromium-linux/compositing/iframes/connect-compositing-iframe2-expected.txt:
* platform/chromium-linux/compositing/iframes/connect-compositing-iframe3-expected.txt:
* platform/chromium-linux/compositing/iframes/enter-compositing-iframe-expected.txt:
* platform/chromium-linux/compositing/iframes/iframe-resize-expected.txt:
* platform/chromium-linux/compositing/iframes/iframe-size-from-zero-expected.txt:
* platform/chromium-linux/compositing/iframes/invisible-nested-iframe-show-expected.txt:
* platform/chromium-linux/compositing/iframes/overlapped-iframe-expected.txt:
* platform/chromium-linux/compositing/iframes/resizer-expected.txt:
* platform/chromium-linux/compositing/overflow/textarea-scroll-touch-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/gpu/compositedscrolling/overflow/textarea-scroll-touch-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/become-overlapped-iframe-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/composited-parent-iframe-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/connect-compositing-iframe-delayed-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/connect-compositing-iframe-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/connect-compositing-iframe2-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/connect-compositing-iframe3-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/enter-compositing-iframe-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/iframe-resize-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/iframe-size-from-zero-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/invisible-nested-iframe-show-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/overlapped-iframe-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/resizer-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/iframes/scrolling-iframe-expected.txt: Removed.
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/overflow/textarea-scroll-touch-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/rtl/rtl-fixed-overflow-scrolled-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-absolute-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-fixed-expected.txt:
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-relative-expected.txt:
* platform/chromium-mac-lion/platform/chromium/virtual/softwarecompositing/rtl/rtl-fixed-overflow-scrolled-expected.txt:
* platform/chromium-mac-lion/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-absolute-expected.txt:
* platform/chromium-mac-lion/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-fixed-expected.txt:
* platform/chromium-mac-lion/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-relative-expected.txt:
* platform/chromium-mac-snowleopard/platform/chromium/virtual/softwarecompositing/rtl/rtl-fixed-overflow-scrolled-expected.txt:
* platform/chromium-mac-snowleopard/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-absolute-expected.txt:
* platform/chromium-mac-snowleopard/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-fixed-expected.txt:
* platform/chromium-mac-snowleopard/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-relative-expected.txt:
* platform/chromium-mac/compositing/iframes/invisible-nested-iframe-show-expected.txt:
* platform/chromium-mac/compositing/overflow/textarea-scroll-touch-expected.txt:
* platform/chromium-mac/compositing/repaint/invalidations-on-composited-layers-expected.txt:
* platform/chromium-mac/compositing/tiling/crash-reparent-tiled-layer-expected.txt:
* platform/chromium-mac/compositing/tiling/huge-layer-add-remove-child-expected.txt:
* platform/chromium-mac/compositing/tiling/huge-layer-with-layer-children-expected.txt:
* platform/chromium-mac/compositing/tiling/huge-layer-with-layer-children-resize-expected.txt:
* platform/chromium-mac/platform/chromium/virtual/gpu/compositedscrolling/overflow/textarea-scroll-touch-expected.txt:
* platform/chromium-mac/platform/chromium/virtual/softwarecompositing/overflow/textarea-scroll-touch-expected.txt:
* platform/chromium-mac/platform/chromium/virtual/softwarecompositing/rtl/rtl-fixed-overflow-scrolled-expected.txt:
* platform/chromium-mac/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-absolute-expected.txt:
* platform/chromium-mac/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-fixed-expected.txt:
* platform/chromium-mac/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-relative-expected.txt:
* platform/chromium-win-xp/compositing/geometry/bounds-ignores-hidden-composited-descendant-expected.txt:
* platform/chromium-win-xp/compositing/geometry/bounds-ignores-hidden-dynamic-negzindex-expected.txt:
* platform/chromium-win-xp/platform/chromium/virtual/softwarecompositing/rtl/rtl-fixed-overflow-scrolled-expected.txt:
* platform/chromium-win-xp/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-absolute-expected.txt:
* platform/chromium-win-xp/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-fixed-expected.txt:
* platform/chromium-win-xp/platform/chromium/virtual/softwarecompositing/rtl/rtl-iframe-relative-expected.txt:
* platform/chromium-win/compositing/backing/no-backing-for-clip-expected.txt:
* platform/chromium-win/compositing/backing/no-backing-for-clip-overlap-expected.txt:
* platform/chromium-win/compositing/backing/no-backing-for-perspective-expected.txt:
* platform/chromium-win/compositing/geometry/bounds-ignores-hidden-composited-descendant-expected.txt:
* platform/chromium-win/compositing/geometry/bounds-ignores-hidden-dynamic-negzindex-expected.txt:
* platform/chromium-win/compositing/geometry/layer-due-to-layer-children-deep-switch-expected.txt:
* platform/chromium-win/compositing/geometry/layer-due-to-layer-children-switch-expected.txt:
* platform/chromium-win/compositing/geometry/limit-layer-bounds-overflow-root-expected.txt:
* platform/chromium-win/compositing/geometry/preserve-3d-switching-expected.txt:
* platform/chromium-win/compositing/iframes/invisible-nested-iframe-show-expected.txt:
* platform/chromium-win/compositing/layer-creation/no-compositing-for-preserve-3d-expected.txt:
* platform/chromium-win/compositing/tiling/crash-reparent-tiled-layer-expected.txt:
* platform/chromium-win/compositing/tiling/huge-layer-add-remove-child-expected.txt:
* platform/chromium-win/compositing/tiling/huge-layer-with-layer-children-expected.txt:
* platform/chromium-win/compositing/tiling/huge-layer-with-layer-children-resize-expected.txt:
* platform/chromium/TestExpectations:
* platform/chromium/compositing/backing/no-backing-for-clip-expected.txt:
* platform/chromium/compositing/backing/no-backing-for-clip-overlap-expected.txt:
* platform/chromium/compositing/backing/no-backing-for-perspective-expected.txt:
* platform/chromium/compositing/columns/composited-in-paginated-expected.txt:
* platform/chromium/compositing/contents-opaque/background-color-expected.txt: Copied from LayoutTests/platform/chromium/compositing/geometry/limit-layer-bounds-positioned-transition-expected.txt.
* platform/chromium/compositing/contents-opaque/body-background-painted-expected.txt: Copied from LayoutTests/platform/chromium/platform/chromium/virtual/softwarecompositing/layer-creation/fixed-position-out-of-view-expected.txt.
* platform/chromium/compositing/contents-opaque/body-background-skipped-expected.txt: Copied from LayoutTests/platform/chromium/platform/chromium/virtual/softwarecompositing/layer-creation/fixed-position-out-of-view-expected.txt.
* platform/chromium/compositing/contents-opaque/layer-opacity-expected.txt: Copied from LayoutTests/compositing/clip-child-by-non-stacking-ancestor-expected.txt.
* platform/chromium/compositing/contents-opaque/layer-transform-expected.txt: Copied from LayoutTests/compositing/clip-child-by-non-stacking-ancestor-expected.txt.
* platform/chromium/compositing/filters/sw-layer-overlaps-hw-shadow-expected.txt:
* platform/chromium/compositing/filters/sw-shadow-overlaps-hw-layer-expected.txt:
* platform/chromium/compositing/geometry/bounds-ignores-hidden-composited-descendant-expected.txt:
* platform/chromium/compositing/geometry/bounds-ignores-hidden-dynamic-negzindex-expected.txt:
* platform/chromium/compositing/geometry/clip-expected.txt:
* platform/chromium/compositing/geometry/clip-inside-expected.txt:
* platform/chromium/compositing/geometry/fixed-position-composited-switch-expected.txt:
* platform/chromium/compositing/geometry/flipped-writing-mode-expected.txt:
* platform/chromium/compositing/geometry/layer-due-to-layer-children-deep-switch-expected.txt:
* platform/chromium/compositing/geometry/limit-layer-bounds-fixed-positioned-expected.txt:
* platform/chromium/compositing/geometry/limit-layer-bounds-overflow-root-expected.txt:
* platform/chromium/compositing/geometry/limit-layer-bounds-positioned-expected.txt:
* platform/chromium/compositing/geometry/limit-layer-bounds-positioned-transition-expected.txt:
* platform/chromium/compositing/geometry/limit-layer-bounds-transformed-expected.txt:
* platform/chromium/compositing/geometry/limit-layer-bounds-transformed-overflow-expected.txt:
* platform/chromium/compositing/geometry/preserve-3d-switching-expected.txt:
* platform/chromium/compositing/iframes/become-composited-nested-iframes-expected.txt:
* platform/chromium/compositing/iframes/become-overlapped-iframe-expected.txt:
* platform/chromium/compositing/iframes/composited-parent-iframe-expected.txt:
* platform/chromium/compositing/iframes/connect-compositing-iframe-delayed-expected.txt:
* platform/chromium/compositing/iframes/connect-compositing-iframe-expected.txt:
* platform/chromium/compositing/iframes/connect-compositing-iframe2-expected.txt:
* platform/chromium/compositing/iframes/connect-compositing-iframe3-expected.txt:
* platform/chromium/compositing/iframes/enter-compositing-iframe-expected.txt:
* platform/chromium/compositing/iframes/iframe-resize-expected.txt:
* platform/chromium/compositing/iframes/iframe-size-from-zero-expected.txt:
* platform/chromium/compositing/iframes/invisible-nested-iframe-hide-expected.txt:
* platform/chromium/compositing/iframes/overlapped-iframe-expected.txt:
* platform/chromium/compositing/iframes/overlapped-iframe-iframe-expected.txt:
* platform/chromium/compositing/iframes/overlapped-nested-iframes-expected.txt:
* platform/chromium/compositing/iframes/resizer-expected.txt:
* platform/chromium/compositing/layer-creation/fixed-position-and-transform-expected.txt:
* platform/chromium/compositing/layer-creation/fixed-position-change-out-of-view-in-view-expected.txt:
* platform/chromium/compositing/layer-creation/fixed-position-out-of-view-expected.txt:
* platform/chromium/compositing/layer-creation/fixed-position-out-of-view-scaled-expected.txt:
* platform/chromium/compositing/layer-creation/fixed-position-out-of-view-scaled-scroll-expected.txt:
* platform/chromium/compositing/layer-creation/fixed-position-under-transform-expected.txt:
* platform/chromium/compositing/layer-creation/no-compositing-for-preserve-3d-expected.txt:
* platform/chromium/compositing/layer-creation/overflow-scroll-overlap-expected.txt:
* platform/chromium/compositing/layer-creation/overlap-animation-clipping-expected.txt:
* platform/chromium/compositing/layer-creation/overlap-animation-expected.txt:
* platform/chromium/compositing/layer-creation/overlap-child-layer-expected.txt:
* platform/chromium/compositing/layer-creation/overlap-clipping-expected.txt:
* platform/chromium/compositing/layer-creation/overlap-transformed-3d-expected.txt:
* platform/chromium/compositing/layer-creation/overlap-transformed-and-clipped-expected.txt:
* platform/chromium/compositing/layer-creation/overlap-transformed-layer-expected.txt:
* platform/chromium/compositing/layer-creation/overlap-transformed-preserved-3d-expected.txt:
* platform/chromium/compositing/layer-creation/overlap-transforms-expected.txt:
* platform/chromium/compositing/layer-creation/spanOverlapsCanvas-expected.txt:
* platform/chromium/compositing/layer-creation/stacking-context-overlap-expected.txt:
* platform/chromium/compositing/layer-creation/translatez-overlap-expected.txt:
* platform/chromium/compositing/overflow-trumps-transform-style-expected.txt:
* platform/chromium/compositing/overflow/clip-descendents-expected.txt:
* platform/chromium/compositing/rtl/rtl-absolute-expected.txt:
* platform/chromium/compositing/rtl/rtl-absolute-overflow-expected.txt:
* platform/chromium/compositing/rtl/rtl-absolute-overflow-scrolled-expected.txt:
* platform/chromium/compositing/rtl/rtl-fixed-expected.txt:
* platform/chromium/compositing/rtl/rtl-fixed-overflow-expected.txt:
* platform/chromium/compositing/rtl/rtl-fixed-overflow-scrolled-expected.txt:
* platform/chromium/compositing/rtl/rtl-iframe-absolute-expected.txt:
* platform/chromium/compositing/rtl/rtl-iframe-fixed-expected.txt:
* platform/chromium/compositing/rtl/rtl-iframe-relative-expected.txt:
* platform/chromium/compositing/rtl/rtl-relative-expected.txt:
* platform/chromium/css3/filters/filtered-compositing-descendant-expected.txt:
* platform/chromium/platform/chromium/virtual/softwarecompositing/layer-creation/fixed-position-change-out-of-view-in-view-expected.txt:
* platform/chromium/platform/chromium/virtual/softwarecompositing/layer-creation/fixed-position-out-of-view-expected.txt:
* platform/chromium/platform/chromium/virtual/softwarecompositing/layer-creation/fixed-position-out-of-view-scaled-expected.txt:
* platform/chromium/platform/chromium/virtual/softwarecompositing/layer-creation/fixed-position-out-of-view-scaled-scroll-expected.txt:
* platform/efl/compositing/repaint/invalidations-on-composited-layers-expected.txt:
* platform/mac-wk2/compositing/visible-rect/iframe-no-layers-expected.txt:
* platform/mac/compositing/geometry/fixed-position-composited-switch-expected.txt:
* platform/mac/compositing/iframes/resizer-expected.txt:
* platform/mac/compositing/overflow/composited-scrolling-creates-a-stacking-container-expected.txt:
* platform/mac/compositing/repaint/invalidations-on-composited-layers-expected.txt:
* platform/mac/compositing/tiling/backface-preserve-3d-tiled-expected.txt:
* platform/mac/compositing/tiling/crash-reparent-tiled-layer-expected.txt:
* platform/mac/compositing/tiling/huge-layer-add-remove-child-expected.txt:
* platform/mac/compositing/tiling/huge-layer-with-layer-children-expected.txt:
* platform/mac/compositing/tiling/huge-layer-with-layer-children-resize-expected.txt:
* platform/mac/compositing/tiling/rotated-tiled-clamped-expected.txt:
* platform/mac/compositing/tiling/rotated-tiled-preserve3d-clamped-expected.txt:
* platform/mac/compositing/tiling/tile-cache-zoomed-expected.txt:
* platform/mac/compositing/tiling/tiled-layer-resize-expected.txt:
* platform/mac/compositing/visible-rect/iframe-no-layers-expected.txt:
* platform/qt-5.0-wk1/compositing/geometry/bounds-ignores-hidden-composited-descendant-expected.txt:
* platform/qt-5.0-wk1/compositing/geometry/layer-due-to-layer-children-deep-switch-expected.txt:
* platform/qt-5.0-wk1/compositing/geometry/layer-due-to-layer-children-switch-expected.txt:
* platform/qt-5.0-wk1/compositing/iframes/page-cache-layer-tree-expected.txt:
* platform/qt-5.0-wk1/compositing/overflow/textarea-scroll-touch-expected.txt:
* platform/qt-5.0-wk1/compositing/repaint/invalidations-on-composited-layers-expected.txt:
* platform/qt-5.0-wk2/compositing/columns/composited-in-paginated-expected.txt:
* platform/qt-5.0-wk2/compositing/geometry/bounds-ignores-hidden-composited-descendant-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/become-composited-nested-iframes-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/become-overlapped-iframe-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/composited-parent-iframe-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/connect-compositing-iframe-delayed-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/connect-compositing-iframe-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/connect-compositing-iframe2-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/connect-compositing-iframe3-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/enter-compositing-iframe-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/iframe-resize-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/invisible-nested-iframe-show-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/overlapped-iframe-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/overlapped-nested-iframes-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/page-cache-layer-tree-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/resizer-expected.txt:
* platform/qt-5.0-wk2/compositing/iframes/scrolling-iframe-expected.txt: Removed.
* platform/qt-5.0-wk2/compositing/layer-creation/fixed-position-and-transform-expected.txt:
* platform/qt-5.0-wk2/compositing/layer-creation/fixed-position-change-out-of-view-in-view-expected.txt:
* platform/qt-5.0-wk2/compositing/layer-creation/fixed-position-under-transform-expected.txt:
* platform/qt-5.0-wk2/compositing/layer-creation/no-compositing-for-preserve-3d-expected.txt:
* platform/qt-5.0-wk2/compositing/rtl/rtl-absolute-overflow-expected.txt:
* platform/qt-5.0-wk2/compositing/rtl/rtl-fixed-overflow-expected.txt:
* platform/qt-5.0-wk2/compositing/rtl/rtl-fixed-overflow-scrolled-expected.txt:
* platform/qt-5.0-wk2/compositing/tiled-layers-hidpi-expected.txt:
* platform/qt-5.0-wk2/compositing/tiling/crash-reparent-tiled-layer-expected.txt:
* platform/qt-5.0-wk2/compositing/tiling/huge-layer-add-remove-child-expected.txt:
* platform/qt-5.0-wk2/compositing/tiling/huge-layer-with-layer-children-expected.txt:
* platform/qt-5.0-wk2/compositing/tiling/huge-layer-with-layer-children-resize-expected.txt:
* platform/qt/compositing/backing/no-backing-for-clip-expected.txt:
* platform/qt/compositing/backing/no-backing-for-clip-overlap-expected.txt:
* platform/qt/compositing/backing/no-backing-for-perspective-expected.txt:
* platform/qt/compositing/geometry/preserve-3d-switching-expected.txt:
* platform/qt/compositing/iframes/invisible-nested-iframe-show-expected.txt:
* platform/qt/compositing/layer-creation/no-compositing-for-preserve-3d-expected.txt:
* platform/qt/compositing/overflow/composited-scrolling-creates-a-stacking-container-expected.txt:
* platform/win/compositing/iframes/overlapped-iframe-iframe-expected.txt:
* platform/win/compositing/tiling/huge-layer-add-remove-child-expected.txt:
* platform/win/compositing/tiling/rotated-tiled-clamped-expected.txt:
* platform/win/compositing/tiling/rotated-tiled-preserve3d-clamped-expected.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@146531 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 356fb46a
This diff is collapsed.
......@@ -8,6 +8,7 @@
(GraphicsLayer
(position 0.00 200.00)
(bounds 100.00 100.00)
(contentsOpaque 1)
(drawsContent 1)
)
)
......
......@@ -26,6 +26,7 @@ This layer should not have backing store.
(GraphicsLayer
(position 30.00 48.00)
(bounds 100.00 100.00)
(contentsOpaque 1)
)
)
)
......
......@@ -18,6 +18,7 @@ This layer should have backing store.
(GraphicsLayer
(position 30.00 48.00)
(bounds 100.00 100.00)
(contentsOpaque 1)
)
)
)
......@@ -35,6 +36,7 @@ This layer should have backing store.
(GraphicsLayer
(position 30.00 48.00)
(bounds 100.00 100.00)
(contentsOpaque 1)
)
)
)
......
......@@ -20,6 +20,7 @@ This layer should not have backing store.
(GraphicsLayer
(position 31.00 49.00)
(bounds 100.00 100.00)
(contentsOpaque 1)
(transform [1.00 0.00 0.00 0.00] [0.00 1.00 0.00 0.00] [0.00 0.00 1.00 0.00] [0.00 0.00 1.00 1.00])
)
)
......
......@@ -8,6 +8,7 @@
(GraphicsLayer
(position 8.00 8.00)
(bounds 100.00 100.00)
(contentsOpaque 1)
(drawsContent 1)
)
)
......
......@@ -8,6 +8,7 @@
(GraphicsLayer
(position 818.00 145.00)
(bounds 100.00 100.00)
(contentsOpaque 1)
)
)
)
......
(GraphicsLayer
(bounds 800.00 600.00)
(children 1
(GraphicsLayer
(bounds 800.00 600.00)
(contentsOpaque 1)
(children 3
(GraphicsLayer
(position 13.00 8.00)
(bounds 100.00 100.00)
(contentsOpaque 1)
(drawsContent 1)
)
(GraphicsLayer
(position 13.00 113.00)
(bounds 100.00 100.00)
(drawsContent 1)
)
(GraphicsLayer
(position 13.00 218.00)
(bounds 100.00 100.00)
(drawsContent 1)
)
)
)
)
)
<html>
<head>
<style type="text/css">
.box {
width: 80px;
height: 80px;
margin: 5px;
border-style: solid;
border-width: 5px;
padding: 5px;
background-color: green;
}
.composited {
-webkit-transform: translateZ(0);
}
.padding-clip {
background-clip: padding-box;
-webkit-background-clip: padding-box;
}
.content-clip {
background-clip: content-box;
-webkit-background-clip: content-box;
}
</style>
<script type="text/javascript">
if (window.testRunner)
testRunner.dumpAsText();
function doTest() {
if (window.testRunner && window.internals)
document.getElementById('layertree').innerText = window.internals.layerTreeAsText(document);
}
window.addEventListener('load', doTest, false);
</script>
</head>
<body>
<!-- Box with border-box background-clip. -->
<!-- GraphicsLayer::contentsOpaque for this box should be true. -->
<div class="box composited"></div>
<!-- Box with padding-box background-clip. -->
<!-- GraphicsLayer::contentsOpaque for this box should be false. -->
<div class="box composited padding-clip"></div>
<!-- Box with content-box background-clip. -->
<!-- GraphicsLayer::contentsOpaque for this box should be false. -->
<div class="box composited content-clip"></div>
<pre id="layertree"></pre>
</body>
</html>
(GraphicsLayer
(bounds 800.00 600.00)
(children 1
(GraphicsLayer
(bounds 800.00 600.00)
(contentsOpaque 1)
(children 3
(GraphicsLayer
(position 8.00 8.00)
(bounds 100.00 100.00)
)
(GraphicsLayer
(position 8.00 108.00)
(bounds 100.00 100.00)
)
(GraphicsLayer
(position 8.00 208.00)
(bounds 100.00 100.00)
(contentsOpaque 1)
)
)
)
)
)
<html>
<head>
<style type="text/css">
.box {
width: 100px;
height: 100px;
}
.opaque {
background-color: green;
}
.translucent {
background-color: rgba(0, 255, 0, 0.5);
}
.composited {
-webkit-transform: translateZ(0);
}
</style>
<script type="text/javascript">
if (window.testRunner)
testRunner.dumpAsText();
function doTest() {
if (window.testRunner && window.internals)
document.getElementById('layertree').innerText = window.internals.layerTreeAsText(document);
}
window.addEventListener('load', doTest, false);
</script>
</head>
<body>
<!-- Box with transparent background. -->
<!-- GraphicsLayer::contentsOpaque for this box should be false. -->
<div class="box composited"></div>
<!-- Box with translucent background color. -->
<!-- GraphicsLayer::contentsOpaque for this box should be false. -->
<div class="box translucent composited"></div>
<!-- Box with opaque background color. -->
<!-- GraphicsLayer::contentsOpaque for this box should be true. -->
<div class="box opaque composited"></div>
<pre id="layertree"></pre>
</body>
</html>
(GraphicsLayer
(bounds 800.00 600.00)
(children 1
(GraphicsLayer
(bounds 800.00 600.00)
(contentsOpaque 1)
(children 1
(GraphicsLayer
(bounds 800.00 600.00)
(contentsOpaque 1)
(drawsContent 1)
(children 2
(GraphicsLayer
(position 8.00 8.00)
(bounds 200.00 200.00)
(contentsOpaque 1)
)
(GraphicsLayer
(bounds 800.00 600.00)
(drawsContent 1)
)
)
)
)
)
)
)
<html style="background-color: lightgray">
<head>
<style type="text/css">
body {
width: 100px;
height: 100px;
background-color: blue;
}
#underbody {
position: fixed;
z-index: -1;
width: 200px;
height: 200px;
background-color: green;
-webkit-transform: translateZ(0);
}
</style>
<script type="text/javascript">
if (window.testRunner)
testRunner.dumpAsText();
function doTest() {
if (window.testRunner && window.internals)
document.getElementById('layertree').innerText = window.internals.layerTreeAsText(document);
}
window.addEventListener('load', doTest, false);
</script>
</head>
<!-- Composited body over the child div. -->
<!-- Root <html> element has a background-color. -->
<!-- Background for the body element is painted in this case. ->
<!-- GraphicsLayer::contentsOpaque for the body layer should be false. -->
<body>
<!-- Box under the body. -->
<div id="underbody"></div>
<pre id="layertree"></pre>
</body>
</html>
(GraphicsLayer
(bounds 800.00 600.00)
(children 1
(GraphicsLayer
(bounds 800.00 600.00)
(contentsOpaque 1)
(children 1
(GraphicsLayer
(bounds 800.00 600.00)
(drawsContent 1)
(children 2
(GraphicsLayer
(position 8.00 8.00)
(bounds 200.00 200.00)
(contentsOpaque 1)
)
(GraphicsLayer
(bounds 800.00 600.00)
(drawsContent 1)
)
)
)
)
)
)
)
<html>
<head>
<style type="text/css">
body {
width: 100px;
height: 100px;
background-color: blue;
}
#underbody {
position: fixed;
z-index: -1;
width: 200px;
height: 200px;
background-color: green;
-webkit-transform: translateZ(0);
}
</style>
<script type="text/javascript">
if (window.testRunner)
testRunner.dumpAsText();
function doTest() {
if (window.testRunner && window.internals)
document.getElementById('layertree').innerText = window.internals.layerTreeAsText(document);
}
window.addEventListener('load', doTest, false);
</script>
</head>
<!-- Composited body over the child div. -->
<!-- Background for the body element is not painted. ->
<!-- GraphicsLayer::contentsOpaque for the body layer should be false. -->
<body>
<!-- Box under the body. -->
<div id="underbody"></div>
<pre id="layertree"></pre>
</body>
</html>
(GraphicsLayer
(bounds 800.00 600.00)
(children 1
(GraphicsLayer
(bounds 800.00 600.00)
(contentsOpaque 1)
(children 1
(GraphicsLayer
(position 8.00 8.00)
(bounds 100.00 100.00)
(opacity 0.50)
(contentsOpaque 1)
)
)
)
)
)
<html>
<head>
<style type="text/css">
.box {
width: 100px;
height: 100px;
}
.opaque-background {
background-color: green;
}
.translucent {
opacity: 0.5;
}
.composited {
-webkit-transform: translateZ(0);
}
</style>
<script type="text/javascript">
if (window.testRunner)
testRunner.dumpAsText();
function doTest() {
if (window.testRunner && window.internals)
document.getElementById('layertree').innerText = window.internals.layerTreeAsText(document);
}
window.addEventListener('load', doTest, false);
</script>
</head>
<body>
<!-- Box with opaque background color but global opacity. -->
<!-- Global opacity does not affect the opaqueness of content. -->
<!-- GraphicsLayer::contentsOpaque for this box should be true. -->
<div class="box opaque-background translucent composited"></div>
<pre id="layertree"></pre>
</body>
</html>
(GraphicsLayer
(bounds 800.00 600.00)
(children 1
(GraphicsLayer
(bounds 800.00 600.00)
(contentsOpaque 1)
(children 1
(GraphicsLayer
(position 8.00 8.00)
(bounds 100.00 100.00)
(contentsOpaque 1)
(transform [0.87 0.50 0.00 0.00] [-0.50 0.87 0.00 0.00] [0.00 0.00 1.00 0.00] [0.00 0.00 0.00 1.00])
)
)
)
)
)
<html>
<head>
<style type="text/css">
.box {
width: 100px;
height: 100px;
background-color: green;
-webkit-transform: rotate(30deg) translateZ(0);
}
</style>