Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(27)

Side by Side Diff: src/gpu/GrClipStackClip.h

Issue 2246113002: Convert GrAppliedClip interface to builder style (Closed) Base URL: https://skia.googlesource.com/skia.git@fixstencilpath
Patch Set: Convert GrAppliedClip interface to builder style Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/gpu/GrClip.cpp ('k') | src/gpu/GrClipStackClip.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2016 Google Inc. 2 * Copyright 2016 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 #ifndef GrClipStackClip_DEFINED 7 #ifndef GrClipStackClip_DEFINED
8 #define GrClipStackClip_DEFINED 8 #define GrClipStackClip_DEFINED
9 9
10 #include "GrClip.h" 10 #include "GrClip.h"
(...skipping 15 matching lines...) Expand all
26 } 26 }
27 27
28 void reset(const SkClipStack* stack = nullptr, const SkIPoint* origin = null ptr) { 28 void reset(const SkClipStack* stack = nullptr, const SkIPoint* origin = null ptr) {
29 fOrigin = origin ? *origin : SkIPoint::Make(0, 0); 29 fOrigin = origin ? *origin : SkIPoint::Make(0, 0);
30 fStack.reset(SkSafeRef(stack)); 30 fStack.reset(SkSafeRef(stack));
31 } 31 }
32 32
33 bool quickContains(const SkRect&) const final; 33 bool quickContains(const SkRect&) const final;
34 void getConservativeBounds(int width, int height, SkIRect* devResult, 34 void getConservativeBounds(int width, int height, SkIRect* devResult,
35 bool* isIntersectionOfRects) const final; 35 bool* isIntersectionOfRects) const final;
36 bool apply(GrContext*, 36 bool apply(GrContext*, GrDrawContext*, bool useHWAA, bool hasUserStencilSett ings,
37 GrDrawContext*,
38 const SkRect* devBounds,
39 bool useHWAA,
40 bool hasUserStencilSettings,
41 GrAppliedClip* out) const final; 37 GrAppliedClip* out) const final;
42 38
43 private: 39 private:
44 static bool PathNeedsSWRenderer(GrContext* context, 40 static bool PathNeedsSWRenderer(GrContext* context,
45 bool hasUserStencilSettings, 41 bool hasUserStencilSettings,
46 const GrDrawContext*, 42 const GrDrawContext*,
47 const SkMatrix& viewMatrix, 43 const SkMatrix& viewMatrix,
48 const SkClipStack::Element* element, 44 const SkClipStack::Element* element,
49 GrPathRenderer** prOut, 45 GrPathRenderer** prOut,
50 bool needsStencil); 46 bool needsStencil);
(...skipping 22 matching lines...) Expand all
73 const GrReducedClip::ElementList& elements); 69 const GrReducedClip::ElementList& elements);
74 70
75 static GrTexture* CreateCachedMask(int width, int height, const GrUniqueKey& key, 71 static GrTexture* CreateCachedMask(int width, int height, const GrUniqueKey& key,
76 bool renderTarget); 72 bool renderTarget);
77 73
78 SkIPoint fOrigin; 74 SkIPoint fOrigin;
79 SkAutoTUnref<const SkClipStack> fStack; 75 SkAutoTUnref<const SkClipStack> fStack;
80 }; 76 };
81 77
82 #endif // GrClipStackClip_DEFINED 78 #endif // GrClipStackClip_DEFINED
OLDNEW
« no previous file with comments | « src/gpu/GrClip.cpp ('k') | src/gpu/GrClipStackClip.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698