aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/GrRenderTarget.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gpu/GrRenderTarget.cpp')
-rw-r--r--src/gpu/GrRenderTarget.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/gpu/GrRenderTarget.cpp b/src/gpu/GrRenderTarget.cpp
index 7901648d3a..ed1a018a02 100644
--- a/src/gpu/GrRenderTarget.cpp
+++ b/src/gpu/GrRenderTarget.cpp
@@ -41,6 +41,15 @@ void GrRenderTarget::writePixels(int left, int top, int width, int height,
config, buffer, rowBytes);
}
+void GrRenderTarget::resolve() {
+ // go through context so that all necessary flushing occurs
+ GrContext* context = this->getContext();
+ if (NULL == context) {
+ return;
+ }
+ context->resolveRenderTarget(this);
+}
+
size_t GrRenderTarget::sizeInBytes() const {
int colorBits;
if (kUnknown_GrPixelConfig == fConfig) {