Index: src/gpu/GrGpu.h |
diff --git a/src/gpu/GrGpu.h b/src/gpu/GrGpu.h |
index ade64312b866ac0f831ad9b20e413143cd6c1ba9..5b556c5b2543607e40e042263d3ba7d54d6bf458 100644 |
--- a/src/gpu/GrGpu.h |
+++ b/src/gpu/GrGpu.h |
@@ -152,11 +152,18 @@ public: |
void forceRenderTargetFlush(); |
/** |
- * Gets a preferred 8888 config to use for writing / reading pixel data. The returned config |
- * must have at least as many bits per channel as the config param. |
+ * Gets a preferred 8888 config to use for writing/reading pixel data to/from a surface with |
+ * config surfaceConfig. The returned config must have at least as many bits per channel as the |
+ * readConfig or writeConfig param. |
*/ |
- virtual GrPixelConfig preferredReadPixelsConfig(GrPixelConfig config) const { return config; } |
- virtual GrPixelConfig preferredWritePixelsConfig(GrPixelConfig config) const { return config; } |
+ virtual GrPixelConfig preferredReadPixelsConfig(GrPixelConfig readConfig, |
+ GrPixelConfig surfaceConfig) const { |
+ return readConfig; |
+ } |
+ virtual GrPixelConfig preferredWritePixelsConfig(GrPixelConfig writeConfig, |
+ GrPixelConfig surfaceConfig) const { |
+ return writeConfig; |
+ } |
/** |
* Called before uploading writing pixels to a GrTexture when the src pixel config doesn't |