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

Side by Side Diff: include/gpu/GrPathRendererChain.h

Issue 858343002: Rename GrOptDrawState to GrPipeline and GrDrawState to GrPipelineBuilder (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: more nits Created 5 years, 11 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 | « include/gpu/GrContext.h ('k') | src/gpu/GrAAConvexPathRenderer.h » ('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 2011 Google Inc. 2 * Copyright 2011 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 7
8 #ifndef GrPathRendererChain_DEFINED 8 #ifndef GrPathRendererChain_DEFINED
9 #define GrPathRendererChain_DEFINED 9 #define GrPathRendererChain_DEFINED
10 10
11 #include "SkRefCnt.h" 11 #include "SkRefCnt.h"
12 #include "SkTArray.h" 12 #include "SkTArray.h"
13 13
14 class GrContext; 14 class GrContext;
15 class GrDrawState;
16 class GrDrawTarget; 15 class GrDrawTarget;
17 class GrPathRenderer; 16 class GrPathRenderer;
17 class GrPipelineBuilder;
18 class SkMatrix; 18 class SkMatrix;
19 class SkPath; 19 class SkPath;
20 class SkStrokeRec; 20 class SkStrokeRec;
21 21
22 /** 22 /**
23 * Keeps track of an ordered list of path renderers. When a path needs to be 23 * Keeps track of an ordered list of path renderers. When a path needs to be
24 * drawn this list is scanned to find the most preferred renderer. To add your 24 * drawn this list is scanned to find the most preferred renderer. To add your
25 * path renderer to the list implement the GrPathRenderer::AddPathRenderers 25 * path renderer to the list implement the GrPathRenderer::AddPathRenderers
26 * function. 26 * function.
27 */ 27 */
(...skipping 23 matching lines...) Expand all
51 kStencilOnly_DrawType, // draw just to the stencil buffer 51 kStencilOnly_DrawType, // draw just to the stencil buffer
52 kStencilAndColor_DrawType, // draw the stencil and color buffer , no AA 52 kStencilAndColor_DrawType, // draw the stencil and color buffer , no AA
53 kStencilAndColorAntiAlias_DrawType // draw the stencil and color buffer , with partial 53 kStencilAndColorAntiAlias_DrawType // draw the stencil and color buffer , with partial
54 // coverage AA. 54 // coverage AA.
55 }; 55 };
56 /** Returns a GrPathRenderer compatible with the request if one is available . If the caller 56 /** Returns a GrPathRenderer compatible with the request if one is available . If the caller
57 is drawing the path to the stencil buffer then stencilSupport can be use d to determine 57 is drawing the path to the stencil buffer then stencilSupport can be use d to determine
58 whether the path can be rendered with arbitrary stencil rules or not. Se e comments on 58 whether the path can be rendered with arbitrary stencil rules or not. Se e comments on
59 StencilSupport in GrPathRenderer.h. */ 59 StencilSupport in GrPathRenderer.h. */
60 GrPathRenderer* getPathRenderer(const GrDrawTarget* target, 60 GrPathRenderer* getPathRenderer(const GrDrawTarget* target,
61 const GrDrawState*, 61 const GrPipelineBuilder*,
62 const SkMatrix& viewMatrix, 62 const SkMatrix& viewMatrix,
63 const SkPath& path, 63 const SkPath& path,
64 const SkStrokeRec& rec, 64 const SkStrokeRec& rec,
65 DrawType drawType, 65 DrawType drawType,
66 StencilSupport* stencilSupport); 66 StencilSupport* stencilSupport);
67 67
68 private: 68 private:
69 GrPathRendererChain(); 69 GrPathRendererChain();
70 70
71 void init(); 71 void init();
72 72
73 enum { 73 enum {
74 kPreAllocCount = 8, 74 kPreAllocCount = 8,
75 }; 75 };
76 bool fInit; 76 bool fInit;
77 GrContext* fOwner; 77 GrContext* fOwner;
78 SkSTArray<kPreAllocCount, GrPathRenderer*, true> fChain; 78 SkSTArray<kPreAllocCount, GrPathRenderer*, true> fChain;
79 79
80 typedef SkRefCnt INHERITED; 80 typedef SkRefCnt INHERITED;
81 }; 81 };
82 82
83 #endif 83 #endif
OLDNEW
« no previous file with comments | « include/gpu/GrContext.h ('k') | src/gpu/GrAAConvexPathRenderer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698