From 687378229aecefc0ab7e639181593774ec8a4290 Mon Sep 17 00:00:00 2001 From: robertphillips Date: Thu, 29 Oct 2015 12:12:21 -0700 Subject: Remove GrPipelineBuilder from getPathRenderer call Logically this CL: Moves the PathRendererChain from GrContext to GrDrawManager - this was needed to untangled the Path-Chain/Renderer header mess - this entailed adding getDrawingMgr so the CMM could access the PathRenderingChain - this also entailed re-adding freeGpuResources to the GrDrawingMgr Moves the CanDrawArgs struct up stack Removes the GrPipelineBuilder from the CanDrawArgs struct Review URL: https://codereview.chromium.org/1407883004 --- src/gpu/GrClipMaskManager.h | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'src/gpu/GrClipMaskManager.h') diff --git a/src/gpu/GrClipMaskManager.h b/src/gpu/GrClipMaskManager.h index 2d9816c84c..98fd3af351 100644 --- a/src/gpu/GrClipMaskManager.h +++ b/src/gpu/GrClipMaskManager.h @@ -76,6 +76,18 @@ private: inline const GrCaps* caps() const; inline GrResourceProvider* resourceProvider(); + static bool PathNeedsSWRenderer(GrContext* context, + bool isStencilDisabled, + const GrRenderTarget* rt, + const SkMatrix& viewMatrix, + const SkClipStack::Element* element, + GrPathRenderer** prOut, + bool needsStencil); + static GrPathRenderer* GetPathRenderer(GrContext* context, + GrTexture* texture, + const SkMatrix& viewMatrix, + const SkClipStack::Element* element); + /** * Informs the helper function adjustStencilParams() about how the stencil * buffer clip is being used. @@ -125,8 +137,9 @@ private: const SkIRect& clipSpaceIBounds); bool useSWOnlyPath(const GrPipelineBuilder&, - const SkVector& clipToMaskOffset, - const GrReducedClip::ElementList& elements); + const GrRenderTarget* rt, + const SkVector& clipToMaskOffset, + const GrReducedClip::ElementList& elements); // Draws a clip element into the target alpha mask. The caller should have already setup the // desired blend operation. Optionally if the caller already selected a path renderer it can -- cgit v1.2.3