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

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

Issue 1121463002: Move bounds to GrBatch (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: tweak Created 5 years, 7 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/GrOvalRenderer.cpp ('k') | src/gpu/GrTessellatingPathRenderer.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 2015 Google Inc. 2 * Copyright 2015 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 GrTargetCommands_DEFINED 8 #ifndef GrTargetCommands_DEFINED
9 #define GrTargetCommands_DEFINED 9 #define GrTargetCommands_DEFINED
10 10
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 75
76 Cmd* recordDiscard(GrInOrderDrawBuffer*, GrRenderTarget*); 76 Cmd* recordDiscard(GrInOrderDrawBuffer*, GrRenderTarget*);
77 77
78 Cmd* recordDraw(GrInOrderDrawBuffer*, 78 Cmd* recordDraw(GrInOrderDrawBuffer*,
79 const GrGeometryProcessor*, 79 const GrGeometryProcessor*,
80 const GrDrawTarget::DrawInfo&, 80 const GrDrawTarget::DrawInfo&,
81 const GrDrawTarget::PipelineInfo&); 81 const GrDrawTarget::PipelineInfo&);
82 Cmd* recordDrawBatch(GrInOrderDrawBuffer*, 82 Cmd* recordDrawBatch(GrInOrderDrawBuffer*,
83 GrBatch*, 83 GrBatch*,
84 const GrDrawTarget::PipelineInfo&); 84 const GrDrawTarget::PipelineInfo&);
85 void recordDrawRect(GrInOrderDrawBuffer*,
86 GrPipelineBuilder*,
87 GrColor,
88 const SkMatrix& viewMatrix,
89 const SkRect& rect,
90 const SkRect* localRect,
91 const SkMatrix* localMatrix);
92 Cmd* recordStencilPath(GrInOrderDrawBuffer*, 85 Cmd* recordStencilPath(GrInOrderDrawBuffer*,
93 const GrPipelineBuilder&, 86 const GrPipelineBuilder&,
94 const GrPathProcessor*, 87 const GrPathProcessor*,
95 const GrPath*, 88 const GrPath*,
96 const GrScissorState&, 89 const GrScissorState&,
97 const GrStencilSettings&); 90 const GrStencilSettings&);
98 Cmd* recordDrawPath(GrInOrderDrawBuffer*, 91 Cmd* recordDrawPath(GrInOrderDrawBuffer*,
99 const GrPathProcessor*, 92 const GrPathProcessor*,
100 const GrPath*, 93 const GrPath*,
101 const GrStencilSettings&, 94 const GrStencilSettings&,
(...skipping 11 matching lines...) Expand all
113 Cmd* recordClear(GrInOrderDrawBuffer*, 106 Cmd* recordClear(GrInOrderDrawBuffer*,
114 const SkIRect* rect, 107 const SkIRect* rect,
115 GrColor, 108 GrColor,
116 bool canIgnoreRect, 109 bool canIgnoreRect,
117 GrRenderTarget*); 110 GrRenderTarget*);
118 Cmd* recordCopySurface(GrSurface* dst, 111 Cmd* recordCopySurface(GrSurface* dst,
119 GrSurface* src, 112 GrSurface* src,
120 const SkIRect& srcRect, 113 const SkIRect& srcRect,
121 const SkIPoint& dstPoint); 114 const SkIPoint& dstPoint);
122 115
123 protected:
124 void willReserveVertexAndIndexSpace(int vertexCount,
125 size_t vertexStride,
126 int indexCount);
127
128 private: 116 private:
129 friend class GrInOrderDrawBuffer; 117 friend class GrInOrderDrawBuffer;
130 118
131 typedef GrGpu::DrawArgs DrawArgs; 119 typedef GrGpu::DrawArgs DrawArgs;
132 120
133 // Attempts to concat instances from info onto the previous draw. info must represent an 121 // Attempts to concat instances from info onto the previous draw. info must represent an
134 // instanced draw. The caller must have already recorded a new draw state an d clip if necessary. 122 // instanced draw. The caller must have already recorded a new draw state an d clip if necessary.
135 int concatInstancedDraw(GrInOrderDrawBuffer*, const GrDrawTarget::DrawInfo&) ; 123 int concatInstancedDraw(GrInOrderDrawBuffer*, const GrDrawTarget::DrawInfo&) ;
136 124
137 bool SK_WARN_UNUSED_RESULT setupPipelineAndShouldDraw(GrInOrderDrawBuffer*, 125 bool SK_WARN_UNUSED_RESULT setupPipelineAndShouldDraw(GrInOrderDrawBuffer*,
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
306 typedef void* TCmdAlign; // This wouldn't be enough align if a command used long double. 294 typedef void* TCmdAlign; // This wouldn't be enough align if a command used long double.
307 typedef GrTRecorder<Cmd, TCmdAlign> CmdBuffer; 295 typedef GrTRecorder<Cmd, TCmdAlign> CmdBuffer;
308 296
309 CmdBuffer fCmdBuffer; 297 CmdBuffer fCmdBuffer;
310 SetState* fPrevState; 298 SetState* fPrevState;
311 GrBatchTarget fBatchTarget; 299 GrBatchTarget fBatchTarget;
312 }; 300 };
313 301
314 #endif 302 #endif
315 303
OLDNEW
« no previous file with comments | « src/gpu/GrOvalRenderer.cpp ('k') | src/gpu/GrTessellatingPathRenderer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698