aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/GrTextureRenderTargetProxy.cpp
diff options
context:
space:
mode:
authorGravatar Robert Phillips <robertphillips@google.com>2017-02-28 11:26:32 -0500
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-02-28 17:21:55 +0000
commitc787e495e28d3a37945e74e24bb6ee8f635d86b7 (patch)
tree9fbcc692fcffe3b8a90cbb57f01c5e93225dbaa8 /src/gpu/GrTextureRenderTargetProxy.cpp
parentb26373cfd8151b2fa56bdf532ddcde4919cce09f (diff)
Allow GrSurfaceProxy-derived classes to use flags when instantiating (take 2)
In some instances proxies must be created that, when instantiated, have no pending IO. This is split out of: https://skia-review.googlesource.com/c/8679/ (Add per-Flush callback to GrDrawingManager) and is a reland of: https://skia-review.googlesource.com/c/8988/ ( Allow GrSurfaceProxy-derived classes to use flags when instantiating) Change-Id: I36f52a6d249e762bdfc1f0d7528aba6d4071e492 Reviewed-on: https://skia-review.googlesource.com/9070 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
Diffstat (limited to 'src/gpu/GrTextureRenderTargetProxy.cpp')
-rw-r--r--src/gpu/GrTextureRenderTargetProxy.cpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/gpu/GrTextureRenderTargetProxy.cpp b/src/gpu/GrTextureRenderTargetProxy.cpp
index 212ea0a049..432d00854f 100644
--- a/src/gpu/GrTextureRenderTargetProxy.cpp
+++ b/src/gpu/GrTextureRenderTargetProxy.cpp
@@ -8,19 +8,21 @@
#include "GrTextureRenderTargetProxy.h"
// Deferred version
-// This class is virtually derived from GrSurfaceProxy (via both GrTextureProxy and
+// This class is virtually derived from GrSurfaceProxy (via both GrTextureProxy and
// GrRenderTargetProxy) so its constructor must be explicitly called.
GrTextureRenderTargetProxy::GrTextureRenderTargetProxy(const GrCaps& caps,
const GrSurfaceDesc& desc,
SkBackingFit fit,
- SkBudgeted budgeted)
- : GrSurfaceProxy(desc, fit, budgeted)
- , GrTextureProxy(desc, fit, budgeted, nullptr, 0) // 4 now textures w/ data are always wrapped
- , GrRenderTargetProxy(caps, desc, fit, budgeted) {
+ SkBudgeted budgeted,
+ uint32_t flags)
+ : GrSurfaceProxy(desc, fit, budgeted, flags)
+ // for now textures w/ data are always wrapped
+ , GrTextureProxy(desc, fit, budgeted, nullptr, 0, flags)
+ , GrRenderTargetProxy(caps, desc, fit, budgeted, flags) {
}
// Wrapped version
-// This class is virtually derived from GrSurfaceProxy (via both GrTextureProxy and
+// This class is virtually derived from GrSurfaceProxy (via both GrTextureProxy and
// GrRenderTargetProxy) so its constructor must be explicitly called.
GrTextureRenderTargetProxy::GrTextureRenderTargetProxy(sk_sp<GrSurface> surf)
: GrSurfaceProxy(surf, SkBackingFit::kExact)