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

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

Issue 732693002: Drawstate on stack (Closed) Base URL: https://skia.googlesource.com/skia.git@real_def_gp
Patch Set: tiny fix Created 6 years, 1 month 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/GrInOrderDrawBuffer.cpp ('k') | src/gpu/GrOvalRenderer.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 2014 Google Inc. 2 * Copyright 2014 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 GrOptDrawState_DEFINED 8 #ifndef GrOptDrawState_DEFINED
9 #define GrOptDrawState_DEFINED 9 #define GrOptDrawState_DEFINED
10 10
(...skipping 12 matching lines...) Expand all
23 /** 23 /**
24 * Class that holds an optimized version of a GrDrawState. It is meant to be an immutable class, 24 * Class that holds an optimized version of a GrDrawState. It is meant to be an immutable class,
25 * and contains all data needed to set the state for a gpu draw. 25 * and contains all data needed to set the state for a gpu draw.
26 */ 26 */
27 class GrOptDrawState : public SkRefCnt { 27 class GrOptDrawState : public SkRefCnt {
28 public: 28 public:
29 /** 29 /**
30 * Returns a snapshot of the current optimized state. The GrOptDrawState is reffed and ownership 30 * Returns a snapshot of the current optimized state. The GrOptDrawState is reffed and ownership
31 * is given to the caller. 31 * is given to the caller.
32 */ 32 */
33 static GrOptDrawState* Create(const GrDrawState& drawState, GrGpu*, 33 static GrOptDrawState* Create(const GrDrawState& drawState,
34 const GrDeviceCoordTexture* dstCopy, GrGpu::Dr awType drawType); 34 GrGpu*,
35 const GrDeviceCoordTexture* dstCopy,
36 GrGpu::DrawType drawType);
35 37
36 bool operator== (const GrOptDrawState& that) const; 38 bool operator== (const GrOptDrawState& that) const;
37 39
38 /////////////////////////////////////////////////////////////////////////// 40 ///////////////////////////////////////////////////////////////////////////
39 /// @name Vertex Attributes 41 /// @name Vertex Attributes
40 //// 42 ////
41 43
42 enum { 44 enum {
43 kMaxVertexAttribCnt = kLast_GrVertexAttribBinding + 4, 45 kMaxVertexAttribCnt = kLast_GrVertexAttribBinding + 4,
44 }; 46 };
(...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after
388 390
389 GrProgramDesc fDesc; 391 GrProgramDesc fDesc;
390 392
391 typedef SkRefCnt INHERITED; 393 typedef SkRefCnt INHERITED;
392 }; 394 };
393 395
394 GR_MAKE_BITFIELD_OPS(GrOptDrawState::BlendOptFlags); 396 GR_MAKE_BITFIELD_OPS(GrOptDrawState::BlendOptFlags);
395 397
396 #endif 398 #endif
397 399
OLDNEW
« no previous file with comments | « src/gpu/GrInOrderDrawBuffer.cpp ('k') | src/gpu/GrOvalRenderer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698