aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/gpu/GrSurface.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/gpu/GrSurface.h')
-rw-r--r--include/gpu/GrSurface.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/gpu/GrSurface.h b/include/gpu/GrSurface.h
index 3aa498b611..c401a905ff 100644
--- a/include/gpu/GrSurface.h
+++ b/include/gpu/GrSurface.h
@@ -126,6 +126,12 @@ public:
size_t rowBytes = 0,
uint32_t pixelOpsFlags = 0) = 0;
+ /**
+ * Write the contents of the surface to a PNG. Returns true if successful.
+ * @param filename Full path to desired file
+ */
+ bool savePixels(const char* filename);
+
protected:
GrSurface(GrGpu* gpu, bool isWrapped, const GrTextureDesc& desc)
: INHERITED(gpu, isWrapped)