Index: include/core/SkColorFilter.h |
diff --git a/include/core/SkColorFilter.h b/include/core/SkColorFilter.h |
index a92f9aeff2899e2807e3966798868974a018dd99..a5a1a4c0cc546d8229e4c3481a0212cbd52af696 100644 |
--- a/include/core/SkColorFilter.h |
+++ b/include/core/SkColorFilter.h |
@@ -124,20 +124,17 @@ public: |
static SkColorFilter* CreateComposeFilter(SkColorFilter* outer, SkColorFilter* inner); |
/** |
- * A subclass may implement this factory function to work with the GPU backend. |
- * If it returns true, then 1 or more fragment processors will have been appended to the |
- * array, each of which has been ref'd, so that the caller is responsible for calling unref() |
- * on them when they are finished. If more than one processor is appended, they will be |
- * applied in FIFO order. |
+ * A subclass may implement this factory function to work with the GPU backend. It returns |
+ * a GrFragmentProcessor that implemets the color filter in GPU shader code. |
* |
- * The fragment processor(s) must each return their color as a premul normalized value |
- * e.g. each component between [0..1] and each color component <= alpha. |
+ * The fragment processor receives a premultiplied input color and produces a premultiplied |
+ * output color. |
* |
- * If the subclass returns false, then it should not modify the array at all. |
+ * A null return indicates that the color filter isn't implemented for the GPU backend. |
*/ |
- virtual bool asFragmentProcessors(GrContext*, GrProcessorDataManager*, |
- SkTDArray<const GrFragmentProcessor*>*) const { |
- return false; |
+ virtual const GrFragmentProcessor* asFragmentProcessor(GrContext*, |
+ GrProcessorDataManager*) const { |
+ return nullptr; |
} |
bool affectsTransparentBlack() const { |