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

Unified Diff: include/gpu/GrBackendProcessorFactory.h

Issue 772513002: create and thread batch tracker object (Closed) Base URL: https://skia.googlesource.com/skia.git@2_vertex_attr
Patch Set: rebase Created 6 years 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
« no previous file with comments | « no previous file | include/gpu/GrTBackendProcessorFactory.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/gpu/GrBackendProcessorFactory.h
diff --git a/include/gpu/GrBackendProcessorFactory.h b/include/gpu/GrBackendProcessorFactory.h
index acbc12c192610eca193d476abf69a8d5069152b4..dc0bbbe53f66e224bd61cc729f615d69c7fa1270 100644
--- a/include/gpu/GrBackendProcessorFactory.h
+++ b/include/gpu/GrBackendProcessorFactory.h
@@ -68,14 +68,6 @@ private:
*/
class GrBackendProcessorFactory : SkNoncopyable {
public:
- /**
- * Generates an processor's key. The key is based on the aspects of the GrProcessor object's
- * configuration that affect GLSL code generation. Two GrProcessor instances that would cause
- * this->createGLInstance()->emitCode() to produce different code must produce different keys.
- */
- virtual void getGLProcessorKey(const GrProcessor&, const GrGLCaps&,
- GrProcessorKeyBuilder*) const = 0;
-
/**
* Produces a human-reable name for the v.
*/
@@ -128,6 +120,15 @@ class GrGLXferProcessor;
class GrBackendFragmentProcessorFactory : public GrBackendProcessorFactory {
public:
/**
+ * Generates an processor's key. The key is based on the aspects of the GrProcessor object's
+ * configuration that affect GLSL code generation. Two GrProcessor instances that would cause
+ * this->createGLInstance()->emitCode() to produce different code must produce different keys.
+ */
+ virtual void getGLProcessorKey(const GrFragmentProcessor&,
+ const GrGLCaps&,
+ GrProcessorKeyBuilder*) const = 0;
+
+ /**
* Creates a GrGLProcessor instance that is used both to generate code for the GrProcessor in a
* GLSL program and to manage updating uniforms for the program when it is used.
*/
@@ -143,13 +144,26 @@ public:
virtual GrGLXferProcessor* createGLInstance(const GrXferProcessor&) const = 0;
};
+class GrBatchTracker;
+
class GrBackendGeometryProcessorFactory : public GrBackendProcessorFactory {
public:
/**
+ * Generates an processor's key. The key is based on the aspects of the GrProcessor object's
+ * configuration that affect GLSL code generation. Two GrProcessor instances that would cause
+ * this->createGLInstance()->emitCode() to produce different code must produce different keys.
+ */
+ virtual void getGLProcessorKey(const GrGeometryProcessor&,
+ const GrBatchTracker&,
+ const GrGLCaps&,
+ GrProcessorKeyBuilder*) const = 0;
+
+ /**
* Creates a GrGLProcessor instance that is used both to generate code for the GrProcessor in a
* GLSL program and to manage updating uniforms for the program when it is used.
*/
- virtual GrGLGeometryProcessor* createGLInstance(const GrGeometryProcessor&) const = 0;
+ virtual GrGLGeometryProcessor* createGLInstance(const GrGeometryProcessor&,
+ const GrBatchTracker&) const = 0;
};
#endif
« no previous file with comments | « no previous file | include/gpu/GrTBackendProcessorFactory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698