https://bugs.webkit.org/show_bug.cgi?id=127833
Reviewed by Antti Koivisto.
Remove the USE(ACCELERATED_COMPOSITING) conditionals from the code base and make AC
mandatory.
Source/WebCore:
Tests: No new tests, no functional change.
* css/MediaQueryEvaluator.cpp:
(WebCore::transform_3dMediaFeatureEval):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::canShareStyleWithElement):
* dom/Document.cpp:
(WebCore::Document::setVisualUpdatesAllowed):
(WebCore::Document::recalcStyle):
(WebCore::Document::createRenderTree):
(WebCore::Document::documentWillBecomeInactive):
(WebCore::Document::documentDidResumeFromPageCache):
(WebCore::Document::windowScreenDidChange):
* dom/PseudoElement.cpp:
(WebCore::PseudoElement::~PseudoElement):
* history/CachedFrame.cpp:
(WebCore::CachedFrameBase::CachedFrameBase):
(WebCore::CachedFrameBase::restore):
(WebCore::CachedFrame::CachedFrame):
* history/CachedFrame.h:
* history/CachedPage.cpp:
(WebCore::CachedPage::restore):
* history/CachedPage.h:
* history/PageCache.cpp:
(WebCore::PageCache::PageCache):
(WebCore::PageCache::markPagesForDeviceScaleChanged):
* history/PageCache.h:
* html/HTMLCanvasElement.cpp:
(WebCore::HTMLCanvasElement::getContext):
(WebCore::HTMLCanvasElement::reset):
(WebCore::HTMLCanvasElement::paintsIntoCanvasBuffer):
(WebCore::HTMLCanvasElement::createImageBuffer):
* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::parseAttribute):
* html/HTMLMediaElement.h:
* html/canvas/CanvasRenderingContext.h:
* html/canvas/CanvasRenderingContext2D.cpp:
(WebCore::CanvasRenderingContext2D::didDraw):
* html/canvas/CanvasRenderingContext2D.h:
* html/canvas/WebGLRenderingContext.cpp:
(WebCore::WebGLRenderingContext::markContextChanged):
(WebCore::WebGLRenderingContext::reshape):
(WebCore::WebGLRenderingContext::platformLayer):
* html/canvas/WebGLRenderingContext.h:
* inspector/InspectorController.cpp:
(WebCore::InspectorController::InspectorController):
* inspector/InspectorInstrumentation.cpp:
(WebCore::InspectorInstrumentation::didCommitLoadImpl):
(WebCore::InspectorInstrumentation::pseudoElementDestroyedImpl):
* inspector/InspectorInstrumentation.h:
(WebCore::InspectorInstrumentation::pseudoElementDestroyed):
* inspector/InspectorLayerTreeAgent.cpp:
* inspector/InstrumentingAgents.cpp:
(WebCore::InstrumentingAgents::InstrumentingAgents):
(WebCore::InstrumentingAgents::reset):
* inspector/InstrumentingAgents.h:
* loader/EmptyClients.h:
* page/ChromeClient.h:
* page/Frame.cpp:
(WebCore::Frame::layerTreeAsText):
(WebCore::Frame::deviceOrPageScaleFactorChanged):
* page/Frame.h:
* page/FrameView.cpp:
(WebCore::FrameView::setFrameRect):
(WebCore::FrameView::scheduleLayerFlushAllowingThrottling):
(WebCore::FrameView::hasCompositedContent):
(WebCore::FrameView::hasCompositedContentIncludingDescendants):
(WebCore::FrameView::hasCompositingAncestor):
(WebCore::FrameView::enterCompositingMode):
(WebCore::FrameView::isEnclosedInCompositingLayer):
(WebCore::FrameView::flushCompositingStateIncludingSubframes):
(WebCore::FrameView::isSoftwareRenderable):
(WebCore::FrameView::layout):
(WebCore::FrameView::contentsInCompositedLayer):
(WebCore::FrameView::scrollContentsFastPath):
(WebCore::FrameView::scrollContentsSlowPath):
(WebCore::FrameView::setIsOverlapped):
(WebCore::FrameView::delegatesScrollingDidChange):
(WebCore::FrameView::scrollPositionChanged):
(WebCore::FrameView::updateCompositingLayersAfterScrolling):
(WebCore::FrameView::visibleContentsResized):
(WebCore::FrameView::addedOrRemovedScrollbar):
(WebCore::FrameView::disableLayerFlushThrottlingTemporarilyForInteraction):
(WebCore::FrameView::updateLayerFlushThrottlingInAllFrames):
(WebCore::FrameView::adjustTiledBackingCoverage):
(WebCore::FrameView::hasExtendedBackground):
(WebCore::FrameView::extendedBackgroundRect):
(WebCore::FrameView::setBackgroundExtendsBeyondPage):
(WebCore::FrameView::performPostLayoutTasks):
(WebCore::FrameView::paintContents):
(WebCore::FrameView::setTracksRepaints):
(WebCore::FrameView::resetTrackedRepaints):
(WebCore::FrameView::setScrollingPerformanceLoggingEnabled):
(WebCore::FrameView::setExposedRect):
* page/FrameView.h:
* page/Page.cpp:
(WebCore::Page::setPageScaleFactor):
(WebCore::Page::setDeviceScaleFactor):
* page/Settings.cpp:
(WebCore::Settings::setBackgroundShouldExtendBeyondPage):
* page/animation/AnimationBase.cpp:
(WebCore::AnimationBase::freezeAtTime):
* page/animation/AnimationController.cpp:
(WebCore::AnimationController::supportsAcceleratedAnimationOfProperty):
* page/animation/CSSPropertyAnimation.cpp:
(WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap):
(WebCore::CSSPropertyAnimation::blendProperties):
(WebCore::CSSPropertyAnimation::animationOfPropertyIsAccelerated):
* page/animation/CSSPropertyAnimation.h:
* page/animation/CompositeAnimation.cpp:
(WebCore::CompositeAnimation::updateTransitions):
* page/animation/ImplicitAnimation.cpp:
(WebCore::ImplicitAnimation::animate):
(WebCore::ImplicitAnimation::startAnimation):
(WebCore::ImplicitAnimation::pauseAnimation):
(WebCore::ImplicitAnimation::endAnimation):
(WebCore::ImplicitAnimation::timeToNextService):
* page/animation/KeyframeAnimation.cpp:
(WebCore::KeyframeAnimation::animate):
(WebCore::KeyframeAnimation::startAnimation):
(WebCore::KeyframeAnimation::pauseAnimation):
(WebCore::KeyframeAnimation::endAnimation):
(WebCore::KeyframeAnimation::timeToNextService):
* page/ios/FrameIOS.mm:
(WebCore::Frame::viewportOffsetChanged):
(WebCore::Frame::containsTiledBackingLayers):
* page/scrolling/AsyncScrollingCoordinator.cpp:
(WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
* page/scrolling/ScrollingCoordinator.cpp:
(WebCore::ScrollingCoordinator::coordinatesScrollingForFrameView):
(WebCore::ScrollingCoordinator::computeNonFastScrollableRegion):
(WebCore::ScrollingCoordinator::verticalScrollbarLayerForScrollableArea):
(WebCore::ScrollingCoordinator::scrollLayerForFrameView):
(WebCore::ScrollingCoordinator::headerLayerForFrameView):
(WebCore::ScrollingCoordinator::footerLayerForFrameView):
(WebCore::ScrollingCoordinator::counterScrollingLayerForFrameView):
(WebCore::ScrollingCoordinator::hasVisibleSlowRepaintViewportConstrainedObjects):
* page/scrolling/ScrollingCoordinator.h:
* platform/ScrollView.cpp:
(WebCore::positionScrollCornerLayer):
(WebCore::ScrollView::positionScrollbarLayers):
(WebCore::ScrollView::paintScrollbars):
(WebCore::ScrollView::paint):
* platform/ScrollableArea.cpp:
(WebCore::ScrollableArea::invalidateScrollbar):
(WebCore::ScrollableArea::invalidateScrollCorner):
(WebCore::ScrollableArea::horizontalScrollbarLayerDidChange):
(WebCore::ScrollableArea::hasLayerForHorizontalScrollbar):
(WebCore::ScrollableArea::hasLayerForVerticalScrollbar):
(WebCore::ScrollableArea::hasLayerForScrollCorner):
* platform/ScrollableArea.h:
* platform/ScrollbarTheme.h:
* platform/efl/EflScreenUtilities.cpp:
(WebCore::applyFallbackCursor):
* platform/graphics/GraphicsContext3D.h:
* platform/graphics/GraphicsContext3DPrivate.cpp:
(WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
(WebCore::GraphicsContext3DPrivate::paintToTextureMapper):
* platform/graphics/GraphicsContext3DPrivate.h:
* platform/graphics/GraphicsLayer.cpp:
* platform/graphics/GraphicsLayer.h:
* platform/graphics/GraphicsLayerAnimation.cpp:
* platform/graphics/GraphicsLayerAnimation.h:
* platform/graphics/GraphicsLayerClient.h:
* platform/graphics/GraphicsLayerFactory.h:
* platform/graphics/GraphicsLayerUpdater.cpp:
* platform/graphics/GraphicsLayerUpdater.h:
* platform/graphics/ImageBuffer.cpp:
* platform/graphics/ImageBuffer.h:
* platform/graphics/MediaPlayer.cpp:
(WebCore::MediaPlayer::platformLayer):
(WebCore::MediaPlayer::supportsAcceleratedRendering):
* platform/graphics/MediaPlayer.h:
* platform/graphics/MediaPlayerPrivate.h:
* platform/graphics/PlatformLayer.h:
* platform/graphics/TextTrackRepresentation.cpp:
* platform/graphics/TextTrackRepresentation.h:
* platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
(WebCore::MediaPlayerPrivateAVFoundation::currentRenderingMode):
(WebCore::MediaPlayerPrivateAVFoundation::preferredRenderingMode):
(WebCore::MediaPlayerPrivateAVFoundation::setUpVideoRendering):
(WebCore::MediaPlayerPrivateAVFoundation::tearDownVideoRendering):
* platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::platformLayer):
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::acceleratedRenderingStateChanged):
* platform/graphics/ca/GraphicsLayerCA.cpp:
* platform/graphics/ca/GraphicsLayerCA.h:
* platform/graphics/ca/LayerFlushScheduler.cpp:
* platform/graphics/ca/LayerFlushScheduler.h:
* platform/graphics/ca/LayerFlushSchedulerClient.h:
* platform/graphics/ca/PlatformCAAnimation.h:
* platform/graphics/ca/PlatformCAFilters.h:
* platform/graphics/ca/PlatformCALayer.h:
* platform/graphics/ca/PlatformCALayerClient.h:
* platform/graphics/ca/mac/LayerFlushSchedulerMac.cpp:
* platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
(PlatformCAAnimation::copyTimingFunctionsFrom):
* platform/graphics/ca/mac/PlatformCAFiltersMac.mm:
* platform/graphics/ca/mac/PlatformCALayerMac.h:
* platform/graphics/ca/mac/PlatformCALayerMac.mm:
(PlatformCALayerMac::enumerateRectsBeingDrawn):
* platform/graphics/ca/win/AbstractCACFLayerTreeHost.h:
* platform/graphics/ca/win/CACFLayerTreeHost.cpp:
* platform/graphics/ca/win/CACFLayerTreeHost.h:
* platform/graphics/ca/win/CACFLayerTreeHostClient.h:
* platform/graphics/ca/win/LayerChangesFlusher.cpp:
* platform/graphics/ca/win/LayerChangesFlusher.h:
* platform/graphics/ca/win/LegacyCACFLayerTreeHost.cpp:
* platform/graphics/ca/win/LegacyCACFLayerTreeHost.h:
* platform/graphics/ca/win/PlatformCAAnimationWin.cpp:
(PlatformCAAnimation::copyTimingFunctionsFrom):
* platform/graphics/ca/win/PlatformCAFiltersWin.cpp:
* platform/graphics/ca/win/PlatformCALayerWin.cpp:
(PlatformCALayerWin::createCompatibleLayer):
* platform/graphics/ca/win/PlatformCALayerWin.h:
* platform/graphics/ca/win/PlatformCALayerWinInternal.cpp:
(PlatformCALayerWinInternal::drawTile):
* platform/graphics/ca/win/PlatformCALayerWinInternal.h:
* platform/graphics/ca/win/WKCACFViewLayerTreeHost.cpp:
* platform/graphics/ca/win/WKCACFViewLayerTreeHost.h:
* platform/graphics/cairo/DrawingBufferCairo.cpp:
(WebCore::DrawingBuffer::paintCompositedResultsToCanvas):
* platform/graphics/cairo/GraphicsContext3DCairo.cpp:
(WebCore::GraphicsContext3D::platformLayer):
* platform/graphics/cairo/ImageBufferCairo.cpp:
(WebCore::ImageBuffer::platformLayer):
* platform/graphics/efl/GraphicsContext3DEfl.cpp:
(WebCore::GraphicsContext3D::platformLayer):
* platform/graphics/efl/GraphicsContext3DPrivate.cpp:
* platform/graphics/efl/GraphicsContext3DPrivate.h:
* platform/graphics/gpu/DrawingBuffer.h:
* platform/graphics/gpu/LoopBlinnMathUtils.cpp:
* platform/graphics/gpu/TilingData.cpp:
* platform/graphics/gpu/mac/DrawingBufferMac.mm:
(WebCore::DrawingBuffer::frontColorBuffer):
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
(WebCore::MediaPlayerPrivateGStreamerBase::triggerRepaint):
(WebCore::MediaPlayerPrivateGStreamerBase::paint):
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
* platform/graphics/ios/MediaPlayerPrivateIOS.h:
* platform/graphics/ios/MediaPlayerPrivateIOS.mm:
(WebCore::MediaPlayerPrivateIOS::supportsAcceleratedRendering):
* platform/graphics/mac/MediaPlayerPrivateQTKit.h:
* platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
(WebCore::MediaPlayerPrivateQTKit::createQTMovieLayer):
(WebCore::MediaPlayerPrivateQTKit::destroyQTMovieLayer):
(WebCore::MediaPlayerPrivateQTKit::preferredRenderingMode):
(WebCore::MediaPlayerPrivateQTKit::platformLayer):
(WebCore::MediaPlayerPrivateQTKit::setClosedCaptionsVisible):
(WebCore::MediaPlayerPrivateQTKit::layerHostChanged):
(WebCore::MediaPlayerPrivateQTKit::acceleratedRenderingStateChanged):
(-[WebCoreMovieObserver layerHostChanged:]):
* platform/graphics/mac/WebGLLayer.h:
* platform/graphics/mac/WebGLLayer.mm:
* platform/graphics/mac/WebLayer.h:
* platform/graphics/mac/WebLayer.mm:
* platform/graphics/mac/WebTiledLayer.h:
* platform/graphics/mac/WebTiledLayer.mm:
* platform/graphics/opengl/GLDefs.h:
* platform/graphics/opengl/GLPlatformContext.cpp:
* platform/graphics/opengl/GLPlatformContext.h:
* platform/graphics/opengl/GLPlatformSurface.cpp:
* platform/graphics/opengl/GLPlatformSurface.h:
* platform/graphics/surfaces/GLTransportSurface.cpp:
* platform/graphics/surfaces/GLTransportSurface.h:
* platform/graphics/surfaces/glx/GLXConfigSelector.h:
* platform/graphics/surfaces/glx/GLXContext.cpp:
* platform/graphics/surfaces/glx/GLXContext.h:
* platform/graphics/surfaces/glx/GLXSurface.cpp:
* platform/graphics/surfaces/glx/GLXSurface.h:
* platform/graphics/texmap/TextureMapper.cpp:
* platform/graphics/texmap/TextureMapper.h:
* platform/graphics/texmap/TextureMapperBackingStore.cpp:
* platform/graphics/texmap/TextureMapperBackingStore.h:
* platform/graphics/texmap/TextureMapperFPSCounter.cpp:
* platform/graphics/texmap/TextureMapperFPSCounter.h:
* platform/graphics/texmap/TextureMapperGL.cpp:
* platform/graphics/texmap/TextureMapperGL.h:
* platform/graphics/texmap/TextureMapperLayer.cpp:
* platform/graphics/texmap/TextureMapperLayer.h:
* platform/graphics/texmap/TextureMapperShaderProgram.cpp:
* platform/graphics/texmap/TextureMapperSurfaceBackingStore.cpp:
* platform/graphics/texmap/TextureMapperSurfaceBackingStore.h:
* platform/graphics/texmap/TextureMapperTile.cpp:
* platform/graphics/texmap/TextureMapperTile.h:
* platform/graphics/texmap/TextureMapperTiledBackingStore.cpp:
* platform/graphics/texmap/TextureMapperTiledBackingStore.h:
* platform/graphics/win/GraphicsContext3DWin.cpp:
(WebCore::GraphicsContext3D::platformLayer):
* platform/graphics/win/MediaPlayerPrivateFullscreenWindow.cpp:
(WebCore::MediaPlayerPrivateFullscreenWindow::createWindow):
(WebCore::MediaPlayerPrivateFullscreenWindow::wndProc):
* platform/graphics/win/MediaPlayerPrivateFullscreenWindow.h:
* platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerLayoutSublayersOfLayer):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::MediaPlayerPrivateQuickTimeVisualContext):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::supportsFullscreen):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::platformMedia):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::platformLayer):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::naturalSize):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::paint):
(WebCore::CreateCGImageFromPixelBuffer):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::retrieveCurrentImage):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::currentRenderingMode):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::preferredRenderingMode):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::setUpVideoRendering):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::tearDownVideoRendering):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::hasSetUpVideoRendering):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::retrieveAndResetMovieTransform):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::createLayerForMovie):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::destroyLayerForMovie):
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::setPrivateBrowsingMode):
* platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h:
* platform/graphics/win/WKCAImageQueue.cpp:
* platform/graphics/win/WKCAImageQueue.h:
* platform/mac/ScrollbarThemeMac.h:
* platform/mac/ScrollbarThemeMac.mm:
* plugins/PluginViewBase.h:
* rendering/FlowThreadController.cpp:
(WebCore::FlowThreadController::updateRenderFlowThreadLayersIfNeeded):
* rendering/FlowThreadController.h:
* rendering/RenderBox.cpp:
(WebCore::RenderBox::styleWillChange):
(WebCore::isCandidateForOpaquenessTest):
(WebCore::layersUseImage):
(WebCore::RenderBox::imageChanged):
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::suspendAnimations):
(WebCore::RenderBoxModelObject::fixedBackgroundPaintsInLocalCoordinates):
* rendering/RenderBoxModelObject.h:
* rendering/RenderElement.cpp:
(WebCore::RenderElement::adjustStyleDifference):
(WebCore::RenderElement::setStyle):
(WebCore::RenderElement::styleWillChange):
* rendering/RenderEmbeddedObject.cpp:
(WebCore::RenderEmbeddedObject::allowsAcceleratedCompositing):
* rendering/RenderEmbeddedObject.h:
* rendering/RenderFlowThread.cpp:
(WebCore::RenderFlowThread::RenderFlowThread):
(WebCore::RenderFlowThread::layout):
(WebCore::RenderFlowThread::updateAllLayerToRegionMappings):
* rendering/RenderFlowThread.h:
* rendering/RenderFullScreen.cpp:
* rendering/RenderImage.cpp:
(WebCore::RenderImage::imageDimensionsChanged):
(WebCore::RenderImage::notifyFinished):
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::RenderLayer):
(WebCore::RenderLayer::~RenderLayer):
(WebCore::RenderLayer::canRender3DTransforms):
(WebCore::RenderLayer::paintsWithFilters):
(WebCore::RenderLayer::updateLayerPositions):
(WebCore::RenderLayer::updateDescendantsAreContiguousInStackingOrderRecursive):
(WebCore::RenderLayer::currentTransform):
(WebCore::RenderLayer::updateDescendantDependentFlags):
(WebCore::RenderLayer::checkIfDescendantClippingContextNeedsUpdate):
(WebCore::RenderLayer::shouldRepaintAfterLayout):
(WebCore::RenderLayer::enclosingFilterRepaintLayer):
(WebCore::RenderLayer::setFilterBackendNeedsRepaintingInRect):
(WebCore::RenderLayer::clippingRootForPainting):
(WebCore::RenderLayer::addChild):
(WebCore::RenderLayer::removeChild):
(WebCore::RenderLayer::removeOnlyThisLayer):
(WebCore::RenderLayer::scrollTo):
(WebCore::RenderLayer::updateCompositingLayersAfterScroll):
(WebCore::RenderLayer::invalidateScrollbarRect):
(WebCore::RenderLayer::invalidateScrollCornerRect):
(WebCore::RenderLayer::positionOverflowControls):
(WebCore::RenderLayer::updateScrollInfoAfterLayout):
(WebCore::RenderLayer::paintOverflowControls):
(WebCore::shouldDoSoftwarePaint):
(WebCore::RenderLayer::paintLayer):
(WebCore::RenderLayer::calculateClipRects):
* rendering/RenderLayer.h:
* rendering/RenderLayerBacking.cpp:
* rendering/RenderLayerBacking.h:
* rendering/RenderLayerCompositor.cpp:
* rendering/RenderLayerCompositor.h:
* rendering/RenderNamedFlowThread.cpp:
(WebCore::RenderNamedFlowThread::collectsGraphicsLayersUnderRegions):
* rendering/RenderNamedFlowThread.h:
* rendering/RenderObject.cpp:
(WebCore::RenderObject::containerForRepaint):
(WebCore::RenderObject::repaintUsingContainer):
* rendering/RenderTreeAsText.cpp:
(WebCore::write):
* rendering/RenderVideo.cpp:
(WebCore::RenderVideo::updatePlayer):
(WebCore::RenderVideo::acceleratedRenderingStateChanged):
* rendering/RenderVideo.h:
* rendering/RenderView.cpp:
(WebCore::RenderView::paintBoxDecorations):
(WebCore::RenderView::repaintRootContents):
(WebCore::RenderView::repaintRectangleInViewAndCompositedLayers):
(WebCore::RenderView::repaintViewAndCompositedLayers):
(WebCore::RenderView::setMaximalOutlineSize):
(WebCore::RenderView::compositor):
(WebCore::RenderView::setIsInWindow):
* rendering/RenderView.h:
* rendering/RenderWidget.cpp:
(WebCore::RenderWidget::setWidgetGeometry):
(WebCore::RenderWidget::requiresAcceleratedCompositing):
* rendering/RenderWidget.h:
* rendering/style/RenderStyle.cpp:
(WebCore::RenderStyle::changeRequiresLayout):
(WebCore::RenderStyle::changeRequiresLayerRepaint):
(WebCore::RenderStyle::changeRequiresRecompositeLayer):
(WebCore::RenderStyle::diff):
* rendering/style/RenderStyle.h:
* rendering/style/RenderStyleConstants.h:
* rendering/style/StyleRareNonInheritedData.cpp:
(WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
(WebCore::StyleRareNonInheritedData::operator==):
* rendering/style/StyleRareNonInheritedData.h:
* testing/Internals.cpp:
(WebCore::Internals::resetToConsistentState):
(WebCore::Internals::setHeaderHeight):
(WebCore::Internals::setFooterHeight):
Source/WebKit/efl:
Another patch will be required to remove the flag support from the EFL build system.
* WebCoreSupport/AcceleratedCompositingContextEfl.cpp:
* WebCoreSupport/AcceleratedCompositingContextEfl.h:
* WebCoreSupport/ChromeClientEfl.cpp:
(WebCore::ChromeClientEfl::allowedCompositingTriggers):
* WebCoreSupport/ChromeClientEfl.h:
* WebCoreSupport/PageClientEfl.cpp:
(PageClientEfl::acceleratedCompositingContext):
* WebCoreSupport/PageClientEfl.h:
* ewk/ewk_private.h:
* ewk/ewk_view.cpp:
(_ewk_view_priv_new):
(_ewk_view_priv_del):
(ewk_view_mark_for_sync):
* ewk/ewk_view_private.h:
Source/WebKit/gtk:
Another patch will be required to remove the flag support from the GTK build system.
* WebCoreSupport/AcceleratedCompositingContext.h:
* WebCoreSupport/AcceleratedCompositingContextGL.cpp:
* WebCoreSupport/ChromeClientGtk.cpp:
(WebKit::ChromeClient::widgetSizeChanged):
(WebKit::ChromeClient::forcePaint):
(WebKit::ChromeClient::invalidateContentsAndRootView):
(WebKit::ChromeClient::invalidateContentsForSlowScroll):
(WebKit::ChromeClient::scroll):
(WebKit::ChromeClient::allowedCompositingTriggers):
* WebCoreSupport/ChromeClientGtk.h:
* webkit/webkitwebview.cpp:
(webkit_web_view_update_settings):
(webkit_web_view_settings_notify):
(webkit_web_view_init):
* webkit/webkitwebviewprivate.h:
Source/WebKit/ios:
* WebCoreSupport/WebChromeClientIOS.h:
* WebCoreSupport/WebChromeClientIOS.mm:
(WebChromeClientIOS::attachRootGraphicsLayer):
* WebView/WebUIKitDelegate.h:
Source/WebKit/mac:
* Plugins/Hosted/WebHostedNetscapePluginView.mm:
(-[WebHostedNetscapePluginView createPlugin]):
(-[WebHostedNetscapePluginView createPluginLayer]):
* Plugins/WebNetscapePluginView.mm:
(-[WebNetscapePluginView createPlugin]):
(-[WebNetscapePluginView getVariable:value:]):
* Plugins/WebPluginController.mm:
(-[WebPluginController superlayerForPluginView:]):
* WebCoreSupport/WebChromeClient.h:
(WebChromeClient::allowedCompositingTriggers):
* WebCoreSupport/WebChromeClient.mm:
* WebCoreSupport/WebFrameLoaderClient.mm:
(PluginWidgetIOS::detachPluginLayer):
(NetscapePluginWidget::platformLayer):
* WebView/WebClipView.mm:
(-[WebClipView _immediateScrollToPoint:]):
* WebView/WebHTMLView.mm:
(setNeedsDisplayInRect):
(+[WebHTMLViewPrivate initialize]):
(-[WebHTMLViewPrivate clear]):
(-[WebHTMLView _setAsideSubviews]):
(-[WebHTMLView hitTest:]):
(-[WebHTMLView _isUsingAcceleratedCompositing]):
(-[WebHTMLView _compositingLayersHostingView]):
(-[WebHTMLView viewDidMoveToSuperview]):
(-[WebHTMLView drawRect:]):
* WebView/WebHTMLViewInternal.h:
* WebView/WebRenderLayer.mm:
(+[WebRenderLayer compositingInfoForLayer:]):
* WebView/WebView.mm:
(-[WebView _close]):
(-[WebView _setMediaLayer:forPluginView:]):
(-[WebView _postsAcceleratedCompositingNotifications]):
(-[WebView _setPostsAcceleratedCompositingNotifications:]):
(-[WebView _isUsingAcceleratedCompositing]):
(-[WebView _isSoftwareRenderable]):
(-[WebView close]):
* WebView/WebViewData.h:
* WebView/WebViewData.mm:
(WebViewLayerFlushScheduler::WebViewLayerFlushScheduler):
* WebView/WebViewInternal.h:
Source/WebKit/win:
Another patch will be required to remove the flag support from the Win build system.
* FullscreenVideoController.cpp:
(FullscreenVideoController::LayerClient::platformCALayerLayoutSublayersOfLayer):
(FullscreenVideoController::FullscreenVideoController):
(FullscreenVideoController::~FullscreenVideoController):
(FullscreenVideoController::enterFullscreen):
* FullscreenVideoController.h:
* WebCoreSupport/WebChromeClient.cpp:
(WebChromeClient::scheduleCompositingLayerFlush):
* WebCoreSupport/WebChromeClient.h:
(WebChromeClient::setNeedsOneShotDrawingSynchronization):
* WebPreferences.cpp:
(WebPreferences::acceleratedCompositingEnabled):
* WebView.cpp:
(WebView::WebView):
(WebView::~WebView):
(WebView::close):
(WebView::repaint):
(WebView::addToDirtyRegion):
(WebView::scrollBackingStore):
(WebView::sizeChanged):
(WebView::updateBackingStore):
(WebView::paint):
(WebView::setShouldInvertColors):
(WebView::WebViewWndProc):
(WebView::notifyPreferencesChanged):
(WebView::setAcceleratedCompositing):
* WebView.h:
Source/WebKit/wince:
Another patch will be required to remove the flag support from the WinCE build system.
* WebCoreSupport/ChromeClientWinCE.cpp:
(WebKit::ChromeClientWinCE::scheduleCompositingLayerFlush):
* WebCoreSupport/ChromeClientWinCE.h:
Source/WebKit2:
* PluginProcess/PluginControllerProxy.cpp:
(WebKit::PluginControllerProxy::PluginControllerProxy):
* PluginProcess/PluginCreationParameters.cpp:
(WebKit::PluginCreationParameters::PluginCreationParameters):
(WebKit::PluginCreationParameters::encode):
(WebKit::PluginCreationParameters::decode):
* PluginProcess/PluginCreationParameters.h:
* PluginProcess/PluginProcess.h:
* Shared/WebRenderLayer.cpp:
(WebKit::WebRenderLayer::WebRenderLayer):
* Shared/mac/RemoteLayerBackingStore.h:
* Shared/mac/RemoteLayerBackingStore.mm:
(RemoteLayerBackingStore::enumerateRectsBeingDrawn):
* UIProcess/API/efl/EvasGLContext.cpp:
* UIProcess/API/efl/EvasGLContext.h:
* UIProcess/API/efl/EvasGLSurface.cpp:
* UIProcess/API/efl/EvasGLSurface.h:
* UIProcess/API/efl/EwkView.cpp:
(EwkView::EwkView):
(EwkView::displayTimerFired):
(EwkView::createGLSurface):
(EwkView::handleEvasObjectCalculate):
(EwkView::handleEvasObjectShow):
(EwkView::takeSnapshot):
* UIProcess/API/efl/EwkView.h:
* UIProcess/API/efl/SnapshotImageGL.cpp:
(getImageSurfaceFromFrameBuffer):
* UIProcess/API/efl/SnapshotImageGL.h:
* UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestBase.cpp:
(EWK2UnitTest::EWK2UnitTestBase::SetUp):
* UIProcess/API/gtk/PageClientImpl.cpp:
(WebKit::PageClientImpl::updateAcceleratedCompositingMode):
* UIProcess/API/gtk/PageClientImpl.h:
* UIProcess/API/ios/PageClientImplIOS.h:
* UIProcess/API/ios/PageClientImplIOS.mm:
(WebKit::PageClientImpl::acceleratedCompositingRootLayer):
* UIProcess/CoordinatedGraphics/CoordinatedDrawingAreaProxy.cpp:
(WebKit::CoordinatedDrawingAreaProxy::~CoordinatedDrawingAreaProxy):
(WebKit::CoordinatedDrawingAreaProxy::visibilityDidChange):
(WebKit::CoordinatedDrawingAreaProxy::didUpdateBackingStoreState):
(WebKit::CoordinatedDrawingAreaProxy::enterAcceleratedCompositingMode):
(WebKit::CoordinatedDrawingAreaProxy::exitAcceleratedCompositingMode):
(WebKit::CoordinatedDrawingAreaProxy::updateAcceleratedCompositingMode):
(WebKit::CoordinatedDrawingAreaProxy::sendUpdateBackingStoreState):
(WebKit::CoordinatedDrawingAreaProxy::waitForAndDispatchDidUpdateBackingStoreState):
* UIProcess/CoordinatedGraphics/CoordinatedDrawingAreaProxy.h:
* UIProcess/CoordinatedGraphics/PageViewportController.cpp:
* UIProcess/CoordinatedGraphics/PageViewportController.h:
* UIProcess/CoordinatedGraphics/WebView.cpp:
(WebKit::WebView::setVisible):
* UIProcess/DrawingAreaProxy.h:
* UIProcess/DrawingAreaProxy.messages.in:
* UIProcess/DrawingAreaProxyImpl.cpp:
(WebKit::DrawingAreaProxyImpl::~DrawingAreaProxyImpl):
(WebKit::DrawingAreaProxyImpl::didUpdateBackingStoreState):
(WebKit::DrawingAreaProxyImpl::enterAcceleratedCompositingMode):
(WebKit::DrawingAreaProxyImpl::exitAcceleratedCompositingMode):
(WebKit::DrawingAreaProxyImpl::updateAcceleratedCompositingMode):
(WebKit::DrawingAreaProxyImpl::sendUpdateBackingStoreState):
(WebKit::DrawingAreaProxyImpl::waitForAndDispatchDidUpdateBackingStoreState):
* UIProcess/DrawingAreaProxyImpl.h:
* UIProcess/PageClient.h:
* UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
(WebKit::PluginProcessProxy::platformInitializePluginProcess):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::updateAcceleratedCompositingMode):
* UIProcess/WebPageProxy.h:
* UIProcess/efl/PageLoadClientEfl.cpp:
(WebKit::PageLoadClientEfl::didCommitLoadForFrame):
* UIProcess/efl/PageViewportControllerClientEfl.cpp:
* UIProcess/efl/ViewClientEfl.cpp:
(WebKit::ViewClientEfl::didChangeContentsSize):
(WebKit::ViewClientEfl::didChangeContentsPosition):
(WebKit::ViewClientEfl::didRenderFrame):
(WebKit::ViewClientEfl::didCompletePageTransition):
(WebKit::ViewClientEfl::didChangeViewportAttributes):
* UIProcess/mac/WebContextMac.mm:
(WebKit::WebContext::platformInitializeWebProcess):
* WebProcess/FullScreen/WebFullScreenManager.cpp:
(WebKit::screenRectOfContents):
* WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
(WebKit::NetscapePlugin::isAcceleratedCompositingEnabled):
* WebProcess/Plugins/PluginController.h:
* WebProcess/Plugins/PluginProxy.cpp:
(WebKit::PluginProxy::initialize):
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::layerTreeStateIsFrozen):
* WebProcess/WebCoreSupport/WebChromeClient.h:
* WebProcess/WebPage/CoordinatedGraphics/CoordinatedDrawingArea.cpp:
(WebKit::CoordinatedDrawingArea::layerHostDidFlushLayers):
(WebKit::CoordinatedDrawingArea::scheduleCompositingLayerFlush):
* WebProcess/WebPage/CoordinatedGraphics/CoordinatedDrawingArea.h:
* WebProcess/WebPage/DrawingArea.h:
* WebProcess/WebPage/DrawingAreaImpl.cpp:
(WebKit::DrawingAreaImpl::layerHostDidFlushLayers):
(WebKit::DrawingAreaImpl::scheduleCompositingLayerFlush):
(WebKit::DrawingAreaImpl::exitAcceleratedCompositingMode):
* WebProcess/WebPage/DrawingAreaImpl.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::exitAcceleratedCompositingMode):
(WebKit::WebPage::mainFrameDidLayout):
(WebKit::WebPage::didReceiveMessage):
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/mac/GraphicsLayerCARemote.cpp:
* WebProcess/WebPage/mac/GraphicsLayerCARemote.h:
* WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
(PlatformCALayerRemote::hostingContextID):
* WebProcess/WebPage/mac/PlatformCALayerRemote.h:
* WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.h:
* WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.mm:
(PlatformCALayerRemoteCustom::hostingContextID):
* WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.cpp:
(PlatformCALayerRemoteTiledBacking::setBorderColor):
* WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.h:
* WebProcess/WebProcess.cpp:
(WebKit::WebProcess::WebProcess):
* WebProcess/WebProcess.h:
Source/WTF:
* wtf/OwnPtrCommon.h:
* wtf/Platform.h:
* wtf/efl/OwnPtrEfl.cpp:
(WTF::deleteOwnedPtr):
Tools:
* DumpRenderTree/efl/DumpRenderTree.cpp:
(initEcoreEvas):
* EWebLauncher/main.c:
(windowCreate):
* MiniBrowser/efl/main.c:
(elm_main):
* TestWebKitAPI/efl/PlatformWebView.cpp:
(TestWebKitAPI::initEcoreEvas):
* WebKitTestRunner/cairo/TestInvocationCairo.cpp:
(WTR::TestInvocation::dumpPixelsAndCompareWithExpected):
* WebKitTestRunner/efl/PlatformWebViewEfl.cpp:
(WTR::initEcoreEvas):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@163079
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2014-01-30 Andrei Bucur <abucur@adobe.com>
+
+ Remove the ACCELERATED_COMPOSITING flag
+ https://bugs.webkit.org/show_bug.cgi?id=127833
+
+ Reviewed by Antti Koivisto.
+
+ Remove the USE(ACCELERATED_COMPOSITING) conditionals from the code base and make AC
+ mandatory.
+
+ * wtf/OwnPtrCommon.h:
+ * wtf/Platform.h:
+ * wtf/efl/OwnPtrEfl.cpp:
+ (WTF::deleteOwnedPtr):
+
2014-01-28 Michael Saboff <msaboff@apple.com>
Merge the jsCStack branch
#else
typedef struct _Evas_Object Evas_Object;
#endif
-#if USE(ACCELERATED_COMPOSITING)
typedef struct _Evas_GL Evas_GL;
#endif
-#endif
namespace WTF {
WTF_EXPORT_PRIVATE void deleteOwnedPtr(Eina_Hash*);
WTF_EXPORT_PRIVATE void deleteOwnedPtr(Eina_Module*);
WTF_EXPORT_PRIVATE void deleteOwnedPtr(Evas_Object*);
-#if USE(ACCELERATED_COMPOSITING)
WTF_EXPORT_PRIVATE void deleteOwnedPtr(Evas_GL*);
#endif
-#endif
} // namespace WTF
#endif
#endif
-/* Accelerated compositing */
-#if PLATFORM(MAC) || PLATFORM(IOS) || (PLATFORM(WIN) && !USE(WINGDI) && !PLATFORM(WIN_CAIRO))
-#define WTF_USE_ACCELERATED_COMPOSITING 1
-#endif
-
#if ENABLE(WEBGL) && !defined(WTF_USE_3D_GRAPHICS)
#define WTF_USE_3D_GRAPHICS 1
#endif
#define GST_API_VERSION_1 1
#endif
-#if USE(ACCELERATED_COMPOSITING) && PLATFORM(WIN_CAIRO)
+#if PLATFORM(WIN_CAIRO)
#define WTF_USE_TEXTURE_MAPPER 1
#endif
#include <Ecore_IMF.h>
#include <Eina.h>
#include <Evas.h>
-
-#if USE(ACCELERATED_COMPOSITING)
#include <Evas_GL.h>
-#endif
namespace WTF {
ecore_imf_context_del(ptr);
}
-#if USE(ACCELERATED_COMPOSITING)
void deleteOwnedPtr(Evas_GL* ptr)
{
if (ptr)
evas_gl_free(ptr);
}
-#endif
}
+2014-01-30 Andrei Bucur <abucur@adobe.com>
+
+ Remove the ACCELERATED_COMPOSITING flag
+ https://bugs.webkit.org/show_bug.cgi?id=127833
+
+ Reviewed by Antti Koivisto.
+
+ Remove the USE(ACCELERATED_COMPOSITING) conditionals from the code base and make AC
+ mandatory.
+
+ Tests: No new tests, no functional change.
+
+ * css/MediaQueryEvaluator.cpp:
+ (WebCore::transform_3dMediaFeatureEval):
+ * css/StyleResolver.cpp:
+ (WebCore::StyleResolver::canShareStyleWithElement):
+ * dom/Document.cpp:
+ (WebCore::Document::setVisualUpdatesAllowed):
+ (WebCore::Document::recalcStyle):
+ (WebCore::Document::createRenderTree):
+ (WebCore::Document::documentWillBecomeInactive):
+ (WebCore::Document::documentDidResumeFromPageCache):
+ (WebCore::Document::windowScreenDidChange):
+ * dom/PseudoElement.cpp:
+ (WebCore::PseudoElement::~PseudoElement):
+ * history/CachedFrame.cpp:
+ (WebCore::CachedFrameBase::CachedFrameBase):
+ (WebCore::CachedFrameBase::restore):
+ (WebCore::CachedFrame::CachedFrame):
+ * history/CachedFrame.h:
+ * history/CachedPage.cpp:
+ (WebCore::CachedPage::restore):
+ * history/CachedPage.h:
+ * history/PageCache.cpp:
+ (WebCore::PageCache::PageCache):
+ (WebCore::PageCache::markPagesForDeviceScaleChanged):
+ * history/PageCache.h:
+ * html/HTMLCanvasElement.cpp:
+ (WebCore::HTMLCanvasElement::getContext):
+ (WebCore::HTMLCanvasElement::reset):
+ (WebCore::HTMLCanvasElement::paintsIntoCanvasBuffer):
+ (WebCore::HTMLCanvasElement::createImageBuffer):
+ * html/HTMLMediaElement.cpp:
+ (WebCore::HTMLMediaElement::parseAttribute):
+ * html/HTMLMediaElement.h:
+ * html/canvas/CanvasRenderingContext.h:
+ * html/canvas/CanvasRenderingContext2D.cpp:
+ (WebCore::CanvasRenderingContext2D::didDraw):
+ * html/canvas/CanvasRenderingContext2D.h:
+ * html/canvas/WebGLRenderingContext.cpp:
+ (WebCore::WebGLRenderingContext::markContextChanged):
+ (WebCore::WebGLRenderingContext::reshape):
+ (WebCore::WebGLRenderingContext::platformLayer):
+ * html/canvas/WebGLRenderingContext.h:
+ * inspector/InspectorController.cpp:
+ (WebCore::InspectorController::InspectorController):
+ * inspector/InspectorInstrumentation.cpp:
+ (WebCore::InspectorInstrumentation::didCommitLoadImpl):
+ (WebCore::InspectorInstrumentation::pseudoElementDestroyedImpl):
+ * inspector/InspectorInstrumentation.h:
+ (WebCore::InspectorInstrumentation::pseudoElementDestroyed):
+ * inspector/InspectorLayerTreeAgent.cpp:
+ * inspector/InstrumentingAgents.cpp:
+ (WebCore::InstrumentingAgents::InstrumentingAgents):
+ (WebCore::InstrumentingAgents::reset):
+ * inspector/InstrumentingAgents.h:
+ * loader/EmptyClients.h:
+ * page/ChromeClient.h:
+ * page/Frame.cpp:
+ (WebCore::Frame::layerTreeAsText):
+ (WebCore::Frame::deviceOrPageScaleFactorChanged):
+ * page/Frame.h:
+ * page/FrameView.cpp:
+ (WebCore::FrameView::setFrameRect):
+ (WebCore::FrameView::scheduleLayerFlushAllowingThrottling):
+ (WebCore::FrameView::hasCompositedContent):
+ (WebCore::FrameView::hasCompositedContentIncludingDescendants):
+ (WebCore::FrameView::hasCompositingAncestor):
+ (WebCore::FrameView::enterCompositingMode):
+ (WebCore::FrameView::isEnclosedInCompositingLayer):
+ (WebCore::FrameView::flushCompositingStateIncludingSubframes):
+ (WebCore::FrameView::isSoftwareRenderable):
+ (WebCore::FrameView::layout):
+ (WebCore::FrameView::contentsInCompositedLayer):
+ (WebCore::FrameView::scrollContentsFastPath):
+ (WebCore::FrameView::scrollContentsSlowPath):
+ (WebCore::FrameView::setIsOverlapped):
+ (WebCore::FrameView::delegatesScrollingDidChange):
+ (WebCore::FrameView::scrollPositionChanged):
+ (WebCore::FrameView::updateCompositingLayersAfterScrolling):
+ (WebCore::FrameView::visibleContentsResized):
+ (WebCore::FrameView::addedOrRemovedScrollbar):
+ (WebCore::FrameView::disableLayerFlushThrottlingTemporarilyForInteraction):
+ (WebCore::FrameView::updateLayerFlushThrottlingInAllFrames):
+ (WebCore::FrameView::adjustTiledBackingCoverage):
+ (WebCore::FrameView::hasExtendedBackground):
+ (WebCore::FrameView::extendedBackgroundRect):
+ (WebCore::FrameView::setBackgroundExtendsBeyondPage):
+ (WebCore::FrameView::performPostLayoutTasks):
+ (WebCore::FrameView::paintContents):
+ (WebCore::FrameView::setTracksRepaints):
+ (WebCore::FrameView::resetTrackedRepaints):
+ (WebCore::FrameView::setScrollingPerformanceLoggingEnabled):
+ (WebCore::FrameView::setExposedRect):
+ * page/FrameView.h:
+ * page/Page.cpp:
+ (WebCore::Page::setPageScaleFactor):
+ (WebCore::Page::setDeviceScaleFactor):
+ * page/Settings.cpp:
+ (WebCore::Settings::setBackgroundShouldExtendBeyondPage):
+ * page/animation/AnimationBase.cpp:
+ (WebCore::AnimationBase::freezeAtTime):
+ * page/animation/AnimationController.cpp:
+ (WebCore::AnimationController::supportsAcceleratedAnimationOfProperty):
+ * page/animation/CSSPropertyAnimation.cpp:
+ (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap):
+ (WebCore::CSSPropertyAnimation::blendProperties):
+ (WebCore::CSSPropertyAnimation::animationOfPropertyIsAccelerated):
+ * page/animation/CSSPropertyAnimation.h:
+ * page/animation/CompositeAnimation.cpp:
+ (WebCore::CompositeAnimation::updateTransitions):
+ * page/animation/ImplicitAnimation.cpp:
+ (WebCore::ImplicitAnimation::animate):
+ (WebCore::ImplicitAnimation::startAnimation):
+ (WebCore::ImplicitAnimation::pauseAnimation):
+ (WebCore::ImplicitAnimation::endAnimation):
+ (WebCore::ImplicitAnimation::timeToNextService):
+ * page/animation/KeyframeAnimation.cpp:
+ (WebCore::KeyframeAnimation::animate):
+ (WebCore::KeyframeAnimation::startAnimation):
+ (WebCore::KeyframeAnimation::pauseAnimation):
+ (WebCore::KeyframeAnimation::endAnimation):
+ (WebCore::KeyframeAnimation::timeToNextService):
+ * page/ios/FrameIOS.mm:
+ (WebCore::Frame::viewportOffsetChanged):
+ (WebCore::Frame::containsTiledBackingLayers):
+ * page/scrolling/AsyncScrollingCoordinator.cpp:
+ (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
+ * page/scrolling/ScrollingCoordinator.cpp:
+ (WebCore::ScrollingCoordinator::coordinatesScrollingForFrameView):
+ (WebCore::ScrollingCoordinator::computeNonFastScrollableRegion):
+ (WebCore::ScrollingCoordinator::verticalScrollbarLayerForScrollableArea):
+ (WebCore::ScrollingCoordinator::scrollLayerForFrameView):
+ (WebCore::ScrollingCoordinator::headerLayerForFrameView):
+ (WebCore::ScrollingCoordinator::footerLayerForFrameView):
+ (WebCore::ScrollingCoordinator::counterScrollingLayerForFrameView):
+ (WebCore::ScrollingCoordinator::hasVisibleSlowRepaintViewportConstrainedObjects):
+ * page/scrolling/ScrollingCoordinator.h:
+ * platform/ScrollView.cpp:
+ (WebCore::positionScrollCornerLayer):
+ (WebCore::ScrollView::positionScrollbarLayers):
+ (WebCore::ScrollView::paintScrollbars):
+ (WebCore::ScrollView::paint):
+ * platform/ScrollableArea.cpp:
+ (WebCore::ScrollableArea::invalidateScrollbar):
+ (WebCore::ScrollableArea::invalidateScrollCorner):
+ (WebCore::ScrollableArea::horizontalScrollbarLayerDidChange):
+ (WebCore::ScrollableArea::hasLayerForHorizontalScrollbar):
+ (WebCore::ScrollableArea::hasLayerForVerticalScrollbar):
+ (WebCore::ScrollableArea::hasLayerForScrollCorner):
+ * platform/ScrollableArea.h:
+ * platform/ScrollbarTheme.h:
+ * platform/efl/EflScreenUtilities.cpp:
+ (WebCore::applyFallbackCursor):
+ * platform/graphics/GraphicsContext3D.h:
+ * platform/graphics/GraphicsContext3DPrivate.cpp:
+ (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
+ (WebCore::GraphicsContext3DPrivate::paintToTextureMapper):
+ * platform/graphics/GraphicsContext3DPrivate.h:
+ * platform/graphics/GraphicsLayer.cpp:
+ * platform/graphics/GraphicsLayer.h:
+ * platform/graphics/GraphicsLayerAnimation.cpp:
+ * platform/graphics/GraphicsLayerAnimation.h:
+ * platform/graphics/GraphicsLayerClient.h:
+ * platform/graphics/GraphicsLayerFactory.h:
+ * platform/graphics/GraphicsLayerUpdater.cpp:
+ * platform/graphics/GraphicsLayerUpdater.h:
+ * platform/graphics/ImageBuffer.cpp:
+ * platform/graphics/ImageBuffer.h:
+ * platform/graphics/MediaPlayer.cpp:
+ (WebCore::MediaPlayer::platformLayer):
+ (WebCore::MediaPlayer::supportsAcceleratedRendering):
+ * platform/graphics/MediaPlayer.h:
+ * platform/graphics/MediaPlayerPrivate.h:
+ * platform/graphics/PlatformLayer.h:
+ * platform/graphics/TextTrackRepresentation.cpp:
+ * platform/graphics/TextTrackRepresentation.h:
+ * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
+ (WebCore::MediaPlayerPrivateAVFoundation::currentRenderingMode):
+ (WebCore::MediaPlayerPrivateAVFoundation::preferredRenderingMode):
+ (WebCore::MediaPlayerPrivateAVFoundation::setUpVideoRendering):
+ (WebCore::MediaPlayerPrivateAVFoundation::tearDownVideoRendering):
+ * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
+ * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
+ * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
+ (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::platformLayer):
+ (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::acceleratedRenderingStateChanged):
+ * platform/graphics/ca/GraphicsLayerCA.cpp:
+ * platform/graphics/ca/GraphicsLayerCA.h:
+ * platform/graphics/ca/LayerFlushScheduler.cpp:
+ * platform/graphics/ca/LayerFlushScheduler.h:
+ * platform/graphics/ca/LayerFlushSchedulerClient.h:
+ * platform/graphics/ca/PlatformCAAnimation.h:
+ * platform/graphics/ca/PlatformCAFilters.h:
+ * platform/graphics/ca/PlatformCALayer.h:
+ * platform/graphics/ca/PlatformCALayerClient.h:
+ * platform/graphics/ca/mac/LayerFlushSchedulerMac.cpp:
+ * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
+ (PlatformCAAnimation::copyTimingFunctionsFrom):
+ * platform/graphics/ca/mac/PlatformCAFiltersMac.mm:
+ * platform/graphics/ca/mac/PlatformCALayerMac.h:
+ * platform/graphics/ca/mac/PlatformCALayerMac.mm:
+ (PlatformCALayerMac::enumerateRectsBeingDrawn):
+ * platform/graphics/ca/win/AbstractCACFLayerTreeHost.h:
+ * platform/graphics/ca/win/CACFLayerTreeHost.cpp:
+ * platform/graphics/ca/win/CACFLayerTreeHost.h:
+ * platform/graphics/ca/win/CACFLayerTreeHostClient.h:
+ * platform/graphics/ca/win/LayerChangesFlusher.cpp:
+ * platform/graphics/ca/win/LayerChangesFlusher.h:
+ * platform/graphics/ca/win/LegacyCACFLayerTreeHost.cpp:
+ * platform/graphics/ca/win/LegacyCACFLayerTreeHost.h:
+ * platform/graphics/ca/win/PlatformCAAnimationWin.cpp:
+ (PlatformCAAnimation::copyTimingFunctionsFrom):
+ * platform/graphics/ca/win/PlatformCAFiltersWin.cpp:
+ * platform/graphics/ca/win/PlatformCALayerWin.cpp:
+ (PlatformCALayerWin::createCompatibleLayer):
+ * platform/graphics/ca/win/PlatformCALayerWin.h:
+ * platform/graphics/ca/win/PlatformCALayerWinInternal.cpp:
+ (PlatformCALayerWinInternal::drawTile):
+ * platform/graphics/ca/win/PlatformCALayerWinInternal.h:
+ * platform/graphics/ca/win/WKCACFViewLayerTreeHost.cpp:
+ * platform/graphics/ca/win/WKCACFViewLayerTreeHost.h:
+ * platform/graphics/cairo/DrawingBufferCairo.cpp:
+ (WebCore::DrawingBuffer::paintCompositedResultsToCanvas):
+ * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
+ (WebCore::GraphicsContext3D::platformLayer):
+ * platform/graphics/cairo/ImageBufferCairo.cpp:
+ (WebCore::ImageBuffer::platformLayer):
+ * platform/graphics/efl/GraphicsContext3DEfl.cpp:
+ (WebCore::GraphicsContext3D::platformLayer):
+ * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
+ * platform/graphics/efl/GraphicsContext3DPrivate.h:
+ * platform/graphics/gpu/DrawingBuffer.h:
+ * platform/graphics/gpu/LoopBlinnMathUtils.cpp:
+ * platform/graphics/gpu/TilingData.cpp:
+ * platform/graphics/gpu/mac/DrawingBufferMac.mm:
+ (WebCore::DrawingBuffer::frontColorBuffer):
+ * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
+ (WebCore::MediaPlayerPrivateGStreamerBase::triggerRepaint):
+ (WebCore::MediaPlayerPrivateGStreamerBase::paint):
+ * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
+ * platform/graphics/ios/MediaPlayerPrivateIOS.h:
+ * platform/graphics/ios/MediaPlayerPrivateIOS.mm:
+ (WebCore::MediaPlayerPrivateIOS::supportsAcceleratedRendering):
+ * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
+ * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
+ (WebCore::MediaPlayerPrivateQTKit::createQTMovieLayer):
+ (WebCore::MediaPlayerPrivateQTKit::destroyQTMovieLayer):
+ (WebCore::MediaPlayerPrivateQTKit::preferredRenderingMode):
+ (WebCore::MediaPlayerPrivateQTKit::platformLayer):
+ (WebCore::MediaPlayerPrivateQTKit::setClosedCaptionsVisible):
+ (WebCore::MediaPlayerPrivateQTKit::layerHostChanged):
+ (WebCore::MediaPlayerPrivateQTKit::acceleratedRenderingStateChanged):
+ (-[WebCoreMovieObserver layerHostChanged:]):
+ * platform/graphics/mac/WebGLLayer.h:
+ * platform/graphics/mac/WebGLLayer.mm:
+ * platform/graphics/mac/WebLayer.h:
+ * platform/graphics/mac/WebLayer.mm:
+ * platform/graphics/mac/WebTiledLayer.h:
+ * platform/graphics/mac/WebTiledLayer.mm:
+ * platform/graphics/opengl/GLDefs.h:
+ * platform/graphics/opengl/GLPlatformContext.cpp:
+ * platform/graphics/opengl/GLPlatformContext.h:
+ * platform/graphics/opengl/GLPlatformSurface.cpp:
+ * platform/graphics/opengl/GLPlatformSurface.h:
+ * platform/graphics/surfaces/GLTransportSurface.cpp:
+ * platform/graphics/surfaces/GLTransportSurface.h:
+ * platform/graphics/surfaces/glx/GLXConfigSelector.h:
+ * platform/graphics/surfaces/glx/GLXContext.cpp:
+ * platform/graphics/surfaces/glx/GLXContext.h:
+ * platform/graphics/surfaces/glx/GLXSurface.cpp:
+ * platform/graphics/surfaces/glx/GLXSurface.h:
+ * platform/graphics/texmap/TextureMapper.cpp:
+ * platform/graphics/texmap/TextureMapper.h:
+ * platform/graphics/texmap/TextureMapperBackingStore.cpp:
+ * platform/graphics/texmap/TextureMapperBackingStore.h:
+ * platform/graphics/texmap/TextureMapperFPSCounter.cpp:
+ * platform/graphics/texmap/TextureMapperFPSCounter.h:
+ * platform/graphics/texmap/TextureMapperGL.cpp:
+ * platform/graphics/texmap/TextureMapperGL.h:
+ * platform/graphics/texmap/TextureMapperLayer.cpp:
+ * platform/graphics/texmap/TextureMapperLayer.h:
+ * platform/graphics/texmap/TextureMapperShaderProgram.cpp:
+ * platform/graphics/texmap/TextureMapperSurfaceBackingStore.cpp:
+ * platform/graphics/texmap/TextureMapperSurfaceBackingStore.h:
+ * platform/graphics/texmap/TextureMapperTile.cpp:
+ * platform/graphics/texmap/TextureMapperTile.h:
+ * platform/graphics/texmap/TextureMapperTiledBackingStore.cpp:
+ * platform/graphics/texmap/TextureMapperTiledBackingStore.h:
+ * platform/graphics/win/GraphicsContext3DWin.cpp:
+ (WebCore::GraphicsContext3D::platformLayer):
+ * platform/graphics/win/MediaPlayerPrivateFullscreenWindow.cpp:
+ (WebCore::MediaPlayerPrivateFullscreenWindow::createWindow):
+ (WebCore::MediaPlayerPrivateFullscreenWindow::wndProc):
+ * platform/graphics/win/MediaPlayerPrivateFullscreenWindow.h:
+ * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerLayoutSublayersOfLayer):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::MediaPlayerPrivateQuickTimeVisualContext):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::supportsFullscreen):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::platformMedia):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::platformLayer):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::naturalSize):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::paint):
+ (WebCore::CreateCGImageFromPixelBuffer):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::retrieveCurrentImage):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::currentRenderingMode):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::preferredRenderingMode):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::setUpVideoRendering):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::tearDownVideoRendering):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::hasSetUpVideoRendering):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::retrieveAndResetMovieTransform):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::createLayerForMovie):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::destroyLayerForMovie):
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::setPrivateBrowsingMode):
+ * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h:
+ * platform/graphics/win/WKCAImageQueue.cpp:
+ * platform/graphics/win/WKCAImageQueue.h:
+ * platform/mac/ScrollbarThemeMac.h:
+ * platform/mac/ScrollbarThemeMac.mm:
+ * plugins/PluginViewBase.h:
+ * rendering/FlowThreadController.cpp:
+ (WebCore::FlowThreadController::updateRenderFlowThreadLayersIfNeeded):
+ * rendering/FlowThreadController.h:
+ * rendering/RenderBox.cpp:
+ (WebCore::RenderBox::styleWillChange):
+ (WebCore::isCandidateForOpaquenessTest):
+ (WebCore::layersUseImage):
+ (WebCore::RenderBox::imageChanged):
+ * rendering/RenderBoxModelObject.cpp:
+ (WebCore::RenderBoxModelObject::suspendAnimations):
+ (WebCore::RenderBoxModelObject::fixedBackgroundPaintsInLocalCoordinates):
+ * rendering/RenderBoxModelObject.h:
+ * rendering/RenderElement.cpp:
+ (WebCore::RenderElement::adjustStyleDifference):
+ (WebCore::RenderElement::setStyle):
+ (WebCore::RenderElement::styleWillChange):
+ * rendering/RenderEmbeddedObject.cpp:
+ (WebCore::RenderEmbeddedObject::allowsAcceleratedCompositing):
+ * rendering/RenderEmbeddedObject.h:
+ * rendering/RenderFlowThread.cpp:
+ (WebCore::RenderFlowThread::RenderFlowThread):
+ (WebCore::RenderFlowThread::layout):
+ (WebCore::RenderFlowThread::updateAllLayerToRegionMappings):
+ * rendering/RenderFlowThread.h:
+ * rendering/RenderFullScreen.cpp:
+ * rendering/RenderImage.cpp:
+ (WebCore::RenderImage::imageDimensionsChanged):
+ (WebCore::RenderImage::notifyFinished):
+ * rendering/RenderLayer.cpp:
+ (WebCore::RenderLayer::RenderLayer):
+ (WebCore::RenderLayer::~RenderLayer):
+ (WebCore::RenderLayer::canRender3DTransforms):
+ (WebCore::RenderLayer::paintsWithFilters):
+ (WebCore::RenderLayer::updateLayerPositions):
+ (WebCore::RenderLayer::updateDescendantsAreContiguousInStackingOrderRecursive):
+ (WebCore::RenderLayer::currentTransform):
+ (WebCore::RenderLayer::updateDescendantDependentFlags):
+ (WebCore::RenderLayer::checkIfDescendantClippingContextNeedsUpdate):
+ (WebCore::RenderLayer::shouldRepaintAfterLayout):
+ (WebCore::RenderLayer::enclosingFilterRepaintLayer):
+ (WebCore::RenderLayer::setFilterBackendNeedsRepaintingInRect):
+ (WebCore::RenderLayer::clippingRootForPainting):
+ (WebCore::RenderLayer::addChild):
+ (WebCore::RenderLayer::removeChild):
+ (WebCore::RenderLayer::removeOnlyThisLayer):
+ (WebCore::RenderLayer::scrollTo):
+ (WebCore::RenderLayer::updateCompositingLayersAfterScroll):
+ (WebCore::RenderLayer::invalidateScrollbarRect):
+ (WebCore::RenderLayer::invalidateScrollCornerRect):
+ (WebCore::RenderLayer::positionOverflowControls):
+ (WebCore::RenderLayer::updateScrollInfoAfterLayout):
+ (WebCore::RenderLayer::paintOverflowControls):
+ (WebCore::shouldDoSoftwarePaint):
+ (WebCore::RenderLayer::paintLayer):
+ (WebCore::RenderLayer::calculateClipRects):
+ * rendering/RenderLayer.h:
+ * rendering/RenderLayerBacking.cpp:
+ * rendering/RenderLayerBacking.h:
+ * rendering/RenderLayerCompositor.cpp:
+ * rendering/RenderLayerCompositor.h:
+ * rendering/RenderNamedFlowThread.cpp:
+ (WebCore::RenderNamedFlowThread::collectsGraphicsLayersUnderRegions):
+ * rendering/RenderNamedFlowThread.h:
+ * rendering/RenderObject.cpp:
+ (WebCore::RenderObject::containerForRepaint):
+ (WebCore::RenderObject::repaintUsingContainer):
+ * rendering/RenderTreeAsText.cpp:
+ (WebCore::write):
+ * rendering/RenderVideo.cpp:
+ (WebCore::RenderVideo::updatePlayer):
+ (WebCore::RenderVideo::acceleratedRenderingStateChanged):
+ * rendering/RenderVideo.h:
+ * rendering/RenderView.cpp:
+ (WebCore::RenderView::paintBoxDecorations):
+ (WebCore::RenderView::repaintRootContents):
+ (WebCore::RenderView::repaintRectangleInViewAndCompositedLayers):
+ (WebCore::RenderView::repaintViewAndCompositedLayers):
+ (WebCore::RenderView::setMaximalOutlineSize):
+ (WebCore::RenderView::compositor):
+ (WebCore::RenderView::setIsInWindow):
+ * rendering/RenderView.h:
+ * rendering/RenderWidget.cpp:
+ (WebCore::RenderWidget::setWidgetGeometry):
+ (WebCore::RenderWidget::requiresAcceleratedCompositing):
+ * rendering/RenderWidget.h:
+ * rendering/style/RenderStyle.cpp:
+ (WebCore::RenderStyle::changeRequiresLayout):
+ (WebCore::RenderStyle::changeRequiresLayerRepaint):
+ (WebCore::RenderStyle::changeRequiresRecompositeLayer):
+ (WebCore::RenderStyle::diff):
+ * rendering/style/RenderStyle.h:
+ * rendering/style/RenderStyleConstants.h:
+ * rendering/style/StyleRareNonInheritedData.cpp:
+ (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
+ (WebCore::StyleRareNonInheritedData::operator==):
+ * rendering/style/StyleRareNonInheritedData.h:
+ * testing/Internals.cpp:
+ (WebCore::Internals::resetToConsistentState):
+ (WebCore::Internals::setHeaderHeight):
+ (WebCore::Internals::setFooterHeight):
+
2014-01-30 Krzysztof Czech <k.czech@samsung.com>
AX: Clean up AccessibilityRenderObject
#include "StyleResolver.h"
#include <wtf/HashMap.h>
-#if ENABLE(3D_RENDERING) && USE(ACCELERATED_COMPOSITING)
+#if ENABLE(3D_RENDERING)
#include "RenderLayerCompositor.h"
#endif
#if ENABLE(3D_RENDERING)
bool threeDEnabled = false;
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* view = frame->contentRenderer())
threeDEnabled = view->compositor().canRender3DTransforms();
-#endif
returnValueIfNoParameter = threeDEnabled;
have3dRendering = threeDEnabled ? 1 : 0;
if (style->transitions() || style->animations())
return false;
-#if USE(ACCELERATED_COMPOSITING)
// Turn off style sharing for elements that can gain layers for reasons outside of the style system.
// See comments in RenderObject::setStyle().
if (element->hasTagName(iframeTag) || element->hasTagName(frameTag) || element->hasTagName(embedTag) || element->hasTagName(objectTag) || element->hasTagName(appletTag) || element->hasTagName(canvasTag))
// With proxying, the media elements are backed by a RenderEmbeddedObject.
if ((element->hasTagName(videoTag) || element->hasTagName(audioTag)) && toHTMLMediaElement(element)->shouldUseVideoPluginProxy())
return false;
-#endif
-
#endif
if (elementHasDirectionAuto(element))
#include "PointerLockController.h"
#include "PopStateEvent.h"
#include "ProcessingInstruction.h"
+#include "RenderLayerCompositor.h"
#include "RenderView.h"
#include "RenderWidget.h"
#include "ResourceLoadScheduler.h"
#include <wtf/TemporaryChange.h>
#include <wtf/text/StringBuffer.h>
-#if USE(ACCELERATED_COMPOSITING)
-#include "RenderLayerCompositor.h"
-#endif
-
#if ENABLE(SHARED_WORKERS)
#include "SharedWorkerRepository.h"
#endif
}
}
-#if USE(ACCELERATED_COMPOSITING)
if (view())
view()->updateCompositingLayersAfterLayout();
-#endif
if (RenderView* renderView = this->renderView())
renderView->repaintViewAndCompositedLayers();
Style::resolveTree(*this, change);
-#if USE(ACCELERATED_COMPOSITING)
frameView.updateCompositingLayersAfterStyleChange();
-#endif
clearNeedsStyleRecalc();
clearChildNeedsStyleRecalc();
m_renderView = createRenderer<RenderView>(*this, RenderStyle::create());
Node::setRenderer(m_renderView.get());
-#if USE(ACCELERATED_COMPOSITING)
renderView()->setIsInWindow(true);
-#endif
recalcStyle(Style::Force);
}
void Document::documentWillBecomeInactive()
{
-#if USE(ACCELERATED_COMPOSITING)
if (renderView())
renderView()->setIsInWindow(false);
-#endif
}
void Document::documentWillSuspendForPageCache()
for (Vector<Element*>::iterator i = elements.begin(); i != end; ++i)
(*i)->documentDidResumeFromPageCache();
-#if USE(ACCELERATED_COMPOSITING)
if (renderView())
renderView()->setIsInWindow(true);
-#endif
ASSERT(page());
page()->lockAllOverlayScrollbarsToHidden(false);
m_scriptedAnimationController->windowScreenDidChange(displayID);
#endif
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* view = renderView()) {
if (view->usesCompositing())
view->compositor().windowScreenDidChange(displayID);
}
-#endif
}
String Document::displayStringModifiedByEncoding(const String& str) const
PseudoElement::~PseudoElement()
{
ASSERT(!m_hostElement);
-#if USE(ACCELERATED_COMPOSITING)
InspectorInstrumentation::pseudoElementDestroyed(document().page(), this);
-#endif
}
PassRefPtr<RenderStyle> PseudoElement::customStyleForRenderer()
#include "Logging.h"
#include "MainFrame.h"
#include "Page.h"
+#include "PageCache.h"
#include "PageTransitionEvent.h"
#include "ScriptController.h"
#include "SerializedScriptValue.h"
#include "ChromeClient.h"
#endif
-#if USE(ACCELERATED_COMPOSITING)
-#include "PageCache.h"
-#endif
-
namespace WebCore {
DEFINE_DEBUG_ONLY_GLOBAL(WTF::RefCountedLeakCounter, cachedFrameCounter, ("CachedFrame"));
, m_mousePressNode(frame.eventHandler().mousePressNode())
, m_url(frame.document()->url())
, m_isMainFrame(!frame.tree().parent())
-#if USE(ACCELERATED_COMPOSITING)
, m_isComposited(frame.view()->hasCompositedContent())
-#endif
{
}
// cached page.
frame.script().updatePlatformScriptObjects();
-#if USE(ACCELERATED_COMPOSITING)
if (m_isComposited)
frame.view()->restoreBackingStores();
-#endif
frame.loader().client().didRestoreFromPageCache();
frame.loader().client().savePlatformDataToCachedFrame(this);
-#if USE(ACCELERATED_COMPOSITING)
if (m_isComposited && pageCache()->shouldClearBackingStores())
frame.view()->clearBackingStores();
-#endif
// documentWillSuspendForPageCache() can set up a layout timer on the FrameView, so clear timers after that.
frame.clearTimers();
std::unique_ptr<ScriptCachedFrameData> m_cachedFrameScriptData;
std::unique_ptr<CachedFramePlatformData> m_cachedFramePlatformData;
bool m_isMainFrame;
-#if USE(ACCELERATED_COMPOSITING)
bool m_isComposited;
-#endif
Vector<std::unique_ptr<CachedFrame>> m_childFrames;
};
frame->document()->visitedLinkState().invalidateStyleForAllLinks();
}
-#if USE(ACCELERATED_COMPOSITING)
if (m_needsDeviceScaleChanged) {
page.mainFrame().deviceOrPageScaleFactorChanged();
}
-#endif
if (m_needsFullStyleRecalc)
page.setNeedsRecalcStyleInAllFrames();
void markForCaptionPreferencesChanged() { m_needsCaptionPreferencesChanged = true; }
#endif
-#if USE(ACCELERATED_COMPOSITING)
void markForDeviceScaleChanged() { m_needsDeviceScaleChanged = true; }
-#endif
private:
void destroy();
, m_size(0)
, m_head(0)
, m_tail(0)
-#if USE(ACCELERATED_COMPOSITING)
, m_shouldClearBackingStores(false)
-#endif
{
}
}
}
-
-#if USE(ACCELERATED_COMPOSITING)
void PageCache::markPagesForDeviceScaleChanged(Page* page)
{
for (HistoryItem* current = m_head; current; current = current->m_next) {
cachedPage->markForDeviceScaleChanged();
}
}
-#endif
#if ENABLE(VIDEO_TRACK)
void PageCache::markPagesForCaptionPreferencesChanged()
void markPagesForCaptionPreferencesChanged();
#endif
-#if USE(ACCELERATED_COMPOSITING)
bool shouldClearBackingStores() const { return m_shouldClearBackingStores; }
void setShouldClearBackingStores(bool flag) { m_shouldClearBackingStores = flag; }
void markPagesForDeviceScaleChanged(Page*);
-#endif
private:
PageCache(); // Use pageCache() instead.
HistoryItem* m_head;
HistoryItem* m_tail;
-#if USE(ACCELERATED_COMPOSITING)
bool m_shouldClearBackingStores;
-#endif
};
// Function to obtain the global page cache.
usesDashbardCompatibilityMode = settings->usesDashboardBackwardCompatibilityMode();
#endif
m_context = CanvasRenderingContext2D::create(this, document().inQuirksMode(), usesDashbardCompatibilityMode);
-#if USE(IOSURFACE_CANVAS_BACKING_STORE) || (ENABLE(ACCELERATED_2D_CANVAS) && USE(ACCELERATED_COMPOSITING))
+#if USE(IOSURFACE_CANVAS_BACKING_STORE) || ENABLE(ACCELERATED_2D_CANVAS)
// Need to make sure a RenderLayer and compositing layer get created for the Canvas
setNeedsStyleRecalc(SyntheticStyleChange);
#endif
if (m_rendererIsCanvas) {
if (oldSize != size()) {
toRenderHTMLCanvas(renderer)->canvasSizeChanged();
-#if USE(ACCELERATED_COMPOSITING)
if (renderBox() && renderBox()->hasAcceleratedCompositing())
renderBox()->contentChanged(CanvasChanged);
-#endif
}
if (hadImageBuffer)
renderer->repaint();
return true;
#endif
-#if USE(ACCELERATED_COMPOSITING)
if (!m_context->isAccelerated())
return true;
if (renderBox() && renderBox()->hasAcceleratedCompositing())
return false;
-#endif
+
return true;
}
size_t numBytes = 4 * m_imageBuffer->internalSize().width() * m_imageBuffer->internalSize().height();
scriptExecutionContext()->vm()->heap.reportExtraMemoryCost(numBytes);
-#if USE(IOSURFACE_CANVAS_BACKING_STORE) || (ENABLE(ACCELERATED_2D_CANVAS) && USE(ACCELERATED_COMPOSITING))
+#if USE(IOSURFACE_CANVAS_BACKING_STORE) || ENABLE(ACCELERATED_2D_CANVAS)
if (m_context && m_context->is2d())
// Recalculate compositing requirements if acceleration state changed.
const_cast<HTMLCanvasElement*>(this)->setNeedsStyleRecalc(SyntheticStyleChange);
#include "PageActivityAssertionToken.h"
#include "PageGroup.h"
#include "ProgressTracker.h"
+#include "RenderLayerCompositor.h"
#include "RenderVideo.h"
#include "RenderView.h"
#include "ScriptController.h"
#include <wtf/Ref.h>
#include <wtf/text/CString.h>
-#if USE(ACCELERATED_COMPOSITING)
-#include "RenderLayerCompositor.h"
-#endif
-
#if ENABLE(PLUGIN_PROXY_FOR_VIDEO)
#include "RenderEmbeddedObject.h"
#include "SubframeLoader.h"
endProcessingMediaPlayerCallback();
}
-#if USE(ACCELERATED_COMPOSITING)
bool HTMLMediaElement::mediaPlayerRenderingCanBeAccelerated(MediaPlayer*)
{
if (renderer() && renderer()->isVideo())
// Kick off a fake recalcStyle that will update the compositing tree.
setNeedsStyleRecalc(SyntheticStyleChange);
}
-#endif
#if PLATFORM(WIN) && USE(AVFOUNDATION)
GraphicsDeviceAdapter* HTMLMediaElement::mediaPlayerGraphicsDeviceAdapter(const MediaPlayer*) const
beginProcessingMediaPlayerCallback();
if (displayMode() == PosterWaitingForVideo) {
setDisplayMode(Video);
-#if USE(ACCELERATED_COMPOSITING)
mediaPlayerRenderingModeChanged(m_player.get());
-#endif
}
endProcessingMediaPlayerCallback();
}
return m_player ? m_player->platformMedia() : NoPlatformMedia;
}
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* HTMLMediaElement::platformLayer() const
{
#if PLATFORM(IOS)
renderer()->updateFromElement();
}
#endif
-#endif
bool HTMLMediaElement::hasClosedCaptions() const
{
virtual bool supportsScanning() const override;
PlatformMedia platformMedia() const;
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* platformLayer() const;
#if PLATFORM(IOS)
PlatformLayer* borrowPlatformLayer();
void returnPlatformLayer(PlatformLayer*);
-#endif
#endif
enum DelayedActionType {
virtual void mediaPlayerResourceNotSupported(MediaPlayer*) override;
virtual void mediaPlayerRepaint(MediaPlayer*) override;
virtual void mediaPlayerSizeChanged(MediaPlayer*) override;
-#if USE(ACCELERATED_COMPOSITING)
virtual bool mediaPlayerRenderingCanBeAccelerated(MediaPlayer*) override;
virtual void mediaPlayerRenderingModeChanged(MediaPlayer*) override;
-#endif
virtual void mediaPlayerEngineUpdated(MediaPlayer*) override;
virtual void mediaPlayerFirstVideoFrameAvailable(MediaPlayer*) override;
virtual bool isAccelerated() const { return false; }
virtual void paintRenderingResultsToCanvas() {}
-
-#if USE(ACCELERATED_COMPOSITING)
virtual PlatformLayer* platformLayer() const { return 0; }
-#endif
protected:
CanvasRenderingContext(HTMLCanvasElement*);
#include "HTMLVideoElement.h"
#include "ImageData.h"
#include "RenderElement.h"
+#include "RenderLayer.h"
#include "SecurityOrigin.h"
#include "StrokeStyleApplier.h"
#include "StyleProperties.h"
#include "TextMetrics.h"
#include "TextRun.h"
-#if USE(ACCELERATED_COMPOSITING)
-#include "RenderLayer.h"
-#endif
-
#include <wtf/CheckedArithmetic.h>
#include <wtf/MathExtras.h>
#include <wtf/text/StringBuilder.h>
if (!state().m_hasInvertibleTransform)
return;
-#if ENABLE(ACCELERATED_2D_CANVAS) && USE(ACCELERATED_COMPOSITING)
+#if ENABLE(ACCELERATED_2D_CANVAS)
// If we are drawing to hardware and we have a composited layer, just call contentChanged().
if (isAccelerated()) {
RenderBox* renderBox = canvas()->renderBox();
return state().m_font;
}
-#if ENABLE(ACCELERATED_2D_CANVAS) && USE(ACCELERATED_COMPOSITING)
+#if ENABLE(ACCELERATED_2D_CANVAS)
PlatformLayer* CanvasRenderingContext2D::platformLayer() const
{
return canvas()->buffer() ? canvas()->buffer()->platformLayer() : 0;
#include "GraphicsTypes.h"
#include "ImageBuffer.h"
#include "Path.h"
+#include "PlatformLayer.h"
#include <wtf/Vector.h>
#include <wtf/text/WTFString.h>
-#if USE(ACCELERATED_COMPOSITING)
-#include "PlatformLayer.h"
-#endif
-
namespace WebCore {
class CanvasGradient;
virtual bool hasInvertibleTransform() const override { return state().m_hasInvertibleTransform; }
-#if ENABLE(ACCELERATED_2D_CANVAS) && USE(ACCELERATED_COMPOSITING)
+#if ENABLE(ACCELERATED_2D_CANVAS)
virtual PlatformLayer* platformLayer() const override;
#endif
m_drawingBuffer->markContentsChanged();
m_layerCleared = false;
-#if USE(ACCELERATED_COMPOSITING)
RenderBox* renderBox = canvas()->renderBox();
if (renderBox && renderBox->hasAcceleratedCompositing()) {
m_markedCanvasDirty = true;
canvas()->clearCopiedImage();
renderBox->contentChanged(CanvasChanged);
} else {
-#endif
if (!m_markedCanvasDirty) {
m_markedCanvasDirty = true;
canvas()->didDraw(FloatRect(FloatPoint(0, 0), clampedCanvasSize()));
}
-#if USE(ACCELERATED_COMPOSITING)
}
-#endif
}
bool WebGLRenderingContext::clearIfComposited(GC3Dbitfield mask)
height = clamp(height, 1, maxHeight);
if (m_needsUpdate) {
-#if USE(ACCELERATED_COMPOSITING)
RenderBox* renderBox = canvas()->renderBox();
if (renderBox && renderBox->hasAcceleratedCompositing())
renderBox->contentChanged(CanvasChanged);
-#endif
m_needsUpdate = false;
}
m_restoreTimer.startOneShot(0);
}
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* WebGLRenderingContext::platformLayer() const
{
return (!isContextLost()) ? m_context->platformLayer() : 0;
}
-#endif
void WebGLRenderingContext::removeSharedObject(WebGLSharedObject* object)
{
GraphicsContext3D* graphicsContext3D() const { return m_context.get(); }
WebGLContextGroup* contextGroup() const { return m_contextGroup.get(); }
-#if USE(ACCELERATED_COMPOSITING)
virtual PlatformLayer* platformLayer() const override;
-#endif
void reshape(int width, int height);
m_agents.append(std::make_unique<InspectorInputAgent>(m_instrumentingAgents.get(), &page));
-#if USE(ACCELERATED_COMPOSITING)
m_agents.append(std::make_unique<InspectorLayerTreeAgent>(m_instrumentingAgents.get()));
-#endif
ASSERT(m_injectedScriptManager->commandLineAPIHost());
if (CommandLineAPIHost* commandLineAPIHost = m_injectedScriptManager->commandLineAPIHost()) {
#endif
if (InspectorDOMAgent* domAgent = instrumentingAgents->inspectorDOMAgent())
domAgent->setDocument(page->mainFrame().document());
-#if USE(ACCELERATED_COMPOSITING)
if (InspectorLayerTreeAgent* layerTreeAgent = instrumentingAgents->inspectorLayerTreeAgent())
layerTreeAgent->reset();
-#endif
}
if (InspectorDOMAgent* domAgent = instrumentingAgents->inspectorDOMAgent())
domAgent->didCommitLoad(loader->frame()->document());
return nullptr;
}
-#if USE(ACCELERATED_COMPOSITING)
void InspectorInstrumentation::layerTreeDidChangeImpl(InstrumentingAgents* instrumentingAgents)
{
if (InspectorLayerTreeAgent* layerTreeAgent = instrumentingAgents->inspectorLayerTreeAgent())
if (InspectorLayerTreeAgent* layerTreeAgent = instrumentingAgents->inspectorLayerTreeAgent())
layerTreeAgent->pseudoElementDestroyed(pseudoElement);
}
-#endif
} // namespace WebCore
static void registerInstrumentingAgents(InstrumentingAgents*);
static void unregisterInstrumentingAgents(InstrumentingAgents*);
-#if USE(ACCELERATED_COMPOSITING)
static void layerTreeDidChange(Page*);
static void renderLayerDestroyed(Page*, const RenderLayer*);
static void pseudoElementDestroyed(Page*, PseudoElement*);
-#endif
private:
#if ENABLE(INSPECTOR)
static void cancelPauseOnNativeEvent(InstrumentingAgents*);
static InspectorTimelineAgent* retrieveTimelineAgent(const InspectorInstrumentationCookie&);
-#if USE(ACCELERATED_COMPOSITING)
static void layerTreeDidChangeImpl(InstrumentingAgents*);
static void renderLayerDestroyedImpl(InstrumentingAgents*, const RenderLayer*);
static void pseudoElementDestroyedImpl(InstrumentingAgents*, PseudoElement*);
-#endif
static int s_frontendCounter;
#endif
#endif
}
-#if USE(ACCELERATED_COMPOSITING)
inline void InspectorInstrumentation::layerTreeDidChange(Page* page)
{
#if ENABLE(INSPECTOR)
UNUSED_PARAM(pseudoElement);
#endif
}
-#endif
#if ENABLE(INSPECTOR)
inline InstrumentingAgents* InspectorInstrumentation::instrumentingAgentsForContext(ScriptExecutionContext* context)
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
#if ENABLE(INSPECTOR)
#include "InspectorLayerTreeAgent.h"
} // namespace WebCore
#endif // ENABLE(INSPECTOR)
-#endif // USE(ACCELERATED_COMPOSITING)
, m_inspectorAgent(nullptr)
, m_inspectorPageAgent(nullptr)
, m_inspectorCSSAgent(nullptr)
-#if USE(ACCELERATED_COMPOSITING)
, m_inspectorLayerTreeAgent(nullptr)
-#endif
, m_inspectorConsoleAgent(nullptr)
, m_inspectorDOMAgent(nullptr)
, m_inspectorResourceAgent(nullptr)
m_inspectorAgent = nullptr;
m_inspectorPageAgent = nullptr;
m_inspectorCSSAgent = nullptr;
-#if USE(ACCELERATED_COMPOSITING)
m_inspectorLayerTreeAgent = nullptr;
-#endif
m_inspectorConsoleAgent = nullptr;
m_inspectorDOMAgent = nullptr;
m_inspectorResourceAgent = nullptr;
InspectorCanvasAgent* inspectorCanvasAgent() const { return m_inspectorCanvasAgent; }
void setInspectorCanvasAgent(InspectorCanvasAgent* agent) { m_inspectorCanvasAgent = agent; }
-#if USE(ACCELERATED_COMPOSITING)
InspectorLayerTreeAgent* inspectorLayerTreeAgent() const { return m_inspectorLayerTreeAgent; }
void setInspectorLayerTreeAgent(InspectorLayerTreeAgent* agent) { m_inspectorLayerTreeAgent = agent; }
-#endif
private:
InstrumentingAgents(Inspector::InspectorEnvironment&);
Inspector::InspectorAgent* m_inspectorAgent;
InspectorPageAgent* m_inspectorPageAgent;
InspectorCSSAgent* m_inspectorCSSAgent;
-#if USE(ACCELERATED_COMPOSITING)
InspectorLayerTreeAgent* m_inspectorLayerTreeAgent;
-#endif
InspectorConsoleAgent* m_inspectorConsoleAgent;
InspectorDOMAgent* m_inspectorDOMAgent;
InspectorResourceAgent* m_inspectorResourceAgent;
virtual void scrollRectIntoView(const IntRect&) const override { }
-#if USE(ACCELERATED_COMPOSITING)
virtual void attachRootGraphicsLayer(Frame*, GraphicsLayer*) override { }
virtual void setNeedsOneShotDrawingSynchronization() override { }
virtual void scheduleCompositingLayerFlush() override { }
-#endif
#if PLATFORM(WIN)
virtual void setLastSetCursorToCurrentCursor() override { }
virtual bool shouldPaintEntireContents() const { return false; }
-#if USE(ACCELERATED_COMPOSITING)
// Allows ports to customize the type of graphics layers created by this page.
virtual GraphicsLayerFactory* graphicsLayerFactory() const { return 0; }
// Returns true if layer tree updates are disabled.
virtual bool layerTreeStateIsFrozen() const { return false; }
-#endif
virtual PassRefPtr<ScrollingCoordinator> createScrollingCoordinator(Page*) const { return nullptr; }
#include "Page.h"
#include "PageCache.h"
#include "PageGroup.h"
+#include "RenderLayerCompositor.h"
#include "RenderTableCell.h"
#include "RenderText.h"
#include "RenderTextControl.h"
#include <wtf/StdLibExtras.h>
#include <yarr/RegularExpression.h>
-#if USE(ACCELERATED_COMPOSITING)
-#include "RenderLayerCompositor.h"
-#endif
-
#if ENABLE(SVG)
#include "SVGDocument.h"
#include "SVGDocumentExtensions.h"
String Frame::layerTreeAsText(LayerTreeFlags flags) const
{
-#if USE(ACCELERATED_COMPOSITING)
document()->updateLayout();
if (!contentRenderer())
return String();
return contentRenderer()->compositor().layerTreeAsText(flags);
-#else
- UNUSED_PARAM(flags);
- return String();
-#endif
}
String Frame::trackedRepaintRectsAsText() const
}
}
-#if USE(ACCELERATED_COMPOSITING)
void Frame::deviceOrPageScaleFactorChanged()
{
for (RefPtr<Frame> child = tree().firstChild(); child; child = child->tree().nextSibling())
if (RenderView* root = contentRenderer())
root->compositor().deviceOrPageScaleFactorChanged();
}
-#endif
bool Frame::isURLAllowed(const URL& url) const
{
// Scale factor of this frame with respect to the container.
float frameScaleFactor() const;
-#if USE(ACCELERATED_COMPOSITING)
void deviceOrPageScaleFactorChanged();
-#endif
#if PLATFORM(IOS)
const ViewportArguments& viewportArguments() const;
#include "RenderIFrame.h"
#include "RenderLayer.h"
#include "RenderLayerBacking.h"
+#include "RenderLayerCompositor.h"
#include "RenderScrollbar.h"
#include "RenderScrollbarPart.h"
#include "RenderStyle.h"
#include "StyleResolver.h"
#include "TextResourceDecoder.h"
#include "TextStream.h"
+#include "TiledBacking.h"
#include <wtf/CurrentTime.h>
#include <wtf/Ref.h>
#include <wtf/TemporaryChange.h>
-#if USE(ACCELERATED_COMPOSITING)
-#include "RenderLayerCompositor.h"
-#include "TiledBacking.h"
-#endif
-
#if ENABLE(SVG)
#include "RenderSVGRoot.h"
#include "SVGDocument.h"
updateScrollableAreaSet();
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* renderView = this->renderView()) {
if (renderView->usesCompositing())
renderView->compositor().frameViewDidChangeSize();
}
-#endif
if (!frameFlatteningEnabled())
sendResizeEventIfNeeded();
}
}
-#if USE(ACCELERATED_COMPOSITING)
void FrameView::updateCompositingLayersAfterStyleChange()
{
RenderView* renderView = this->renderView();
return;
view->compositor().scheduleLayerFlush(true /* canThrottle */);
}
-#endif // USE(ACCELERATED_COMPOSITING)
void FrameView::setHeaderHeight(int headerHeight)
{
bool FrameView::hasCompositedContent() const
{
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* renderView = this->renderView())
return renderView->compositor().inCompositingMode();
-#endif
return false;
}
bool FrameView::hasCompositedContentIncludingDescendants() const
{
-#if USE(ACCELERATED_COMPOSITING)
for (Frame* frame = m_frame.get(); frame; frame = frame->tree().traverseNext(m_frame.get())) {
RenderView* renderView = frame->contentRenderer();
if (RenderLayerCompositor* compositor = renderView ? &renderView->compositor() : 0) {
break;
}
}
-#endif
return false;
}
bool FrameView::hasCompositingAncestor() const
{
-#if USE(ACCELERATED_COMPOSITING)
for (Frame* frame = this->frame().tree().parent(); frame; frame = frame->tree().parent()) {
if (FrameView* view = frame->view()) {
if (view->hasCompositedContent())
return true;
}
}
-#endif
return false;
}
// Sometimes (for plug-ins) we need to eagerly go into compositing mode.
void FrameView::enterCompositingMode()
{
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* renderView = this->renderView()) {
renderView->compositor().enableCompositingMode();
if (!needsLayout())
renderView->compositor().scheduleCompositingLayerUpdate();
}
-#endif
}
bool FrameView::isEnclosedInCompositingLayer() const
{
-#if USE(ACCELERATED_COMPOSITING)
auto frameOwnerRenderer = frame().ownerRenderer();
if (frameOwnerRenderer && frameOwnerRenderer->containerForRepaint())
return true;
if (FrameView* parentView = parentFrameView())
return parentView->isEnclosedInCompositingLayer();
-#endif
return false;
}
bool FrameView::flushCompositingStateIncludingSubframes()
{
-#if USE(ACCELERATED_COMPOSITING)
bool allFramesFlushed = flushCompositingStateForThisFrame(&frame());
for (Frame* child = frame().tree().firstChild(); child; child = child->tree().traverseNext(&frame())) {
allFramesFlushed &= flushed;
}
return allFramesFlushed;
-#else // USE(ACCELERATED_COMPOSITING)
- return true;
-#endif
}
bool FrameView::isSoftwareRenderable() const
{
-#if USE(ACCELERATED_COMPOSITING)
RenderView* renderView = this->renderView();
return !renderView || !renderView->compositor().has3DContent();
-#else
- return true;
-#endif
}
void FrameView::didMoveOnscreen()
layer->updateLayerPositionsAfterLayout(renderView()->layer(), updateLayerPositionFlags(layer, subtree, m_needsFullRepaint));
-#if USE(ACCELERATED_COMPOSITING)
updateCompositingLayersAfterLayout();
-#endif
m_layoutCount++;
bool FrameView::contentsInCompositedLayer() const
{
-#if USE(ACCELERATED_COMPOSITING)
RenderView* renderView = this->renderView();
if (renderView && renderView->isComposited()) {
GraphicsLayer* layer = renderView->layer()->backing()->graphicsLayer();
if (layer && layer->drawsContent())
return true;
}
-#endif
+
return false;
}
for (auto& renderer : *m_viewportConstrainedObjects) {
if (!renderer->style().hasViewportConstrainedPosition())
continue;
-#if USE(ACCELERATED_COMPOSITING)
if (renderer->isComposited())
continue;
-#endif
// Fixed items should always have layers.
ASSERT(renderer->hasLayer());
RenderLayer* layer = toRenderBoxModelObject(renderer)->layer();
-#if USE(ACCELERATED_COMPOSITING)
if (layer->viewportConstrainedNotCompositedReason() == RenderLayer::NotCompositedForBoundsOutOfView
|| layer->viewportConstrainedNotCompositedReason() == RenderLayer::NotCompositedForNoVisibleContent) {
// Don't invalidate for invisible fixed layers.
continue;
}
-#endif
#if ENABLE(CSS_FILTERS)
if (layer->hasAncestorWithFilterOutsets()) {
IntRect scrolledRect = updateRect;
scrolledRect.move(scrollDelta);
updateRect.unite(scrolledRect);
-#if USE(ACCELERATED_COMPOSITING)
if (isCompositedContentLayer) {
updateRect = rootViewToContents(updateRect);
ASSERT(renderView());
renderView()->layer()->setBackingNeedsRepaintInRect(updateRect);
continue;
}
-#endif
if (clipsRepaints())
updateRect.intersect(rectToScroll);
hostWindow()->invalidateContentsAndRootView(updateRect, false);
void FrameView::scrollContentsSlowPath(const IntRect& updateRect)
{
-#if USE(ACCELERATED_COMPOSITING)
if (contentsInCompositedLayer()) {
// FIXME: respect paintsEntireContents()?
IntRect updateRect = visibleContentRect(LegacyIOSDocumentVisibleRect);
return;
}
}
-#endif
ScrollView::scrollContentsSlowPath(updateRect);
}
m_isOverlapped = isOverlapped;
updateCanBlitOnScrollRecursively();
-
-#if USE(ACCELERATED_COMPOSITING)
+
if (hasCompositedContentIncludingDescendants()) {
// Overlap can affect compositing tests, so if it changes, we need to trigger
// a layer update in the parent document.
}
}
}
-#endif
}
bool FrameView::isOverlappedIncludingAncestors() const
void FrameView::delegatesScrollingDidChange()
{
-#if USE(ACCELERATED_COMPOSITING)
// When we switch to delgatesScrolling mode, we should destroy the scrolling/clipping layers in RenderLayerCompositor.
if (hasCompositedContent())
clearBackingStores();
-#endif
}
#if USE(TILED_BACKING_STORE)
frame().eventHandler().sendScrollEvent();
frame().eventHandler().dispatchFakeMouseMoveEventSoon();
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* renderView = this->renderView()) {
if (renderView->usesCompositing())
renderView->compositor().frameViewDidScroll();
}
-#endif
}
void FrameView::updateLayerPositionsAfterScrolling()
void FrameView::updateCompositingLayersAfterScrolling()
{
-#if USE(ACCELERATED_COMPOSITING)
if (!shouldUpdateCompositingLayersAfterScrolling())
return;
if (RenderView* renderView = this->renderView())
renderView->compositor().updateCompositingLayers(CompositingUpdateOnScroll);
}
-#endif
}
bool FrameView::isRubberBandInProgress() const
if (!useFixedLayout() && needsLayout())
layout();
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* renderView = this->renderView()) {
if (renderView->usesCompositing())
renderView->compositor().frameViewDidChangeSize();
}
-#endif
}
void FrameView::addedOrRemovedScrollbar()
{
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* renderView = this->renderView()) {
if (renderView->usesCompositing())
renderView->compositor().frameViewDidAddOrRemoveScrollbars();
}
-#endif
}
void FrameView::disableLayerFlushThrottlingTemporarilyForInteraction()
{
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* view = renderView())
view->compositor().disableLayerFlushThrottlingTemporarilyForInteraction();
-#endif
}
void FrameView::updateLayerFlushThrottlingInAllFrames()
{
-#if USE(ACCELERATED_COMPOSITING)
bool isMainLoadProgressing = frame().page()->progress().isMainLoadProgressing();
for (Frame* frame = m_frame.get(); frame; frame = frame->tree().traverseNext(m_frame.get())) {
if (RenderView* renderView = frame->contentRenderer())
renderView->compositor().setLayerFlushThrottlingEnabled(isMainLoadProgressing);
}
-#endif
}
void FrameView::adjustTiledBackingCoverage()
if (!m_speculativeTilingEnabled)
enableSpeculativeTilingIfNeeded();
-#if USE(ACCELERATED_COMPOSITING)
RenderView* renderView = this->renderView();
if (renderView && renderView->layer()->backing())
renderView->layer()->backing()->adjustTiledBackingCoverage();
-#endif
#if PLATFORM(IOS)
if (TileCache* tileCache = this->tileCache())
tileCache->setSpeculativeTileCreationEnabled(m_speculativeTilingEnabled);
bool FrameView::hasExtendedBackground() const
{
-#if USE(ACCELERATED_COMPOSITING)
if (!frame().settings().backgroundShouldExtendBeyondPage())
return false;
return false;
return tiledBacking->hasMargins();
-#else
- return false;
-#endif
}
IntRect FrameView::extendedBackgroundRect() const
{
-#if USE(ACCELERATED_COMPOSITING)
TiledBacking* tiledBacking = this->tiledBacking();
if (!tiledBacking)
return IntRect();
return tiledBacking->bounds();
-#else
- RenderView* renderView = this->renderView();
- if (!renderView)
- return IntRect();
-
- return renderView->unscaledDocumentRect();
-#endif
}
-#if USE(ACCELERATED_COMPOSITING)
void FrameView::setBackgroundExtendsBeyondPage(bool extendBackground)
{
RenderView* renderView = this->renderView();
backing->setTiledBackingHasMargins(extendBackground);
}
-#endif
bool FrameView::shouldUpdateWhileOffscreen() const
{
scrollingCoordinator->frameViewLayoutUpdated(this);
}
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* renderView = this->renderView()) {
if (renderView->usesCompositing())
renderView->compositor().frameViewDidLayout();
}
-#endif
scrollToAnchor();
FontCachePurgePreventer fontCachePurgePreventer;
-#if USE(ACCELERATED_COMPOSITING)
if (!p->paintingDisabled() && !document->printing())
flushCompositingStateForThisFrame(&frame());
-#endif
PaintBehavior oldPaintBehavior = m_paintBehavior;
frame().document()->updateLayout();
}
-#if USE(ACCELERATED_COMPOSITING)
for (Frame* frame = &m_frame->tree().top(); frame; frame = frame->tree().traverseNext()) {
if (RenderView* renderView = frame->contentRenderer())
renderView->compositor().setTracksRepaints(trackRepaints);
}
-#endif
resetTrackedRepaints();
m_isTrackingRepaints = trackRepaints;
void FrameView::resetTrackedRepaints()
{
m_trackedRepaintRects.clear();
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* renderView = this->renderView())
renderView->compositor().resetTrackedRepaintRects();
-#endif
}
String FrameView::trackedRepaintRectsAsText() const
void FrameView::setScrollingPerformanceLoggingEnabled(bool flag)
{
-#if USE(ACCELERATED_COMPOSITING)
if (TiledBacking* tiledBacking = this->tiledBacking())
tiledBacking->setScrollingPerformanceLoggingEnabled(flag);
-#else
- UNUSED_PARAM(flag);
-#endif
}
void FrameView::didAddScrollbar(Scrollbar* scrollbar, ScrollbarOrientation orientation)
m_exposedRect = exposedRect;
-#if USE(ACCELERATED_COMPOSITING)
// FIXME: We should support clipping to the exposed rect for subframes as well.
if (m_frame->isMainFrame()) {
if (TiledBacking* tiledBacking = this->tiledBacking())
tiledBacking->setExposedRect(exposedRect);
}
-#endif
}
} // namespace WebCore
void serviceScriptedAnimations(double monotonicAnimationStartTime);
#endif
-#if USE(ACCELERATED_COMPOSITING)
void updateCompositingLayersAfterStyleChange();
void updateCompositingLayersAfterLayout();
bool flushCompositingStateForThisFrame(Frame* rootFrameForFlush);
// In the future when any ScrollableArea can have a node in th ScrollingTree, this should
// become a virtual function on ScrollableArea.
uint64_t scrollLayerID() const;
-#endif
bool hasCompositedContent() const;
bool hasCompositedContentIncludingDescendants() const;
bool hasExtendedBackground() const;
IntRect extendedBackgroundRect() const;
-#if USE(ACCELERATED_COMPOSITING)
void setBackgroundExtendsBeyondPage(bool);
-#endif
bool shouldUpdateWhileOffscreen() const;
void setShouldUpdateWhileOffscreen(bool);
virtual ScrollableArea* enclosingScrollableArea() const override;
virtual IntRect scrollableAreaBoundingBox() const override;
virtual bool scrollAnimatorEnabled() const override;
-#if USE(ACCELERATED_COMPOSITING)
virtual bool usesCompositedScrolling() const override;
virtual GraphicsLayer* layerForScrolling() const override;
virtual GraphicsLayer* layerForHorizontalScrollbar() const override;
virtual GraphicsLayer* layerForScrollCorner() const override;
#if ENABLE(RUBBER_BANDING)
virtual GraphicsLayer* layerForOverhangAreas() const override;
-#endif
#endif
// Override scrollbar notifications to update the AXObject cache.
mainFrame().view()->invalidateRect(IntRect(LayoutRect::infiniteRect()));
}
-#if USE(ACCELERATED_COMPOSITING)
mainFrame().deviceOrPageScaleFactorChanged();
-#endif
if (view && view->fixedElementsLayoutRelativeToFrame())
view->setViewportConstrainedObjectsNeedLayout();
m_deviceScaleFactor = scaleFactor;
setNeedsRecalcStyleInAllFrames();
-#if USE(ACCELERATED_COMPOSITING)
mainFrame().deviceOrPageScaleFactorChanged();
pageCache()->markPagesForDeviceScaleChanged(this);
-#endif
for (Frame* frame = &mainFrame(); frame; frame = frame->tree().traverseNext())
frame->editor().deviceScaleFactorChanged();
m_backgroundShouldExtendBeyondPage = shouldExtend;
-#if USE(ACCELERATED_COMPOSITING)
m_page->mainFrame().view()->setBackgroundExtendsBeyondPage(shouldExtend);
-#endif
}
#if USE(AVFOUNDATION)
else
m_pauseTime = m_startTime + t - m_animation->delay();
-#if USE(ACCELERATED_COMPOSITING)
if (m_object && m_object->isComposited())
toRenderBoxModelObject(m_object)->suspendAnimations(m_pauseTime);
-#endif
}
double AnimationBase::beginAnimationUpdateTime() const
bool AnimationController::supportsAcceleratedAnimationOfProperty(CSSPropertyID property)
{
-#if USE(ACCELERATED_COMPOSITING)
return CSSPropertyAnimation::animationOfPropertyIsAccelerated(property);
-#else
- UNUSED_PARAM(property);
- return false;
-#endif
}
} // namespace WebCore
CSSPropertyID property() const { return m_prop; }
-#if USE(ACCELERATED_COMPOSITING)
virtual bool animationIsAccelerated() const { return false; }
-#endif
private:
CSSPropertyID m_prop;
};
-#if USE(ACCELERATED_COMPOSITING)
class PropertyWrapperAcceleratedOpacity : public PropertyWrapper<float> {
public:
PropertyWrapperAcceleratedOpacity()
}
};
#endif
-#endif // USE(ACCELERATED_COMPOSITING)
static inline size_t shadowListLength(const ShadowData* shadow)
{
new LengthPropertyWrapper<LengthBox>(CSSPropertyClip, &RenderStyle::clip, &RenderStyle::setClip),
-#if USE(ACCELERATED_COMPOSITING)
new PropertyWrapperAcceleratedOpacity(),
new PropertyWrapperAcceleratedTransform(),
#if ENABLE(CSS_FILTERS)
new PropertyWrapperAcceleratedFilter(),
-#endif
-#else
- new PropertyWrapper<float>(CSSPropertyOpacity, &RenderStyle::opacity, &RenderStyle::setOpacity),
- new PropertyWrapper<const TransformOperations&>(CSSPropertyWebkitTransform, &RenderStyle::transform, &RenderStyle::setTransform),
-#if ENABLE(CSS_FILTERS)
- new PropertyWrapper<const FilterOperations&>(CSSPropertyWebkitFilter, &RenderStyle::filter, &RenderStyle::setFilter),
-#endif
#endif
new PropertyWrapperClipPath(CSSPropertyWebkitClipPath, &RenderStyle::clipPath, &RenderStyle::setClipPath),
AnimationPropertyWrapperBase* wrapper = CSSPropertyAnimationWrapperMap::instance().wrapperForProperty(prop);
if (wrapper) {
wrapper->blend(anim, dst, a, b, progress);
-#if USE(ACCELERATED_COMPOSITING)
return !wrapper->animationIsAccelerated() || !anim->isAccelerated();
-#else
- return true;
-#endif
}
return false;
}
-#if USE(ACCELERATED_COMPOSITING)
bool CSSPropertyAnimation::animationOfPropertyIsAccelerated(CSSPropertyID prop)
{
AnimationPropertyWrapperBase* wrapper = CSSPropertyAnimationWrapperMap::instance().wrapperForProperty(prop);
return wrapper ? wrapper->animationIsAccelerated() : false;
}
-#endif
// Note: this is inefficient. It's only called from pauseTransitionAtTime().
HashSet<CSSPropertyID> CSSPropertyAnimation::animatableShorthandsAffectingProperty(CSSPropertyID property)
class CSSPropertyAnimation {
public:
-#if USE(ACCELERATED_COMPOSITING)
static bool animationOfPropertyIsAccelerated(CSSPropertyID);
-#endif
static bool propertiesEqual(CSSPropertyID, const RenderStyle* a, const RenderStyle* b);
static CSSPropertyID getPropertyAtIndex(int, bool& isShorthand);
static int getNumProperties();
// list. In this case, the latter one overrides the earlier one, so we
// behave as though this is a running animation being replaced.
if (!implAnim->isTargetPropertyEqual(prop, targetStyle)) {
-#if USE(ACCELERATED_COMPOSITING)
// For accelerated animations we need to return a new RenderStyle with the _current_ value
// of the property, so that restarted transitions use the correct starting point.
if (CSSPropertyAnimation::animationOfPropertyIsAccelerated(prop) && implAnim->isAccelerated()) {
implAnim->blendPropertyValueInStyle(prop, modifiedCurrentStyle.get());
}
-#endif
LOG(Animations, "Removing existing ImplicitAnimation %p for property %s", implAnim, getPropertyName(prop));
animationController()->animationWillBeRemoved(implAnim);
m_transitions.remove(prop);
if (!animatedStyle)
animatedStyle = RenderStyle::clone(targetStyle);
-#if USE(ACCELERATED_COMPOSITING)
bool needsAnim = CSSPropertyAnimation::blendProperties(this, m_animatingProperty, animatedStyle.get(), m_fromStyle.get(), m_toStyle.get(), progress(1, 0, 0));
// FIXME: we also need to detect cases where we have to software animate for other reasons,
// such as a child using inheriting the transform. https://bugs.webkit.org/show_bug.cgi?id=23902
// that is animating are correctly detected during the animation (e.g. when a transition
// gets interrupted).
animatedStyle->setIsRunningAcceleratedAnimation();
-#endif
// Fire the start timeout if needed
fireAnimationEventsIfNeeded();
bool ImplicitAnimation::startAnimation(double timeOffset)
{
-#if USE(ACCELERATED_COMPOSITING)
if (m_object && m_object->isComposited())
return toRenderBoxModelObject(m_object)->startTransition(timeOffset, m_animatingProperty, m_fromStyle.get(), m_toStyle.get());
-#else
- UNUSED_PARAM(timeOffset);
-#endif
return false;
}
if (!m_object)
return;
-#if USE(ACCELERATED_COMPOSITING)
if (m_object->isComposited())
toRenderBoxModelObject(m_object)->transitionPaused(timeOffset, m_animatingProperty);
-#else
- UNUSED_PARAM(timeOffset);
-#endif
// Restore the original (unanimated) style
if (!paused())
setNeedsStyleRecalc(m_object->element());
void ImplicitAnimation::endAnimation()
{
-#if USE(ACCELERATED_COMPOSITING)
if (m_object && m_object->isComposited())
toRenderBoxModelObject(m_object)->transitionFinished(m_animatingProperty);
-#endif
}
void ImplicitAnimation::onAnimationEnd(double elapsedTime)
double ImplicitAnimation::timeToNextService()
{
double t = AnimationBase::timeToNextService();
-#if USE(ACCELERATED_COMPOSITING)
if (t != 0 || preActive())
return t;
bool isLooping;
getTimeToNextEvent(t, isLooping);
}
-#endif
return t;
}
double progress = 0.0;
fetchIntervalEndpointsForProperty(*it, fromStyle, toStyle, progress);
-#if USE(ACCELERATED_COMPOSITING)
bool needsAnim = CSSPropertyAnimation::blendProperties(this, *it, animatedStyle.get(), fromStyle, toStyle, progress);
if (!needsAnim)
// If we are running an accelerated animation, set a flag in the style
// to indicate it. This can be used to make sure we get an updated
// style for hit testing, etc.
animatedStyle->setIsRunningAcceleratedAnimation();
-#endif
}
}
bool KeyframeAnimation::startAnimation(double timeOffset)
{
-#if USE(ACCELERATED_COMPOSITING)
if (m_object && m_object->isComposited()) {
return toRenderBoxModelObject(m_object)->startAnimation(timeOffset, m_animation.get(), m_keyframes);
}
-#else
- UNUSED_PARAM(timeOffset);
-#endif
return false;
}
if (!m_object)
return;
-#if USE(ACCELERATED_COMPOSITING)
if (m_object->isComposited())
toRenderBoxModelObject(m_object)->animationPaused(timeOffset, m_keyframes.animationName());
-#else
- UNUSED_PARAM(timeOffset);
-#endif
+
// Restore the original (unanimated) style
if (!paused())
setNeedsStyleRecalc(m_object->element());
if (!m_object)
return;
-#if USE(ACCELERATED_COMPOSITING)
if (m_object->isComposited())
toRenderBoxModelObject(m_object)->animationFinished(m_keyframes.animationName());
-#endif
+
// Restore the original (unanimated) style
if (!paused())
setNeedsStyleRecalc(m_object->element());
double KeyframeAnimation::timeToNextService()
{
double t = AnimationBase::timeToNextService();
-#if USE(ACCELERATED_COMPOSITING)
if (t != 0 || preActive())
return t;
bool isLooping;
getTimeToNextEvent(t, isLooping);
}
-#endif
+
return t;
}
void Frame::viewportOffsetChanged(ViewportOffsetChangeType changeType)
{
-#if USE(ACCELERATED_COMPOSITING)
if (changeType == IncrementalScrollOffset) {
if (anyFrameHasTiledLayers(this)) {
if (RenderView* root = contentRenderer())
if (RenderView* root = contentRenderer())
root->compositor().updateCompositingLayers(CompositingUpdateOnScroll);
}
-#endif
}
bool Frame::containsTiledBackingLayers() const
{
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* root = contentRenderer())
return root->compositor().hasNonMainLayersWithTiledBacking();
-#endif
+
return false;
}
frameView->setInProgrammaticScroll(oldProgrammaticScroll);
-#if USE(ACCELERATED_COMPOSITING)
if (scrollingNodeID == frameView->scrollLayerID()) {
if (GraphicsLayer* scrollLayer = scrollLayerForFrameView(frameView)) {
GraphicsLayer* counterScrollingLayer = counterScrollingLayerForFrameView(frameView);
}
}
// FIXME: handle non-main scrolling nodes.
-#else
- UNUSED_PARAM(scrollingLayerPositionAction);
-#endif
}
void AsyncScrollingCoordinator::scrollableAreaScrollbarLayerDidChange(ScrollableArea* scrollableArea, ScrollbarOrientation orientation)
#include "PlatformWheelEvent.h"
#include "PluginViewBase.h"
#include "Region.h"
+#include "RenderLayerCompositor.h"
#include "RenderView.h"
#include "ScrollAnimator.h"
#include <wtf/MainThread.h>
#include <wtf/text/StringBuilder.h>
-#if USE(ACCELERATED_COMPOSITING)
-#include "RenderLayerCompositor.h"
-#endif
-
#if USE(COORDINATED_GRAPHICS)
#include "ScrollingCoordinatorCoordinatedGraphics.h"
#endif
return false;
// We currently only support composited mode.
-#if USE(ACCELERATED_COMPOSITING)
RenderView* renderView = m_page->mainFrame().contentRenderer();
if (!renderView)
return false;
return renderView->usesCompositing();
-#else
- return false;
-#endif
}
Region ScrollingCoordinator::computeNonFastScrollableRegion(const Frame* frame, const IntPoint& frameLocation) const
if (const FrameView::ScrollableAreaSet* scrollableAreas = frameView->scrollableAreas()) {
for (FrameView::ScrollableAreaSet::const_iterator it = scrollableAreas->begin(), end = scrollableAreas->end(); it != end; ++it) {
ScrollableArea* scrollableArea = *it;
-#if USE(ACCELERATED_COMPOSITING)
// Composited scrollable areas can be scrolled off the main thread.
if (scrollableArea->usesCompositedScrolling())
continue;
-#endif
IntRect box = scrollableArea->scrollableAreaBoundingBox();
box.moveBy(offset);
nonFastScrollableRegion.unite(box);
updateSynchronousScrollingReasons();
}
-#if USE(ACCELERATED_COMPOSITING)
GraphicsLayer* ScrollingCoordinator::scrollLayerForScrollableArea(ScrollableArea* scrollableArea)
{
return scrollableArea->layerForScrolling();
{
return scrollableArea->layerForVerticalScrollbar();
}
-#endif
GraphicsLayer* ScrollingCoordinator::scrollLayerForFrameView(FrameView* frameView)
{
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* renderView = frameView->frame().contentRenderer())
return renderView->compositor().scrollLayer();
return 0;
-#else
- UNUSED_PARAM(frameView);
- return 0;
-#endif
}
GraphicsLayer* ScrollingCoordinator::headerLayerForFrameView(FrameView* frameView)
{
-#if USE(ACCELERATED_COMPOSITING) && ENABLE(RUBBER_BANDING)
+#if ENABLE(RUBBER_BANDING)
if (RenderView* renderView = frameView->frame().contentRenderer())
renderView->compositor().headerLayer();
return 0;
GraphicsLayer* ScrollingCoordinator::footerLayerForFrameView(FrameView* frameView)
{
-#if USE(ACCELERATED_COMPOSITING) && ENABLE(RUBBER_BANDING)
+#if ENABLE(RUBBER_BANDING)
if (RenderView* renderView = frameView->frame().contentRenderer())
return renderView->compositor().footerLayer();
return 0;
GraphicsLayer* ScrollingCoordinator::counterScrollingLayerForFrameView(FrameView* frameView)
{
-#if USE(ACCELERATED_COMPOSITING)
if (RenderView* renderView = frameView->frame().contentRenderer())
return renderView->compositor().fixedRootBackgroundLayer();
return 0;
-#else
- UNUSED_PARAM(frameView);
- return 0;
-#endif
}
void ScrollingCoordinator::frameViewRootLayerDidChange(FrameView* frameView)
if (!viewportConstrainedObjects)
return false;
-#if USE(ACCELERATED_COMPOSITING)
for (FrameView::ViewportConstrainedObjectSet::const_iterator it = viewportConstrainedObjects->begin(), end = viewportConstrainedObjects->end(); it != end; ++it) {
RenderObject* viewportConstrainedObject = *it;
if (!viewportConstrainedObject->isBoxModelObject() || !viewportConstrainedObject->hasLayer())
return true;
}
return false;
-#else
- return viewportConstrainedObjects->size();
-#endif
}
SynchronousScrollingReasons ScrollingCoordinator::synchronousScrollingReasons() const
protected:
explicit ScrollingCoordinator(Page*);
-#if USE(ACCELERATED_COMPOSITING)
static GraphicsLayer* scrollLayerForScrollableArea(ScrollableArea*);
static GraphicsLayer* horizontalScrollbarLayerForScrollableArea(ScrollableArea*);
static GraphicsLayer* verticalScrollbarLayerForScrollableArea(ScrollableArea*);
-#endif
unsigned computeCurrentWheelEventHandlerCount();
GraphicsLayer* scrollLayerForFrameView(FrameView*);
(*current)->clipRectChanged();
}
-#if USE(ACCELERATED_COMPOSITING)
static void positionScrollbarLayer(GraphicsLayer* graphicsLayer, Scrollbar* scrollbar)
{
if (!graphicsLayer || !scrollbar)
graphicsLayer->setNeedsDisplay();
graphicsLayer->setSize(cornerRect.size());
}
-#endif
-
void ScrollView::positionScrollbarLayers()
{
-#if USE(ACCELERATED_COMPOSITING)
positionScrollbarLayer(layerForHorizontalScrollbar(), horizontalScrollbar());
positionScrollbarLayer(layerForVerticalScrollbar(), verticalScrollbar());
positionScrollCornerLayer(layerForScrollCorner(), scrollCornerRect());
-#endif
}
void ScrollView::repaintContentRectangle(const IntRect& rect, bool now)
void ScrollView::paintScrollbars(GraphicsContext* context, const IntRect& rect)
{
- if (m_horizontalScrollbar
-#if USE(ACCELERATED_COMPOSITING)
- && !layerForHorizontalScrollbar()
-#endif
- )
+ if (m_horizontalScrollbar && !layerForHorizontalScrollbar())
paintScrollbar(context, m_horizontalScrollbar.get(), rect);
- if (m_verticalScrollbar
-#if USE(ACCELERATED_COMPOSITING)
- && !layerForVerticalScrollbar()
-#endif
- )
+ if (m_verticalScrollbar && !layerForVerticalScrollbar())
paintScrollbar(context, m_verticalScrollbar.get(), rect);
-#if USE(ACCELERATED_COMPOSITING)
if (layerForScrollCorner())
return;
-#endif
+
paintScrollCorner(context, scrollCornerRect());
}
paintContents(context, documentDirtyRect);
}
-#if USE(ACCELERATED_COMPOSITING) && ENABLE(RUBBER_BANDING)
+#if ENABLE(RUBBER_BANDING)
if (!layerForOverhangAreas())
calculateAndPaintOverhangAreas(context, rect);
#else
void ScrollableArea::invalidateScrollbar(Scrollbar* scrollbar, const IntRect& rect)
{
-#if USE(ACCELERATED_COMPOSITING)
if (scrollbar == horizontalScrollbar()) {
if (GraphicsLayer* graphicsLayer = layerForHorizontalScrollbar()) {
graphicsLayer->setNeedsDisplay();
return;
}
}
-#endif
+
invalidateScrollbarRect(scrollbar, rect);
}
void ScrollableArea::invalidateScrollCorner(const IntRect& rect)
{
-#if USE(ACCELERATED_COMPOSITING)
if (GraphicsLayer* graphicsLayer = layerForScrollCorner()) {
graphicsLayer->setNeedsDisplay();
return;
}
-#endif
+
invalidateScrollCornerRect(rect);
}
-#if USE(ACCELERATED_COMPOSITING)
void ScrollableArea::verticalScrollbarLayerDidChange()
{
scrollAnimator()->verticalScrollbarLayerDidChange();
{
scrollAnimator()->horizontalScrollbarLayerDidChange();
}
-#endif
bool ScrollableArea::hasLayerForHorizontalScrollbar() const
{
-#if USE(ACCELERATED_COMPOSITING)
return layerForHorizontalScrollbar();
-#else
- return false;
-#endif
}
bool ScrollableArea::hasLayerForVerticalScrollbar() const
{
-#if USE(ACCELERATED_COMPOSITING)
return layerForVerticalScrollbar();
-#else
- return false;
-#endif
}
bool ScrollableArea::hasLayerForScrollCorner() const
{
-#if USE(ACCELERATED_COMPOSITING)
return layerForScrollCorner();
-#else
- return false;
-#endif
}
void ScrollableArea::serviceScrollAnimations()
class PlatformTouchEvent;
class PlatformWheelEvent;
class ScrollAnimator;
-#if USE(ACCELERATED_COMPOSITING)
class GraphicsLayer;
class TiledBacking;
-#endif
class ScrollableArea {
public:
bool isPinnedVerticallyInDirection(int verticalScrollDelta) const;
#endif
-#if USE(ACCELERATED_COMPOSITING)
virtual TiledBacking* tiledBacking() const { return 0; }
virtual bool usesCompositedScrolling() const { return false; }
void verticalScrollbarLayerDidChange();
void horizontalScrollbarLayerDidChange();
-#endif
protected:
ScrollableArea();
virtual void invalidateScrollbarRect(Scrollbar*, const IntRect&) = 0;
virtual void invalidateScrollCornerRect(const IntRect&) = 0;
-#if USE(ACCELERATED_COMPOSITING)
friend class ScrollingCoordinator;
virtual GraphicsLayer* layerForScrolling() const { return 0; }
virtual GraphicsLayer* layerForScrollCorner() const { return 0; }
#if ENABLE(RUBBER_BANDING)
virtual GraphicsLayer* layerForOverhangAreas() const { return 0; }
#endif
-#endif
+
bool hasLayerForHorizontalScrollbar() const;
bool hasLayerForVerticalScrollbar() const;
bool hasLayerForScrollCorner() const;
class ScrollbarThemeClient;
class ScrollView;
-#if USE(ACCELERATED_COMPOSITING) && ENABLE(RUBBER_BANDING)
+#if ENABLE(RUBBER_BANDING)
class GraphicsLayer;
#endif
virtual void paintTickmarks(GraphicsContext*, ScrollbarThemeClient*, const IntRect&) { }
virtual void paintOverhangAreas(ScrollView*, GraphicsContext*, const IntRect&, const IntRect&, const IntRect&) { }
-#if USE(ACCELERATED_COMPOSITING) && ENABLE(RUBBER_BANDING)
+#if ENABLE(RUBBER_BANDING)
virtual void setUpOverhangAreasLayerContents(GraphicsLayer*, const Color&) { }
virtual void setUpContentShadowLayer(GraphicsLayer*) { }
#endif
}
Ecore_X_Window window;
-#if USE(ACCELERATED_COMPOSITING)
window = ecore_evas_gl_x11_window_get(ecoreEvas);
// Fallback to software mode if necessary.
if (!window)
-#endif
- window = ecore_evas_software_x11_window_get(ecoreEvas);
+ window = ecore_evas_software_x11_window_get(ecoreEvas);
Ecore_X_Cursor cursor = ecore_x_cursor_shape_get(shape);
ecore_x_window_cursor_set(window, cursor);
#else
PlatformGraphicsContext3D platformGraphicsContext3D();
Platform3DObject platformTexture() const;
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* platformLayer() const;
-#endif
#endif
bool makeContextCurrent();
#include "OpenGLShims.h"
#endif
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER) && USE(TEXTURE_MAPPER_GL)
+#if USE(TEXTURE_MAPPER) && USE(TEXTURE_MAPPER_GL)
#include <texmap/TextureMapperGL.h>
#endif
GraphicsContext3DPrivate::~GraphicsContext3DPrivate()
{
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
if (client())
client()->platformLayerWillBeDestroyed();
#endif
return m_glContext ? m_glContext->platformContext() : GLContext::getCurrent()->platformContext();
}
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
void GraphicsContext3DPrivate::paintToTextureMapper(TextureMapper* textureMapper, const FloatRect& targetRect, const TransformationMatrix& matrix, float opacity)
{
if (!m_glContext)
TextureMapperGL::Flags flags = TextureMapperGL::ShouldFlipTexture | (m_context->m_attrs.alpha ? TextureMapperGL::ShouldBlend : 0);
IntSize textureSize(m_context->m_currentWidth, m_context->m_currentHeight);
texmapGL->drawTexture(m_context->m_texture, flags, textureSize, targetRect, matrix, opacity);
-#endif // USE(ACCELERATED_COMPOSITING_GL)
+#endif // USE(TEXTURE_MAPPER_GL)
}
-#endif // USE(ACCELERATED_COMPOSITING)
+#endif // USE(TEXTURE_MAPPER)
} // namespace WebCore
#include "GraphicsContext3D.h"
#include <wtf/PassOwnPtr.h>
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#include "TextureMapperPlatformLayer.h"
#endif
namespace WebCore {
class GraphicsContext3DPrivate
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
: public TextureMapperPlatformLayer
#endif
{
GraphicsContext3D::RenderStyle renderStyle() { return m_renderStyle; }
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
virtual void paintToTextureMapper(TextureMapper*, const FloatRect& target, const TransformationMatrix&, float opacity);
#endif
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "GraphicsLayer.h"
#include "FloatPoint.h"
fprintf(stderr, "%s\n", output.utf8().data());
}
#endif
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef GraphicsLayer_h
#define GraphicsLayer_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "Animation.h"
#include "Color.h"
#include "FloatPoint.h"
void showGraphicsLayerTree(const WebCore::GraphicsLayer* layer);
#endif
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // GraphicsLayer_h
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
#include "GraphicsLayerAnimation.h"
#include "LayoutSize.h"
return active;
}
}
-#endif
-
#ifndef GraphicsLayerAnimation_h
#define GraphicsLayerAnimation_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "GraphicsLayer.h"
#include "TransformationMatrix.h"
#include <wtf/HashMap.h>
};
}
-#endif
#endif // GraphicsLayerAnimation_h
#ifndef GraphicsLayerClient_h
#define GraphicsLayerClient_h
-#if USE(ACCELERATED_COMPOSITING)
-
namespace WebCore {
class FloatPoint;
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // GraphicsLayerClient_h
#ifndef GraphicsLayerFactory_h
#define GraphicsLayerFactory_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include <wtf/Forward.h>
namespace WebCore {
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // GraphicsLayerFactory_h
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "GraphicsLayerUpdater.h"
#include "GraphicsLayer.h"
}
} // namespace WebCore
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef GraphicsLayerUpdater_h
#define GraphicsLayerUpdater_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "DisplayRefreshMonitor.h"
#include "PlatformScreen.h"
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // GraphicsLayerUpdater_h
genericConvertToLuminanceMask();
}
-#if USE(ACCELERATED_COMPOSITING) && !USE(CAIRO)
+#if !USE(CAIRO)
PlatformLayer* ImageBuffer::platformLayer() const
{
return 0;
#include "ColorSpace.h"
#include "FloatRect.h"
#include "GraphicsContext.h"
-#if USE(ACCELERATED_COMPOSITING)
-#include "PlatformLayer.h"
-#endif
#include "GraphicsTypes.h"
#include "GraphicsTypes3D.h"
#include "IntSize.h"
#include "ImageBufferData.h"
+#include "PlatformLayer.h"
#include <runtime/Uint8ClampedArray.h>
#include <wtf/Forward.h>
#include <wtf/OwnPtr.h>
#else
AffineTransform baseTransform() const { return AffineTransform(1, 0, 0, -1, 0, m_data.m_backingStoreSize.height()); }
#endif
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* platformLayer() const;
-#endif
// FIXME: current implementations of this method have the restriction that they only work
// with textures that are RGB or RGBA format, and UNSIGNED_BYTE type.
virtual void pause() { }
virtual PlatformMedia platformMedia() const { return NoPlatformMedia; }
-#if USE(ACCELERATED_COMPOSITING)
virtual PlatformLayer* platformLayer() const { return 0; }
-#endif
virtual IntSize naturalSize() const { return IntSize(0, 0); }
return m_private->platformMedia();
}
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* MediaPlayer::platformLayer() const
{
return m_private->platformLayer();
}
-#endif
MediaPlayer::NetworkState MediaPlayer::networkState()
{
}
#endif
-#if USE(ACCELERATED_COMPOSITING)
void MediaPlayer::acceleratedRenderingStateChanged()
{
m_private->acceleratedRenderingStateChanged();
{
return m_private->supportsAcceleratedRendering();
}
-#endif // USE(ACCELERATED_COMPOSITING)
bool MediaPlayer::shouldMaintainAspectRatio() const
{
#include "URL.h"
#include "LayoutRect.h"
#include "NativeImagePtr.h"
+#include "PlatformLayer.h"
#include "Timer.h"
#include "VideoTrackPrivate.h"
#include <runtime/Uint8Array.h>
#include <wtf/PassOwnPtr.h>
#include <wtf/text/StringHash.h>
-#if USE(ACCELERATED_COMPOSITING)
-#include "PlatformLayer.h"
-#endif
-
#if USE(PLATFORM_TEXT_TRACK_MENU)
#include "PlatformTextTrackMenu.h"
#endif
// A characteristic of the media file, eg. video, audio, closed captions, etc, has changed.
virtual void mediaPlayerCharacteristicChanged(MediaPlayer*) { }
-#if USE(ACCELERATED_COMPOSITING)
// whether the rendering system can accelerate the display of this MediaPlayer.
virtual bool mediaPlayerRenderingCanBeAccelerated(MediaPlayer*) { return false; }
// called when the media player's rendering mode changed, which indicates a change in the
// availability of the platformLayer().
virtual void mediaPlayerRenderingModeChanged(MediaPlayer*) { }
-#endif
#if PLATFORM(WIN) && USE(AVFOUNDATION)
virtual GraphicsDeviceAdapter* mediaPlayerGraphicsDeviceAdapter(const MediaPlayer*) const { return 0; }
bool supportsScanning() const;
bool requiresImmediateCompositing() const;
PlatformMedia platformMedia() const;
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* platformLayer() const;
-#endif
IntSize naturalSize();
bool hasVideo() const;
bool canEnterFullscreen() const;
#endif
-#if USE(ACCELERATED_COMPOSITING)
// whether accelerated rendering is supported by the media engine for the current media.
bool supportsAcceleratedRendering() const;
// called when the rendering system flips the into or out of accelerated rendering mode.
void acceleratedRenderingStateChanged();
-#endif
bool shouldMaintainAspectRatio() const;
void setShouldMaintainAspectRatio(bool);
virtual void prepareToPlay() { }
virtual PlatformMedia platformMedia() const { return NoPlatformMedia; }
-#if USE(ACCELERATED_COMPOSITING)
virtual PlatformLayer* platformLayer() const { return 0; }
-#endif
virtual void play() = 0;
virtual void pause() = 0;
virtual bool canEnterFullscreen() const { return false; }
#endif
-#if USE(ACCELERATED_COMPOSITING)
// whether accelerated rendering is supported by the media engine for the current media.
virtual bool supportsAcceleratedRendering() const { return false; }
// called when the rendering system flips the into or out of accelerated rendering mode.
virtual void acceleratedRenderingStateChanged() { }
-#endif
virtual bool shouldMaintainAspectRatio() const { return true; }
virtual void setShouldMaintainAspectRatio(bool) { }
#ifndef PlatformLayer_h
#define PlatformLayer_h
-#if USE(ACCELERATED_COMPOSITING)
-
#if PLATFORM(MAC)
OBJC_CLASS CALayer;
typedef CALayer PlatformLayer;
typedef void* PlatformLayer;
#endif
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // PlatformLayer_h
public:
virtual ~NullTextTrackRepresentation() { }
virtual void update() { }
-#if USE(ACCELERATED_COMPOSITING)
virtual PlatformLayer* platformLayer() { return 0; }
-#endif
virtual void setContentScale(float) { }
virtual IntRect bounds() const { return IntRect(); }
};
virtual ~TextTrackRepresentation() { }
virtual void update() = 0;
-#if USE(ACCELERATED_COMPOSITING)
virtual PlatformLayer* platformLayer() = 0;
-#endif
virtual void setContentScale(float) = 0;
virtual IntRect bounds() const = 0;
};
MediaPlayerPrivateAVFoundation::MediaRenderingMode MediaPlayerPrivateAVFoundation::currentRenderingMode() const
{
-#if USE(ACCELERATED_COMPOSITING)
if (platformLayer())
return MediaRenderingToLayer;
-#endif
if (hasContextRenderer())
return MediaRenderingToContext;
if (!m_player->visible() || !m_player->frameView() || assetStatus() == MediaPlayerAVAssetStatusUnknown)
return MediaRenderingNone;
-#if USE(ACCELERATED_COMPOSITING)
if (supportsAcceleratedRendering() && m_player->mediaPlayerClient()->mediaPlayerRenderingCanBeAccelerated(m_player))
return MediaRenderingToLayer;
-#endif
return MediaRenderingToContext;
}
case MediaRenderingToContext:
createContextVideoRenderer();
break;
-
-#if USE(ACCELERATED_COMPOSITING)
+
case MediaRenderingToLayer:
createVideoLayer();
break;
-#endif
}
-#if USE(ACCELERATED_COMPOSITING)
// If using a movie layer, inform the client so the compositing tree is updated.
if (currentMode == MediaRenderingToLayer || preferredMode == MediaRenderingToLayer) {
LOG(Media, "MediaPlayerPrivateAVFoundation::setUpVideoRendering(%p) - calling mediaPlayerRenderingModeChanged()", this);
m_player->mediaPlayerClient()->mediaPlayerRenderingModeChanged(m_player);
}
-#endif
}
void MediaPlayerPrivateAVFoundation::tearDownVideoRendering()
destroyContextVideoRenderer();
-#if USE(ACCELERATED_COMPOSITING)
if (platformLayer())
destroyVideoLayer();
-#endif
}
bool MediaPlayerPrivateAVFoundation::hasSetUpVideoRendering() const
virtual void paint(GraphicsContext*, const IntRect&) = 0;
virtual void paintCurrentFrameInContext(GraphicsContext*, const IntRect&) = 0;
virtual void setPreload(MediaPlayer::Preload) override;
-#if USE(ACCELERATED_COMPOSITING)
virtual PlatformLayer* platformLayer() const { return 0; }
virtual bool supportsAcceleratedRendering() const = 0;
virtual void acceleratedRenderingStateChanged() override;
-#endif
virtual bool shouldMaintainAspectRatio() const override { return m_shouldMaintainAspectRatio; }
virtual void setShouldMaintainAspectRatio(bool) override;
virtual void prepareToPlay() override;
virtual PlatformMedia platformMedia() const override;
-#if USE(ACCELERATED_COMPOSITING)
virtual PlatformLayer* platformLayer() const override;
-#endif
virtual void play() override;
void playInternal();
virtual bool hasAvailableVideoFrame() const override;
-#if USE(ACCELERATED_COMPOSITING)
virtual bool supportsAcceleratedRendering() const override;
// called when the rendering system flips the into or out of accelerated rendering mode.
virtual void acceleratedRenderingStateChanged() override;
-#endif
virtual MediaPlayer::MovieLoadType movieLoadType() const override;
return pm;
}
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* MediaPlayerPrivateMediaSourceAVFObjC::platformLayer() const
{
return m_sampleBufferDisplayLayer.get();
}
-#endif
void MediaPlayerPrivateMediaSourceAVFObjC::play()
{
return m_hasAvailableVideoFrame;
}
-#if USE(ACCELERATED_COMPOSITING)
bool MediaPlayerPrivateMediaSourceAVFObjC::supportsAcceleratedRendering() const
{
return true;
else
destroyLayer();
}
-#endif
MediaPlayer::MovieLoadType MediaPlayerPrivateMediaSourceAVFObjC::movieLoadType() const
{
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "GraphicsLayerCA.h"
#include "Animation.h"
}
} // namespace WebCore
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef GraphicsLayerCA_h
#define GraphicsLayerCA_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "GraphicsLayer.h"
#include "Image.h"
#include "PlatformCAAnimation.h"
} // namespace WebCore
-
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // GraphicsLayerCA_h
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "LayerFlushScheduler.h"
namespace WebCore {
}
} // namespace WebCore
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef LayerFlushScheduler_h
#define LayerFlushScheduler_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "LayerFlushSchedulerClient.h"
#include <wtf/Noncopyable.h>
#include <wtf/RetainPtr.h>
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // LayerFlushScheduler_h
#ifndef LayerFlushSchedulerClient_h
#define LayerFlushSchedulerClient_h
-#if USE(ACCELERATED_COMPOSITING)
-
namespace WebCore {
class LayerFlushSchedulerClient {
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // LayerFlushSchedulerClient_h
#ifndef PlatformCAAnimation_h
#define PlatformCAAnimation_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "Color.h"
#include "FilterOperation.h"
#include "FloatPoint3D.h"
}
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // PlatformCAAnimation_h
#ifndef PlatformCAFilters_h
#define PlatformCAFilters_h
-#if USE(ACCELERATED_COMPOSITING)
#if ENABLE(CSS_FILTERS)
#include "FilterOperations.h"
}
#endif // ENABLE(CSS_FILTERS)
-#endif // USE(ACCELERATED_COMPOSITING)
#endif // PlatformCAFilters_h
#ifndef PlatformCALayer_h
#define PlatformCALayer_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "GraphicsContext.h"
#include "GraphicsLayer.h"
#include "PlatformCAAnimation.h"
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // PlatformCALayer_h
#ifndef PlatformCALayerClient_h
#define PlatformCALayerClient_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "GraphicsContext.h"
#include "GraphicsLayer.h"
#include "PlatformCAAnimation.h"
}
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // PlatformCALayerClient_h
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "LayerFlushScheduler.h"
#include <wtf/AutodrainedPool.h>
}
} // namespace WebCore
-
-#endif // USE(ACCELERATED_COMPOSITING)
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#import "PlatformCAAnimation.h"
#import "FloatConversion.h"
CAKeyframeAnimation* other = static_cast<CAKeyframeAnimation*>(value->m_animation.get());
[static_cast<CAKeyframeAnimation*>(m_animation.get()) setTimingFunctions:[other timingFunctions]];
}
-
-#endif // USE(ACCELERATED_COMPOSITING)
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
#if ENABLE(CSS_FILTERS)
#import "PlatformCAFilters.h"
}
#endif // ENABLE(CSS_FILTERS)
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef PlatformCALayerMac_h
#define PlatformCALayerMac_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "PlatformCALayer.h"
OBJC_CLASS NSObject;
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // PlatformCALayerMac_h
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#import "PlatformCALayerMac.h"
#import "AnimationUtilities.h"
{
wkCALayerEnumerateRectsBeingDrawnWithBlock(m_layer.get(), context, block);
}
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef AbstractCACFLayerTreeHost_h
#define AbstractCACFLayerTreeHost_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include <wtf/Forward.h>
namespace WebCore {
}
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // AbstractCACFLayerTreeHost_h
#include "config.h"
#include "CACFLayerTreeHost.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "CACFLayerTreeHostClient.h"
#include "DefWndProcWindowClass.h"
#include "LayerChangesFlusher.h"
}
}
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef CACFLayerTreeHost_h
#define CACFLayerTreeHost_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "AbstractCACFLayerTreeHost.h"
#include "COMPtr.h"
#include "Timer.h"
}
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // CACFLayerTreeHost_h
#ifndef CACFLayerTreeHostClient_h
#define CACFLayerTreeHostClient_h
-#if USE(ACCELERATED_COMPOSITING)
-
namespace WebCore {
class CACFLayerTreeHostClient {
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // CACFLayerTreeHostClient_h
#include "config.h"
#include "LayerChangesFlusher.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "AbstractCACFLayerTreeHost.h"
#include "StructuredExceptionHandlerSuppressor.h"
#include <wtf/StdLibExtras.h>
}
} // namespace WebCore
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef LayerChangesFlusher_h
#define LayerChangesFlusher_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include <windows.h>
#include <wtf/HashSet.h>
#include <wtf/Noncopyable.h>
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // LayerChangesFlusher_h
#include "config.h"
#include "LegacyCACFLayerTreeHost.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "PlatformCALayer.h"
#include <QuartzCore/CABase.h>
#include <WebKitSystemInterface/WebKitSystemInterface.h>
}
} // namespace WebCore
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef LegacyCACFLayerTreeHost_h
#define LegacyCACFLayerTreeHost_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "CACFLayerTreeHost.h"
namespace WebCore {
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // LegacyCACFLayerTreeHost_h
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "PlatformCAAnimation.h"
#include "FloatConversion.h"
{
CACFAnimationSetTimingFunctions(m_animation.get(), CACFAnimationGetTimingFunctions(value->platformAnimation()));
}
-
-#endif // USE(ACCELERATED_COMPOSITING)
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
#if ENABLE(CSS_FILTERS)
#include "PlatformCAFilters.h"
}
#endif // ENABLE(CSS_FILTERS)
-#endif // USE(ACCELERATED_COMPOSITING)
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "PlatformCALayerWin.h"
#include "AbstractCACFLayerTreeHost.h"
{
return PlatformCALayerWin::create(layerType, client);
}
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef PlatformCALayerWin_h
#define PlatformCALayerWin_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "PlatformCALayer.h"
namespace WebCore {
}
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // PlatformCALayerWin_h
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "PlatformCALayerWinInternal.h"
#include "Font.h"
CGContextRestoreGState(context);
}
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef PlatformCALayerWinInternal_h
#define PlatformCALayerWinInternal_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include <CoreGraphics/CGGeometry.h>
#include <wtf/RetainPtr.h>
#include <wtf/Vector.h>
}
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // PlatformCALayerWinInternal_h
#include "config.h"
#include "WKCACFViewLayerTreeHost.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "PlatformCALayer.h"
#include "SoftLinking.h"
#include <wtf/CurrentTime.h>
#endif
} // namespace WebCore
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef WKCACFViewLayerTreeHost_h
#define WKCACFViewLayerTreeHost_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "CACFLayerTreeHost.h"
typedef struct _WKCACFView* WKCACFViewRef;
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // WKCACFViewLayerTreeHost_h
namespace WebCore {
-#if USE(ACCELERATED_COMPOSITING)
-
unsigned DrawingBuffer::frontColorBuffer() const
{
return colorBuffer();
void DrawingBuffer::paintCompositedResultsToCanvas(ImageBuffer*)
{
}
-#endif
}
#endif
}
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* GraphicsContext3D::platformLayer() const
{
return m_private.get();
}
-#endif
} // namespace WebCore
}
#endif
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* ImageBuffer::platformLayer() const
{
#if ENABLE(ACCELERATED_2D_CANVAS)
#endif
return 0;
}
-#endif
} // namespace WebCore
#include "config.h"
#include "GraphicsContext3D.h"
-#if USE(3D_GRAPHICS) || USE(ACCELERATED_COMPOSITING)
-
#include "GLDefs.h"
#include "GraphicsContext3DPrivate.h"
#include "Image.h"
return m_texture;
}
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* GraphicsContext3D::platformLayer() const
{
#if USE(TEXTURE_MAPPER_GL)
return 0;
#endif
}
-#endif
bool GraphicsContext3D::makeContextCurrent()
{
}
} // namespace WebCore
-
-#endif // USE(3D_GRAPHICS)
#include "config.h"
#include "GraphicsContext3DPrivate.h"
-#if USE(3D_GRAPHICS) || USE(ACCELERATED_COMPOSITING)
-
#include "HostWindow.h"
#include "NotImplemented.h"
#endif
} // namespace WebCore
-
-#endif // USE(3D_GRAPHICS) || USE(ACCELERATED_COMPOSITING)
#ifndef GraphicsContext3DPrivate_h
#define GraphicsContext3DPrivate_h
-#if USE(3D_GRAPHICS) || USE(ACCELERATED_COMPOSITING)
-
#include "GraphicsContext3D.h"
#if USE(TEXTURE_MAPPER_GL)
} // namespace WebCore
#endif
-
-#endif
void markContentsChanged() { m_contentsChanged = true; }
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* platformLayer();
unsigned frontColorBuffer() const;
void paintCompositedResultsToCanvas(ImageBuffer*);
-#endif
GraphicsContext3D* graphicsContext3D() const { return m_context.get(); }
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING) || ENABLE(ACCELERATED_2D_CANVAS)
-
#include "LoopBlinnMathUtils.h"
#include "FloatPoint.h"
} // namespace LoopBlinnMathUtils
} // namespace WebCore
-
-#endif
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING) || ENABLE(ACCELERATED_2D_CANVAS)
-
#include "TilingData.h"
#include "FloatRect.h"
}
}
-
-#endif
clear();
}
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* DrawingBuffer::platformLayer()
{
return m_platformLayer.get();
{
return colorBuffer();
}
-#endif
}
#include <gst/audio/streamvolume.h>
-#if GST_CHECK_VERSION(1, 1, 0) && USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER_GL)
+#if GST_CHECK_VERSION(1, 1, 0) && USE(TEXTURE_MAPPER_GL)
#include "TextureMapperGL.h"
#endif
}
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
+#if USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
PassRefPtr<BitmapTexture> MediaPlayerPrivateGStreamerBase::updateTexture(TextureMapper* textureMapper)
{
GMutexLocker lock(m_bufferMutex);
gst_buffer_replace(&m_buffer, buffer);
}
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
+#if USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
if (supportsAcceleratedRendering() && m_player->mediaPlayerClient()->mediaPlayerRenderingCanBeAccelerated(m_player) && client()) {
client()->setPlatformLayerNeedsDisplay();
return;
void MediaPlayerPrivateGStreamerBase::paint(GraphicsContext* context, const IntRect& rect)
{
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
+#if USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
if (client())
return;
#endif
rect, gstImage->rect(), CompositeCopy, ImageOrientationDescription(), false);
}
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
+#if USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
void MediaPlayerPrivateGStreamerBase::paintToTextureMapper(TextureMapper* textureMapper, const FloatRect& targetRect, const TransformationMatrix& matrix, float opacity)
{
if (textureMapper->accelerationMode() != TextureMapper::OpenGLMode)
#include <wtf/Forward.h>
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
+#if USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
#include "TextureMapperPlatformLayer.h"
#endif
class IntRect;
class MediaPlayerPrivateGStreamerBase : public MediaPlayerPrivateInterface
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
+#if USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
, public TextureMapperPlatformLayer
#endif
{
unsigned audioDecodedByteCount() const;
unsigned videoDecodedByteCount() const;
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
+#if USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
virtual PlatformLayer* platformLayer() const { return const_cast<MediaPlayerPrivateGStreamerBase*>(this); }
virtual bool supportsAcceleratedRendering() const { return true; }
virtual void paintToTextureMapper(TextureMapper*, const FloatRect&, const TransformationMatrix&, float);
unsigned long m_volumeSignalHandler;
unsigned long m_muteSignalHandler;
mutable IntSize m_videoSize;
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
+#if USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
PassRefPtr<BitmapTexture> updateTexture(TextureMapper*);
#endif
};
virtual void setHasPlaybackTargetAvailabilityListeners(bool) override;
#endif
-#if USE(ACCELERATED_COMPOSITING)
virtual bool supportsAcceleratedRendering() const override;
-#endif
virtual void setMediaPlayerProxy(WebMediaPlayerProxy*) override;
void processPendingRequests();
}
#endif
-#if USE(ACCELERATED_COMPOSITING)
bool MediaPlayerPrivateIOS::supportsAcceleratedRendering() const
{
return true;
}
-#endif
void MediaPlayerPrivateIOS::enterFullscreen()
{
void sizeChanged();
void timeChanged();
void didEnd();
-#if USE(ACCELERATED_COMPOSITING)
void layerHostChanged(PlatformLayer* rootLayer);
-#endif
private:
MediaPlayerPrivateQTKit(MediaPlayer*);
static bool isAvailable();
PlatformMedia platformMedia() const;
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* platformLayer() const;
-#endif
IntSize naturalSize() const;
bool hasVideo() const;
void paintCurrentFrameInContext(GraphicsContext*, const IntRect&);
virtual void prepareForRendering();
-
-#if USE(ACCELERATED_COMPOSITING)
bool supportsAcceleratedRendering() const;
void acceleratedRenderingStateChanged();
-#endif
bool hasSingleSecurityOrigin() const;
MediaPlayer::MovieLoadType movieLoadType() const;
#import "URL.h"
#import "Logging.h"
#import "MIMETypeRegistry.h"
+#import "PlatformLayer.h"
#import "SecurityOrigin.h"
#import "SoftLinking.h"
#import "TimeRanges.h"
#import <QTKit/QTKit.h>
#import <objc/runtime.h>
-#if USE(ACCELERATED_COMPOSITING)
-#include "PlatformLayer.h"
-#endif
-
#if DRAW_FRAME_RATE
#import "Font.h"
#import "Document.h"
void MediaPlayerPrivateQTKit::createQTMovieLayer()
{
LOG(Media, "MediaPlayerPrivateQTKit::createQTMovieLayer(%p)", this);
-#if USE(ACCELERATED_COMPOSITING)
if (!m_qtMovie)
return;
#endif
// The layer will get hooked up via RenderLayerBacking::updateGraphicsLayerConfiguration().
}
-#endif
}
void MediaPlayerPrivateQTKit::destroyQTMovieLayer()
{
LOG(Media, "MediaPlayerPrivateQTKit::destroyQTMovieLayer(%p)", this);
-#if USE(ACCELERATED_COMPOSITING)
if (!m_qtVideoLayer)
return;
// disassociate our movie from our instance of QTMovieLayer
[m_qtVideoLayer.get() setMovie:nil];
m_qtVideoLayer = nil;
-#endif
}
MediaPlayerPrivateQTKit::MediaRenderingMode MediaPlayerPrivateQTKit::currentRenderingMode() const
if (!m_player->frameView() || !m_qtMovie)
return MediaRenderingNone;
-#if USE(ACCELERATED_COMPOSITING)
if (supportsAcceleratedRendering() && m_player->mediaPlayerClient()->mediaPlayerRenderingCanBeAccelerated(m_player))
return MediaRenderingMovieLayer;
-#endif
if (!QTVideoRendererClass())
return MediaRenderingMovieView;
return pm;
}
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* MediaPlayerPrivateQTKit::platformLayer() const
{
return m_qtVideoLayer.get();
}
-#endif
void MediaPlayerPrivateQTKit::play()
{
if (metaDataAvailable()) {
wkQTMovieSetShowClosedCaptions(m_qtMovie.get(), closedCaptionsVisible);
-#if USE(ACCELERATED_COMPOSITING)
if (closedCaptionsVisible && m_qtVideoLayer) {
// Captions will be rendered upside down unless we flag the movie as flipped (again). See <rdar://7408440>.
[m_qtVideoLayer.get() setGeometryFlipped:YES];
}
-#endif
}
}
m_player->timeChanged();
}
-#if USE(ACCELERATED_COMPOSITING)
void MediaPlayerPrivateQTKit::layerHostChanged(PlatformLayer* rootLayer)
{
UNUSED_PARAM(rootLayer);
}
-#endif
void MediaPlayerPrivateQTKit::setSize(const IntSize&)
{
m_player->mediaPlayerClient()->mediaPlayerSawUnsupportedTracks(m_player);
}
-#if USE(ACCELERATED_COMPOSITING)
bool MediaPlayerPrivateQTKit::supportsAcceleratedRendering() const
{
return isReadyForVideoSetup() && getQTMovieLayerClass() != Nil;
// Set up or change the rendering path if necessary.
setUpVideoRendering();
}
-#endif
bool MediaPlayerPrivateQTKit::hasSingleSecurityOrigin() const
{
- (void)layerHostChanged:(NSNotification *)notification
{
-#if USE(ACCELERATED_COMPOSITING)
CALayer* rootLayer = static_cast<CALayer*>([notification object]);
m_callback->layerHostChanged(rootLayer);
-#else
- UNUSED_PARAM(notification);
-#endif
}
- (void)setDelayCallbacks:(BOOL)shouldDelay
#ifndef WebGLLayer_h
#define WebGLLayer_h
-#if USE(ACCELERATED_COMPOSITING)
-
#import <QuartzCore/QuartzCore.h>
namespace WebCore {
@end
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // WebGLLayer_h
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING)
#if ENABLE(WEBGL)
#import "WebGLLayer.h"
@end
#endif // ENABLE(WEBGL)
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef WebLayer_h
#define WebLayer_h
-#if USE(ACCELERATED_COMPOSITING)
-
#import <QuartzCore/QuartzCore.h>
#import <WebCore/FloatRect.h>
#import <wtf/Vector.h>
void drawRepaintIndicator(CGContextRef, PlatformCALayer*, int repaintCount, CGColorRef customBackgroundColor);
}
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // WebLayer_h
*/
#include "config.h"
-
-#if USE(ACCELERATED_COMPOSITING)
-
#import "WebLayer.h"
#import "GraphicsContext.h"
@end // implementation WebLayer(ExtendedDescription)
#endif // NDEBUG
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef WebTiledLayer_h
#define WebTiledLayer_h
-#if USE(ACCELERATED_COMPOSITING)
-
#import "WebLayer.h"
@interface WebTiledLayer : CATiledLayer
@end
-#endif // USE(ACCELERATED_COMPOSITING)
-
#endif // WebTiledLayer_h
*/
#include "config.h"
-
-#if USE(ACCELERATED_COMPOSITING)
-
#import "WebTiledLayer.h"
#import "GraphicsContext.h"
}
@end // implementation WebTiledLayer
-
-#endif // USE(ACCELERATED_COMPOSITING)
#ifndef GLDefs_h
#define GLDefs_h
-#if USE(ACCELERATED_COMPOSITING)
-
#define GL_GLEXT_PROTOTYPES 1
#if USE(OPENGL_ES_2)
}
#endif
-
-#endif
#include "config.h"
#include "GLPlatformContext.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#if USE(GLX)
#include "GLXContext.h"
#elif USE(EGL)
}
} // namespace WebCore
-
-#endif
#ifndef GLPlatformContext_h
#define GLPlatformContext_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "GLDefs.h"
#include "GLPlatformSurface.h"
#include "GraphicsContext3D.h"
} // namespace WebCore
-#endif
-
#endif // GLNativeContext_H
#include "config.h"
#include "GLPlatformSurface.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#if USE(GLX)
#include "GLXSurface.h"
#endif
}
}
-
-#endif
#ifndef GLPlatformSurface_h
#define GLPlatformSurface_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "GLDefs.h"
#include "IntRect.h"
#include <wtf/Noncopyable.h>
}
#endif
-
-#endif
-
#include "config.h"
#include "GLTransportSurface.h"
-#if USE(ACCELERATED_COMPOSITING)
-
#include "FloatRect.h"
#if USE(GLX)
}
}
-
-#endif
#ifndef GLTransportSurface_h
#define GLTransportSurface_h
-#if USE(ACCELERATED_COMPOSITING)
-
#include "GLPlatformSurface.h"
#include <wtf/PassOwnPtr.h>
}
#endif
-
-#endif
#ifndef GLXConfigSelector_h
#define GLXConfigSelector_h
-#if USE(ACCELERATED_COMPOSITING) && USE(GLX)
+#if USE(GLX)
#include "X11Helper.h"
#include <opengl/GLDefs.h>
#include "config.h"
#include "GLXContext.h"
-#if USE(ACCELERATED_COMPOSITING) && USE(GLX)
+#if USE(GLX)
#include "X11Helper.h"
#ifndef GLXContext_h
#define GLXContext_h
-#if USE(ACCELERATED_COMPOSITING) && USE(GLX)
+#if USE(GLX)
#include "GLPlatformContext.h"
#include "config.h"
#include "GLXSurface.h"
-#if USE(ACCELERATED_COMPOSITING) && USE(GLX)
+#if USE(GLX)
namespace WebCore {
#ifndef GLXSurface_h
#define GLXSurface_h
-#if USE(ACCELERATED_COMPOSITING) && USE(GLX)
+#if USE(GLX)
#include "GLTransportSurface.h"
#include "GLXConfigSelector.h"
#include "Timer.h"
#include <wtf/CurrentTime.h>
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
namespace WebCore {
#ifndef TextureMapper_h
#define TextureMapper_h
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#if (PLATFORM(GTK) || PLATFORM(EFL)) && USE(OPENGL_ES_2)
#define TEXMAP_OPENGL_ES_2
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#include "TextureMapperBackingStore.h"
#include "GraphicsLayer.h"
#ifndef TextureMapperBackingStore_h
#define TextureMapperBackingStore_h
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#include "FloatRect.h"
#include "Image.h"
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#include "TextureMapperFPSCounter.h"
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
+#endif // USE(TEXTURE_MAPPER)
#ifndef TextureMapperFPSCounter_h
#define TextureMapperFPSCounter_h
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#include "FloatPoint.h"
#include "TransformationMatrix.h"
#include <wtf/Noncopyable.h>
} // namespace WebCore
-#endif // USE(ACCELERATED_COMPOSITING)
+#endif // USE(TEXTURE_MAPPER)
#endif // TextureMapperFPSCounter_h
#define GL_UNPACK_SKIP_ROWS 0x0CF3
#endif
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
namespace WebCore {
struct TextureMapperGLData {
#ifndef TextureMapperGL_h
#define TextureMapperGL_h
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#include "FilterOperation.h"
#include "FloatQuad.h"
#include "Region.h"
#include <wtf/MathExtras.h>
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
namespace WebCore {
#ifndef TextureMapperLayer_h
#define TextureMapperLayer_h
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#include "FilterOperations.h"
#include "FloatRect.h"
#include "config.h"
#include "TextureMapperShaderProgram.h"
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#include "LengthFunctions.h"
#include "Logging.h"
#include "TextureMapperGL.h"
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING) && USE(GRAPHICS_SURFACE)
+#if USE(GRAPHICS_SURFACE)
#include "TextureMapperSurfaceBackingStore.h"
#include "GraphicsSurface.h"
#ifndef TextureMapperSurfaceBackingStore_h
#define TextureMapperSurfaceBackingStore_h
-#if USE(ACCELERATED_COMPOSITING) && USE(GRAPHICS_SURFACE)
+#if USE(GRAPHICS_SURFACE)
#include "GraphicsSurface.h"
#include "TextureMapperBackingStore.h"
*/
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#include "TextureMapperTile.h"
#include "Image.h"
#ifndef TextureMapperTile_h
#define TextureMapperTile_h
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#include "FloatRect.h"
#include "Image.h"
#include "config.h"
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#include "TextureMapperTiledBackingStore.h"
#include "ImageBuffer.h"
#ifndef TextureMapperTiledBackingStore_h
#define TextureMapperTiledBackingStore_h
-#if USE(ACCELERATED_COMPOSITING) && USE(TEXTURE_MAPPER)
+#if USE(TEXTURE_MAPPER)
#include "FloatRect.h"
#include "Image.h"
#endif
}
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* GraphicsContext3D::platformLayer() const
{
return m_webGLLayer->platformLayer();
}
-#endif
} // namespace WebCore
#include <CoreGraphics/CGColor.h>
#endif
-#if USE(ACCELERATED_COMPOSITING) && USE(CA)
+#if USE(CA)
#include "CACFLayerTreeHost.h"
#include "PlatformCALayer.h"
#endif
parentHwnd, 0, instanceHandle(), this);
ASSERT(IsWindow(m_hwnd));
-#if USE(ACCELERATED_COMPOSITING) && USE(CA)
+#if USE(CA)
if (m_layerTreeHost)
m_layerTreeHost->setWindow(m_hwnd);
#endif
::SetFocus(m_hwnd);
}
-#if USE(ACCELERATED_COMPOSITING) && USE(CA)
+#if USE(CA)
void MediaPlayerPrivateFullscreenWindow::setRootChildLayer(PassRefPtr<PlatformCALayer> rootChild)
{
if (m_rootChild == rootChild)
break;
case WM_DESTROY:
m_hwnd = 0;
-#if USE(ACCELERATED_COMPOSITING) && USE(CA)
+#if USE(CA)
if (m_layerTreeHost)
m_layerTreeHost->setWindow(0);
#endif
LPWINDOWPOS wp = reinterpret_cast<LPWINDOWPOS>(lParam);
if (wp->flags & SWP_NOSIZE)
break;
-#if USE(ACCELERATED_COMPOSITING) && USE(CA)
+#if USE(CA)
if (m_layerTreeHost) {
m_layerTreeHost->resize();
PlatformCALayer* rootLayer = m_rootChild->rootLayer();
}
break;
case WM_PAINT:
-#if USE(ACCELERATED_COMPOSITING) && USE(CA)
+#if USE(CA)
if (m_layerTreeHost) {
m_layerTreeHost->paint();
::ValidateRect(m_hwnd, 0);
#include <wtf/RefPtr.h>
#include <wtf/WindowsExtras.h>
-#if USE(ACCELERATED_COMPOSITING) && USE(CA)
+#if USE(CA)
#include "CACFLayerTreeHostClient.h"
#endif
namespace WebCore {
-#if USE(ACCELERATED_COMPOSITING) && USE(CA)
+#if USE(CA)
class CACFLayerTreeHost;
class PlatformCALayer;
#endif
HWND hwnd() const { return m_hwnd; }
-#if USE(ACCELERATED_COMPOSITING) && USE(CA)
+#if USE(CA)
PlatformCALayer* rootChildLayer() const { return m_rootChild.get(); }
void setRootChildLayer(PassRefPtr<PlatformCALayer>);
#endif
LRESULT wndProc(HWND, UINT message, WPARAM, LPARAM);
MediaPlayerPrivateFullscreenClient* m_client;
-#if USE(ACCELERATED_COMPOSITING) && USE(CA)
+#if USE(CA)
RefPtr<CACFLayerTreeHost> m_layerTreeHost;
RefPtr<PlatformCALayer> m_rootChild;
#endif
#include "GraphicsContext.h"
#include "MediaPlayerPrivateTaskTimer.h"
#include "Page.h"
+#include "PlatformCALayerWin.h"
#include "QTCFDictionary.h"
#include "QTDecompressionSession.h"
#include "QTMovie.h"
#include "TimeRanges.h"
#include "Timer.h"
#include "URL.h"
+#include "WKCAImageQueue.h"
#include <AssertMacros.h>
#include <CoreGraphics/CGAffineTransform.h>
#include <CoreGraphics/CGContext.h>
#include <wtf/text/StringBuilder.h>
#include <wtf/text/StringHash.h>
-#if USE(ACCELERATED_COMPOSITING)
-#include "PlatformCALayerWin.h"
-#include "WKCAImageQueue.h"
-#endif
-
using namespace std;
namespace WebCore {
MediaPlayerPrivateQuickTimeVisualContext* m_parent;
};
-#if USE(ACCELERATED_COMPOSITING)
class MediaPlayerPrivateQuickTimeVisualContext::LayerClient : public PlatformCALayerClient {
public:
LayerClient(MediaPlayerPrivateQuickTimeVisualContext* parent) : m_parent(parent) {}
m_parent->m_qtVideoLayer->setBounds(videoBounds);
m_parent->m_qtVideoLayer->setPosition(position);
}
-#endif
class MediaPlayerPrivateQuickTimeVisualContext::VisualContextClient : public QTMovieVisualContextClient {
public:
, m_visible(false)
, m_newFrameAvailable(false)
, m_movieClient(adoptPtr(new MediaPlayerPrivateQuickTimeVisualContext::MovieClient(this)))
-#if USE(ACCELERATED_COMPOSITING)
, m_layerClient(adoptPtr(new MediaPlayerPrivateQuickTimeVisualContext::LayerClient(this)))
, m_movieTransform(CGAffineTransformIdentity)
-#endif
, m_visualContextClient(adoptPtr(new MediaPlayerPrivateQuickTimeVisualContext::VisualContextClient(this)))
, m_delayingLoad(false)
, m_privateBrowsing(false)
bool MediaPlayerPrivateQuickTimeVisualContext::supportsFullscreen() const
{
-#if USE(ACCELERATED_COMPOSITING)
Document* document = m_player->mediaPlayerClient()->mediaPlayerOwningDocument();
if (document)
return document->settings()->acceleratedCompositingEnabled();
-#endif
+
return false;
}
p.media.qtMovieVisualContext = m_visualContext.get();
return p;
}
-#if USE(ACCELERATED_COMPOSITING)
PlatformLayer* MediaPlayerPrivateQuickTimeVisualContext::platformLayer() const
{
return m_transformLayer ? m_transformLayer->platformLayer() : 0;
}
-#endif
String MediaPlayerPrivateQuickTimeVisualContext::rfc2616DateStringFromTime(CFAbsoluteTime time)
{
int width;
int height;
m_movie->getNaturalSize(width, height);
-#if USE(ACCELERATED_COMPOSITING)
CGSize originalSize = {width, height};
CGSize transformedSize = CGSizeApplyAffineTransform(originalSize, m_movieTransform);
return IntSize(abs(transformedSize.width), abs(transformedSize.height));
-#else
- return IntSize(width, height);
-#endif
}
bool MediaPlayerPrivateQuickTimeVisualContext::hasVideo() const
QTPixelBuffer buffer = m_visualContext->imageForTime(0);
if (buffer.pixelBufferRef()) {
-#if USE(ACCELERATED_COMPOSITING)
if (m_qtVideoLayer) {
// We are probably being asked to render the video into a canvas, but
// there's a good chance the QTPixelBuffer is not ARGB and thus can't be
buffer = m_decompressionSession->decompress(buffer);
}
}
-#endif
+
CGImageRef image = CreateCGImageFromPixelBuffer(buffer);
CGContextRef context = p->platformContext();
static CGImageRef CreateCGImageFromPixelBuffer(QTPixelBuffer buffer)
{
-#if USE(ACCELERATED_COMPOSITING)
CGDataProviderRef provider = 0;
CGColorSpaceRef colorSpace = 0;
CGImageRef image = 0;
CGColorSpaceRelease(colorSpace);
return image;
-#else
- return 0;
-#endif
}
if (!m_visualContext)
return;
-#if USE(ACCELERATED_COMPOSITING)
if (m_qtVideoLayer) {
QTPixelBuffer buffer = m_visualContext->imageForTime(0);
layer->setNeedsCommit();
}
} else
-#endif
m_player->repaint();
m_visualContext->task();
if (!m_movie)
return MediaRenderingNone;
-#if USE(ACCELERATED_COMPOSITING)
if (m_qtVideoLayer)
return MediaRenderingMovieLayer;
-#endif
return m_visualContext ? MediaRenderingSoftwareRenderer : MediaRenderingNone;
}
if (!m_player->frameView() || !m_movie)
return MediaRenderingNone;
-#if USE(ACCELERATED_COMPOSITING)
if (supportsAcceleratedRendering() && m_player->mediaPlayerClient()->mediaPlayerRenderingCanBeAccelerated(m_player))
return MediaRenderingMovieLayer;
-#endif
return MediaRenderingSoftwareRenderer;
}
MediaRenderingMode currentMode = currentRenderingMode();
MediaRenderingMode preferredMode = preferredRenderingMode();
-#if !USE(ACCELERATED_COMPOSITING)
- ASSERT(preferredMode != MediaRenderingMovieLayer);
-#endif
-
if (currentMode == preferredMode && currentMode != MediaRenderingNone)
return;
if (preferredMode == MediaRenderingMovieLayer)
createLayerForMovie();
-#if USE(ACCELERATED_COMPOSITING)
if (currentMode == MediaRenderingMovieLayer || preferredMode == MediaRenderingMovieLayer)
m_player->mediaPlayerClient()->mediaPlayerRenderingModeChanged(m_player);
-#endif
QTPixelBuffer::Type contextType = requiredDllsAvailable() && preferredMode == MediaRenderingMovieLayer ? QTPixelBuffer::ConfigureForCAImageQueue : QTPixelBuffer::ConfigureForCGImage;
m_visualContext = QTMovieVisualContext::create(m_visualContextClient.get(), contextType);
void MediaPlayerPrivateQuickTimeVisualContext::tearDownVideoRendering()
{
-#if USE(ACCELERATED_COMPOSITING)
if (m_qtVideoLayer)
destroyLayerForMovie();
-#endif
m_visualContext = 0;
}
bool MediaPlayerPrivateQuickTimeVisualContext::hasSetUpVideoRendering() const
{
-#if USE(ACCELERATED_COMPOSITING)
return m_qtVideoLayer || (currentRenderingMode() != MediaRenderingMovieLayer && m_visualContext);
-#else
- return true;
-#endif
}
void MediaPlayerPrivateQuickTimeVisualContext::retrieveAndResetMovieTransform()
{
-#if USE(ACCELERATED_COMPOSITING)
// First things first, reset the total movie transform so that
// we can bail out early:
m_movieTransform = CGAffineTransformIdentity;
// Multiply the two transforms together, taking care to
// do so in the correct order, track * movie = final:
m_movieTransform = CGAffineTransformConcat(trackTransform, movieTransform);
-#endif
}
void MediaPlayerPrivateQuickTimeVisualContext::createLayerForMovie()
{
-#if USE(ACCELERATED_COMPOSITING)
ASSERT(supportsAcceleratedRendering());
if (!m_movie || m_qtVideoLayer)
m_transformLayer->appendSublayer(m_qtVideoLayer.get());
m_transformLayer->setNeedsLayout();
// The layer will get hooked up via RenderLayerBacking::updateGraphicsLayerConfiguration().
-#endif
// Fill the newly created layer with image data, so we're not looking at
// an empty layer until the next time a new image is available, which could
void MediaPlayerPrivateQuickTimeVisualContext::destroyLayerForMovie()
{
-#if USE(ACCELERATED_COMPOSITING)
if (m_qtVideoLayer) {
m_qtVideoLayer->removeFromSuperlayer();
m_qtVideoLayer = 0;
if (m_imageQueue)
m_imageQueue = nullptr;
-#endif
}
-#if USE(ACCELERATED_COMPOSITING)
bool MediaPlayerPrivateQuickTimeVisualContext::supportsAcceleratedRendering() const
{
return isReadyForRendering();
if (m_movie)
m_movie->setPrivateBrowsingMode(m_privateBrowsing);
}
-
-#endif
-
}