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

Unified Diff: include/gpu/GrProgramElement.h

Issue 574333003: Rename GrProgramResource to GrGpuResourceRef (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: include/gpu/GrProgramElement.h
diff --git a/include/gpu/GrProgramElement.h b/include/gpu/GrProgramElement.h
index 5f88a2a68f79896cf1880692c8f0659c8d702bd6..73ff39bbf649c4f64d33ad6f63a8b84804fc8ec0 100644
--- a/include/gpu/GrProgramElement.h
+++ b/include/gpu/GrProgramElement.h
@@ -11,7 +11,7 @@
#include "SkRefCnt.h"
#include "SkTArray.h"
-class GrProgramResource;
+class GrGpuResourceRef;
/**
* Base class for GrEffect (and future GrGeometryProcessor). GrDrawState uses this to manage
@@ -19,8 +19,8 @@ class GrProgramResource;
* converts resources owned by the effect from being ref'ed to having pending reads/writes.
*
* All GrGpuResource objects owned by a GrProgramElement or derived classes (either directly or
- * indirectly) must be wrapped in a GrProgramResource and registered with the GrProgramElement using
- * addGrProgramResource(). This allows the regular refs to be converted to pending IO events
+ * indirectly) must be wrapped in a GrGpuResourceRef and registered with the GrProgramElement using
robertphillips 2014/09/17 14:38:38 This remained addProgramResource.
bsalomon 2014/09/17 14:55:03 Ah, nice catch. Renamed to addGpuResource(), renam
+ * addGrGpuResourceRef(). This allows the regular refs to be converted to pending IO events
* when the program element is scheduled for deferred execution.
*/
class GrProgramElement : public SkNoncopyable {
@@ -67,9 +67,9 @@ protected:
/** Subclasses registers their resources using this function. It is assumed the GrProgramResouce
is and will remain owned by the subclass and this function will retain a raw ptr. Once a
- GrProgramResource is registered its setResource must not be called.
+ GrGpuResourceRef is registered its setResource must not be called.
*/
- void addProgramResource(const GrProgramResource* res) {
+ void addProgramResource(const GrGpuResourceRef* res) {
fProgramResources.push_back(res);
}
@@ -85,7 +85,7 @@ private:
mutable int32_t fPendingExecutions;
uint32_t fUniqueID;
- SkSTArray<4, const GrProgramResource*, true> fProgramResources;
+ SkSTArray<4, const GrGpuResourceRef*, true> fProgramResources;
// Only this class can access convertRefToPendingExecution() and completedExecution().
template <typename T> friend class GrProgramElementRef;

Powered by Google App Engine
This is Rietveld 408576698