aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/image/SkSurface_Gpu.cpp
diff options
context:
space:
mode:
authorGravatar Mike Reed <reed@google.com>2018-02-08 14:10:40 -0500
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2018-02-08 19:34:50 +0000
commit4c790bd7dd8a6edacfc39b65b7043742331ab4da (patch)
tree1d66da0bfa6b7627315388b0d3f712897ea03bbd /src/image/SkSurface_Gpu.cpp
parentb9fc24e465767db8bd9dbddfd67c905392346e66 (diff)
add writePixels to SkSurface --> so we can remove it from canvas
Bug: skia: Change-Id: Ib35d7bdc113c3fd9f6dfacb42ec61aaa448cb165 Reviewed-on: https://skia-review.googlesource.com/105623 Commit-Queue: Mike Reed <reed@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
Diffstat (limited to 'src/image/SkSurface_Gpu.cpp')
-rw-r--r--src/image/SkSurface_Gpu.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/image/SkSurface_Gpu.cpp b/src/image/SkSurface_Gpu.cpp
index d7c1a46c58..04333ae508 100644
--- a/src/image/SkSurface_Gpu.cpp
+++ b/src/image/SkSurface_Gpu.cpp
@@ -125,6 +125,10 @@ sk_sp<SkImage> SkSurface_Gpu::onNewImageSnapshot() {
return image;
}
+void SkSurface_Gpu::onWritePixels(const SkPixmap& src, int x, int y) {
+ fDevice->writePixels(src, x, y);
+}
+
// Create a new render target and, if necessary, copy the contents of the old
// render target into it. Note that this flushes the SkGpuDevice but
// doesn't force an OpenGL flush.