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

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

Issue 597323002: Split GrDrawState and GrOptDrawState into separate classes and remove base class. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: More nits Created 6 years, 2 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 | « gyp/gpu.gypi ('k') | src/gpu/GrDrawState.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 GrGpuResourceRef_DEFINED 8 #ifndef GrGpuResourceRef_DEFINED
9 #define GrGpuResourceRef_DEFINED 9 #define GrGpuResourceRef_DEFINED
10 10
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 writes to the resource using the program element or draw state. It can o nly be called once. 68 writes to the resource using the program element or draw state. It can o nly be called once.
69 */ 69 */
70 void removeRef() const; 70 void removeRef() const;
71 71
72 /** Called to indicate that the previous pending IO is complete. Useful when the owning object 72 /** Called to indicate that the previous pending IO is complete. Useful when the owning object
73 still has refs, so it is not about to destroy this GrGpuResourceRef, but its previously 73 still has refs, so it is not about to destroy this GrGpuResourceRef, but its previously
74 pending executions have been complete. Can only be called if removeRef() was not previously 74 pending executions have been complete. Can only be called if removeRef() was not previously
75 called. */ 75 called. */
76 void pendingIOComplete() const; 76 void pendingIOComplete() const;
77 77
78 friend class GrRODrawState; 78 friend class GrDrawState;
79 friend class GrOptDrawState;
79 friend class GrProgramElement; 80 friend class GrProgramElement;
80 81
81 GrGpuResource* fResource; 82 GrGpuResource* fResource;
82 mutable bool fOwnRef; 83 mutable bool fOwnRef;
83 mutable bool fPendingIO; 84 mutable bool fPendingIO;
84 GrIORef::IOType fIOType; 85 GrIORef::IOType fIOType;
85 86
86 typedef SkNoncopyable INHERITED; 87 typedef SkNoncopyable INHERITED;
87 }; 88 };
88 89
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
146 } 147 }
147 } 148 }
148 } 149 }
149 150
150 T* get() const { return fResource; } 151 T* get() const { return fResource; }
151 152
152 private: 153 private:
153 T* fResource; 154 T* fResource;
154 }; 155 };
155 #endif 156 #endif
OLDNEW
« no previous file with comments | « gyp/gpu.gypi ('k') | src/gpu/GrDrawState.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698