RenderLayerCompositor.h 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481
  1. /*
  2. * Copyright (C) 2009 Apple Inc. All rights reserved.
  3. *
  4. * Redistribution and use in source and binary forms, with or without
  5. * modification, are permitted provided that the following conditions
  6. * are met:
  7. * 1. Redistributions of source code must retain the above copyright
  8. * notice, this list of conditions and the following disclaimer.
  9. * 2. Redistributions in binary form must reproduce the above copyright
  10. * notice, this list of conditions and the following disclaimer in the
  11. * documentation and/or other materials provided with the distribution.
  12. *
  13. * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
  14. * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  15. * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  16. * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE COMPUTER, INC. OR
  17. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
  18. * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
  19. * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
  20. * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
  21. * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  22. * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  23. * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  24. */
  25. #ifndef RenderLayerCompositor_h
  26. #define RenderLayerCompositor_h
  27. #if USE(ACCELERATED_COMPOSITING)
  28. #include "ChromeClient.h"
  29. #include "Frame.h"
  30. #include "GraphicsLayerClient.h"
  31. #include "GraphicsLayerUpdater.h"
  32. #include "RenderLayer.h"
  33. #include <wtf/HashMap.h>
  34. namespace WebCore {
  35. class FixedPositionViewportConstraints;
  36. class GraphicsLayer;
  37. class GraphicsLayerUpdater;
  38. class RenderEmbeddedObject;
  39. class RenderPart;
  40. class ScrollingCoordinator;
  41. class StickyPositionViewportConstraints;
  42. #if ENABLE(VIDEO)
  43. class RenderVideo;
  44. #endif
  45. class TiledBacking;
  46. enum CompositingUpdateType {
  47. CompositingUpdateAfterStyleChange,
  48. CompositingUpdateAfterLayout,
  49. CompositingUpdateOnHitTest,
  50. CompositingUpdateOnScroll,
  51. CompositingUpdateOnCompositedScroll
  52. };
  53. enum {
  54. CompositingReasonNone = 0,
  55. CompositingReason3DTransform = 1 << 0,
  56. CompositingReasonVideo = 1 << 1,
  57. CompositingReasonCanvas = 1 << 2,
  58. CompositingReasonPlugin = 1 << 3,
  59. CompositingReasonIFrame = 1 << 4,
  60. CompositingReasonBackfaceVisibilityHidden = 1 << 5,
  61. CompositingReasonClipsCompositingDescendants = 1 << 6,
  62. CompositingReasonAnimation = 1 << 7,
  63. CompositingReasonFilters = 1 << 8,
  64. CompositingReasonPositionFixed = 1 << 9,
  65. CompositingReasonPositionSticky = 1 << 10,
  66. CompositingReasonOverflowScrollingTouch = 1 << 11,
  67. CompositingReasonStacking = 1 << 12,
  68. CompositingReasonOverlap = 1 << 13,
  69. CompositingReasonNegativeZIndexChildren = 1 << 14,
  70. CompositingReasonTransformWithCompositedDescendants = 1 << 15,
  71. CompositingReasonOpacityWithCompositedDescendants = 1 << 16,
  72. CompositingReasonMaskWithCompositedDescendants = 1 << 17,
  73. CompositingReasonReflectionWithCompositedDescendants = 1 << 18,
  74. CompositingReasonFilterWithCompositedDescendants = 1 << 19,
  75. CompositingReasonBlendingWithCompositedDescendants = 1 << 20,
  76. CompositingReasonPerspective = 1 << 21,
  77. CompositingReasonPreserve3D = 1 << 22,
  78. CompositingReasonRoot = 1 << 23
  79. };
  80. typedef unsigned CompositingReasons;
  81. // RenderLayerCompositor manages the hierarchy of
  82. // composited RenderLayers. It determines which RenderLayers
  83. // become compositing, and creates and maintains a hierarchy of
  84. // GraphicsLayers based on the RenderLayer painting order.
  85. //
  86. // There is one RenderLayerCompositor per RenderView.
  87. class RenderLayerCompositor : public GraphicsLayerClient, public GraphicsLayerUpdaterClient {
  88. WTF_MAKE_FAST_ALLOCATED;
  89. public:
  90. explicit RenderLayerCompositor(RenderView*);
  91. ~RenderLayerCompositor();
  92. // Return true if this RenderView is in "compositing mode" (i.e. has one or more
  93. // composited RenderLayers)
  94. bool inCompositingMode() const { return m_compositing; }
  95. // This will make a compositing layer at the root automatically, and hook up to
  96. // the native view/window system.
  97. void enableCompositingMode(bool enable = true);
  98. bool inForcedCompositingMode() const { return m_forceCompositingMode; }
  99. // Returns true if the accelerated compositing is enabled
  100. bool hasAcceleratedCompositing() const { return m_hasAcceleratedCompositing; }
  101. bool canRender3DTransforms() const;
  102. // Copy the accelerated compositing related flags from Settings
  103. void cacheAcceleratedCompositingFlags();
  104. // Called when the layer hierarchy needs to be updated (compositing layers have been
  105. // created, destroyed or re-parented).
  106. void setCompositingLayersNeedRebuild(bool needRebuild = true);
  107. bool compositingLayersNeedRebuild() const { return m_compositingLayersNeedRebuild; }
  108. // GraphicsLayers buffer state, which gets pushed to the underlying platform layers
  109. // at specific times.
  110. void scheduleLayerFlush(bool canThrottle);
  111. void flushPendingLayerChanges(bool isFlushRoot = true);
  112. // flushPendingLayerChanges() flushes the entire GraphicsLayer tree, which can cross frame boundaries.
  113. // This call returns the rootmost compositor that is being flushed (including self).
  114. RenderLayerCompositor* enclosingCompositorFlushingLayers() const;
  115. // Called when the GraphicsLayer for the given RenderLayer has flushed changes inside of flushPendingLayerChanges().
  116. void didFlushChangesForLayer(RenderLayer*, const GraphicsLayer*);
  117. // Called when something outside WebKit affects the visible rect (e.g. delegated scrolling). Might schedule a layer flush.
  118. void didChangeVisibleRect();
  119. // Rebuild the tree of compositing layers
  120. void updateCompositingLayers(CompositingUpdateType, RenderLayer* updateRoot = 0);
  121. // This is only used when state changes and we do not exepect a style update or layout to happen soon (e.g. when
  122. // we discover that an iframe is overlapped during painting).
  123. void scheduleCompositingLayerUpdate();
  124. // Update the compositing state of the given layer. Returns true if that state changed.
  125. enum CompositingChangeRepaint { CompositingChangeRepaintNow, CompositingChangeWillRepaintLater };
  126. bool updateLayerCompositingState(RenderLayer*, CompositingChangeRepaint = CompositingChangeRepaintNow);
  127. // Update the geometry for compositing children of compositingAncestor.
  128. void updateCompositingDescendantGeometry(RenderLayer* compositingAncestor, RenderLayer*, bool compositedChildrenOnly);
  129. // Whether layer's backing needs a graphics layer to do clipping by an ancestor (non-stacking-context parent with overflow).
  130. bool clippedByAncestor(RenderLayer*) const;
  131. // Whether layer's backing needs a graphics layer to clip z-order children of the given layer.
  132. bool clipsCompositingDescendants(const RenderLayer*) const;
  133. // Whether the given layer needs an extra 'contents' layer.
  134. bool needsContentsCompositingLayer(const RenderLayer*) const;
  135. bool supportsFixedRootBackgroundCompositing() const;
  136. bool needsFixedRootBackgroundLayer(const RenderLayer*) const;
  137. GraphicsLayer* fixedRootBackgroundLayer() const;
  138. // Return the bounding box required for compositing layer and its childern, relative to ancestorLayer.
  139. // If layerBoundingBox is not 0, on return it contains the bounding box of this layer only.
  140. IntRect calculateCompositedBounds(const RenderLayer*, const RenderLayer* ancestorLayer) const;
  141. // Repaint the appropriate layers when the given RenderLayer starts or stops being composited.
  142. void repaintOnCompositingChange(RenderLayer*);
  143. void repaintInCompositedAncestor(RenderLayer*, const LayoutRect&);
  144. // Notify us that a layer has been added or removed
  145. void layerWasAdded(RenderLayer* parent, RenderLayer* child);
  146. void layerWillBeRemoved(RenderLayer* parent, RenderLayer* child);
  147. // Get the nearest ancestor layer that has overflow or clip, but is not a stacking context
  148. RenderLayer* enclosingNonStackingClippingLayer(const RenderLayer* layer) const;
  149. // Repaint parts of all composited layers that intersect the given absolute rectangle (or the entire layer if the pointer is null).
  150. void repaintCompositedLayers(const IntRect* = 0);
  151. // Returns true if the given layer needs it own backing store.
  152. bool requiresOwnBackingStore(const RenderLayer*, const RenderLayer* compositingAncestorLayer, const IntRect& layerCompositedBoundsInAncestor, const IntRect& ancestorCompositedBounds) const;
  153. RenderLayer* rootRenderLayer() const;
  154. GraphicsLayer* rootGraphicsLayer() const;
  155. GraphicsLayer* scrollLayer() const;
  156. #if ENABLE(RUBBER_BANDING)
  157. GraphicsLayer* headerLayer() const;
  158. GraphicsLayer* footerLayer() const;
  159. #endif
  160. enum RootLayerAttachment {
  161. RootLayerUnattached,
  162. RootLayerAttachedViaChromeClient,
  163. RootLayerAttachedViaEnclosingFrame
  164. };
  165. RootLayerAttachment rootLayerAttachment() const { return m_rootLayerAttachment; }
  166. void updateRootLayerAttachment();
  167. void updateRootLayerPosition();
  168. void setIsInWindow(bool);
  169. void clearBackingForAllLayers();
  170. void layerBecameComposited(const RenderLayer*) { ++m_compositedLayerCount; }
  171. void layerBecameNonComposited(const RenderLayer*);
  172. #if ENABLE(VIDEO)
  173. // Use by RenderVideo to ask if it should try to use accelerated compositing.
  174. bool canAccelerateVideoRendering(RenderVideo*) const;
  175. #endif
  176. // Walk the tree looking for layers with 3d transforms. Useful in case you need
  177. // to know if there is non-affine content, e.g. for drawing into an image.
  178. bool has3DContent() const;
  179. // Most platforms connect compositing layer trees between iframes and their parent document.
  180. // Some (currently just Mac) allow iframes to do their own compositing.
  181. static bool allowsIndependentlyCompositedFrames(const FrameView*);
  182. bool shouldPropagateCompositingToEnclosingFrame() const;
  183. static RenderLayerCompositor* frameContentsCompositor(RenderPart*);
  184. // Return true if the layers changed.
  185. static bool parentFrameContentLayers(RenderPart*);
  186. // Update the geometry of the layers used for clipping and scrolling in frames.
  187. void frameViewDidChangeLocation(const IntPoint& contentsOffset);
  188. void frameViewDidChangeSize();
  189. void frameViewDidScroll();
  190. void frameViewDidLayout();
  191. void rootFixedBackgroundsChanged();
  192. void scrollingLayerDidChange(RenderLayer*);
  193. void fixedRootBackgroundLayerChanged();
  194. String layerTreeAsText(LayerTreeFlags);
  195. virtual float deviceScaleFactor() const OVERRIDE;
  196. virtual float pageScaleFactor() const OVERRIDE;
  197. virtual void didCommitChangesForLayer(const GraphicsLayer*) const OVERRIDE;
  198. virtual void notifyFlushBeforeDisplayRefresh(const GraphicsLayer*) OVERRIDE;
  199. void layerTiledBackingUsageChanged(const GraphicsLayer*, bool /*usingTiledBacking*/);
  200. bool keepLayersPixelAligned() const;
  201. bool acceleratedDrawingEnabled() const { return m_acceleratedDrawingEnabled; }
  202. void deviceOrPageScaleFactorChanged();
  203. void windowScreenDidChange(PlatformDisplayID);
  204. GraphicsLayer* layerForHorizontalScrollbar() const { return m_layerForHorizontalScrollbar.get(); }
  205. GraphicsLayer* layerForVerticalScrollbar() const { return m_layerForVerticalScrollbar.get(); }
  206. GraphicsLayer* layerForScrollCorner() const { return m_layerForScrollCorner.get(); }
  207. #if ENABLE(RUBBER_BANDING)
  208. GraphicsLayer* layerForOverhangAreas() const { return m_layerForOverhangAreas.get(); }
  209. GraphicsLayer* updateLayerForTopOverhangArea(bool wantsLayer);
  210. GraphicsLayer* updateLayerForBottomOverhangArea(bool wantsLayer);
  211. GraphicsLayer* updateLayerForHeader(bool wantsLayer);
  212. GraphicsLayer* updateLayerForFooter(bool wantsLayer);
  213. #endif
  214. void updateViewportConstraintStatus(RenderLayer*);
  215. void removeViewportConstrainedLayer(RenderLayer*);
  216. void resetTrackedRepaintRects();
  217. void setTracksRepaints(bool);
  218. void setShouldReevaluateCompositingAfterLayout() { m_reevaluateCompositingAfterLayout = true; }
  219. bool viewHasTransparentBackground(Color* backgroundColor = 0) const;
  220. bool hasNonMainLayersWithTiledBacking() const { return m_layersWithTiledBackingCount; }
  221. CompositingReasons reasonsForCompositing(const RenderLayer*) const;
  222. void setLayerFlushThrottlingEnabled(bool);
  223. void disableLayerFlushThrottlingTemporarilyForInteraction();
  224. void didPaintBacking(RenderLayerBacking*);
  225. private:
  226. class OverlapMap;
  227. // GraphicsLayerClient implementation
  228. virtual void notifyAnimationStarted(const GraphicsLayer*, double) OVERRIDE { }
  229. virtual void notifyFlushRequired(const GraphicsLayer*) OVERRIDE;
  230. virtual void paintContents(const GraphicsLayer*, GraphicsContext&, GraphicsLayerPaintingPhase, const IntRect&) OVERRIDE;
  231. virtual bool isTrackingRepaints() const OVERRIDE;
  232. // GraphicsLayerUpdaterClient implementation
  233. virtual void flushLayers(GraphicsLayerUpdater*) OVERRIDE;
  234. virtual void customPositionForVisibleRectComputation(const GraphicsLayer*, FloatPoint&) const OVERRIDE;
  235. // Whether the given RL needs a compositing layer.
  236. bool needsToBeComposited(const RenderLayer*, RenderLayer::ViewportConstrainedNotCompositedReason* = 0) const;
  237. // Whether the layer has an intrinsic need for compositing layer.
  238. bool requiresCompositingLayer(const RenderLayer*, RenderLayer::ViewportConstrainedNotCompositedReason* = 0) const;
  239. // Whether the layer could ever be composited.
  240. bool canBeComposited(const RenderLayer*) const;
  241. // Make or destroy the backing for this layer; returns true if backing changed.
  242. bool updateBacking(RenderLayer*, CompositingChangeRepaint shouldRepaint);
  243. void clearBackingForLayerIncludingDescendants(RenderLayer*);
  244. // Repaint the given rect (which is layer's coords), and regions of child layers that intersect that rect.
  245. void recursiveRepaintLayer(RenderLayer*, const IntRect* = 0);
  246. void addToOverlapMap(OverlapMap&, RenderLayer*, IntRect& layerBounds, bool& boundsComputed);
  247. void addToOverlapMapRecursive(OverlapMap&, RenderLayer*, RenderLayer* ancestorLayer = 0);
  248. void updateCompositingLayersTimerFired(Timer<RenderLayerCompositor>*);
  249. // Returns true if any layer's compositing changed
  250. void computeCompositingRequirements(RenderLayer* ancestorLayer, RenderLayer*, OverlapMap*, struct CompositingState&, bool& layersChanged, bool& descendantHas3DTransform);
  251. // Recurses down the tree, parenting descendant compositing layers and collecting an array of child layers for the current compositing layer.
  252. void rebuildCompositingLayerTree(RenderLayer*, Vector<GraphicsLayer*>& childGraphicsLayersOfEnclosingLayer, int depth);
  253. // Recurses down the tree, updating layer geometry only.
  254. void updateLayerTreeGeometry(RenderLayer*, int depth);
  255. // Hook compositing layers together
  256. void setCompositingParent(RenderLayer* childLayer, RenderLayer* parentLayer);
  257. void removeCompositedChildren(RenderLayer*);
  258. bool layerHas3DContent(const RenderLayer*) const;
  259. bool isRunningAcceleratedTransformAnimation(RenderObject*) const;
  260. bool hasAnyAdditionalCompositedLayers(const RenderLayer* rootLayer) const;
  261. void ensureRootLayer();
  262. void destroyRootLayer();
  263. void attachRootLayer(RootLayerAttachment);
  264. void detachRootLayer();
  265. void rootLayerAttachmentChanged();
  266. void updateOverflowControlsLayers();
  267. void notifyIFramesOfCompositingChange();
  268. bool isFlushingLayers() const { return m_flushingLayers; }
  269. Page* page() const;
  270. TiledBacking* pageTiledBacking() const;
  271. GraphicsLayerFactory* graphicsLayerFactory() const;
  272. ScrollingCoordinator* scrollingCoordinator() const;
  273. // Whether a running transition or animation enforces the need for a compositing layer.
  274. bool requiresCompositingForAnimation(RenderObject*) const;
  275. bool requiresCompositingForTransform(RenderObject*) const;
  276. bool requiresCompositingForVideo(RenderObject*) const;
  277. bool requiresCompositingForCanvas(RenderObject*) const;
  278. bool requiresCompositingForPlugin(RenderObject*) const;
  279. bool requiresCompositingForFrame(RenderObject*) const;
  280. bool requiresCompositingForFilters(RenderObject*) const;
  281. bool requiresCompositingForBlending(RenderObject* renderer) const;
  282. bool requiresCompositingForScrollableFrame() const;
  283. bool requiresCompositingForPosition(RenderObject*, const RenderLayer*, RenderLayer::ViewportConstrainedNotCompositedReason* = 0) const;
  284. bool requiresCompositingForOverflowScrolling(const RenderLayer*) const;
  285. bool requiresCompositingForIndirectReason(RenderObject*, bool hasCompositedDescendants, bool has3DTransformedDescendants, RenderLayer::IndirectCompositingReason&) const;
  286. void addViewportConstrainedLayer(RenderLayer*);
  287. void registerOrUpdateViewportConstrainedLayer(RenderLayer*);
  288. void unregisterViewportConstrainedLayer(RenderLayer*);
  289. FixedPositionViewportConstraints computeFixedViewportConstraints(RenderLayer*) const;
  290. StickyPositionViewportConstraints computeStickyViewportConstraints(RenderLayer*) const;
  291. bool requiresScrollLayer(RootLayerAttachment) const;
  292. bool requiresHorizontalScrollbarLayer() const;
  293. bool requiresVerticalScrollbarLayer() const;
  294. bool requiresScrollCornerLayer() const;
  295. #if ENABLE(RUBBER_BANDING)
  296. bool requiresOverhangAreasLayer() const;
  297. bool requiresContentShadowLayer() const;
  298. #endif
  299. bool hasCoordinatedScrolling() const;
  300. bool shouldCompositeOverflowControls() const;
  301. void scheduleLayerFlushNow();
  302. bool isThrottlingLayerFlushes() const;
  303. void startLayerFlushTimerIfNeeded();
  304. void layerFlushTimerFired(Timer<RenderLayerCompositor>*);
  305. void paintRelatedMilestonesTimerFired(Timer<RenderLayerCompositor>*);
  306. #if !LOG_DISABLED
  307. const char* logReasonsForCompositing(const RenderLayer*);
  308. void logLayerInfo(const RenderLayer*, int depth);
  309. #endif
  310. private:
  311. RenderView* m_renderView;
  312. OwnPtr<GraphicsLayer> m_rootContentLayer;
  313. Timer<RenderLayerCompositor> m_updateCompositingLayersTimer;
  314. bool m_hasAcceleratedCompositing;
  315. ChromeClient::CompositingTriggerFlags m_compositingTriggers;
  316. int m_compositedLayerCount;
  317. bool m_showDebugBorders;
  318. bool m_showRepaintCounter;
  319. bool m_acceleratedDrawingEnabled;
  320. // When true, we have to wait until layout has happened before we can decide whether to enter compositing mode,
  321. // because only then do we know the final size of plugins and iframes.
  322. mutable bool m_reevaluateCompositingAfterLayout;
  323. bool m_compositing;
  324. bool m_compositingLayersNeedRebuild;
  325. bool m_flushingLayers;
  326. bool m_shouldFlushOnReattach;
  327. bool m_forceCompositingMode;
  328. bool m_inPostLayoutUpdate; // true when it's OK to trust layout information (e.g. layer sizes and positions)
  329. bool m_isTrackingRepaints; // Used for testing.
  330. unsigned m_layersWithTiledBackingCount;
  331. RootLayerAttachment m_rootLayerAttachment;
  332. // Enclosing clipping layer for iframe content
  333. OwnPtr<GraphicsLayer> m_clipLayer;
  334. OwnPtr<GraphicsLayer> m_scrollLayer;
  335. HashSet<RenderLayer*> m_viewportConstrainedLayers;
  336. HashSet<RenderLayer*> m_viewportConstrainedLayersNeedingUpdate;
  337. // Enclosing layer for overflow controls and the clipping layer
  338. OwnPtr<GraphicsLayer> m_overflowControlsHostLayer;
  339. // Layers for overflow controls
  340. OwnPtr<GraphicsLayer> m_layerForHorizontalScrollbar;
  341. OwnPtr<GraphicsLayer> m_layerForVerticalScrollbar;
  342. OwnPtr<GraphicsLayer> m_layerForScrollCorner;
  343. #if ENABLE(RUBBER_BANDING)
  344. OwnPtr<GraphicsLayer> m_layerForOverhangAreas;
  345. OwnPtr<GraphicsLayer> m_contentShadowLayer;
  346. OwnPtr<GraphicsLayer> m_layerForTopOverhangArea;
  347. OwnPtr<GraphicsLayer> m_layerForBottomOverhangArea;
  348. OwnPtr<GraphicsLayer> m_layerForHeader;
  349. OwnPtr<GraphicsLayer> m_layerForFooter;
  350. #endif
  351. OwnPtr<GraphicsLayerUpdater> m_layerUpdater; // Updates tiled layer visible area periodically while animations are running.
  352. Timer<RenderLayerCompositor> m_layerFlushTimer;
  353. bool m_layerFlushThrottlingEnabled;
  354. bool m_layerFlushThrottlingTemporarilyDisabledForInteraction;
  355. bool m_hasPendingLayerFlush;
  356. Timer<RenderLayerCompositor> m_paintRelatedMilestonesTimer;
  357. #if !LOG_DISABLED
  358. int m_rootLayerUpdateCount;
  359. int m_obligateCompositedLayerCount; // count of layer that have to be composited.
  360. int m_secondaryCompositedLayerCount; // count of layers that have to be composited because of stacking or overlap.
  361. double m_obligatoryBackingStoreBytes;
  362. double m_secondaryBackingStoreBytes;
  363. #endif
  364. };
  365. } // namespace WebCore
  366. #endif // USE(ACCELERATED_COMPOSITING)
  367. #endif // RenderLayerCompositor_h