diff options
author | 2016-05-17 09:57:46 -0700 | |
---|---|---|
committer | 2016-05-17 09:57:46 -0700 | |
commit | ca6eafc0f7e59ed89f03a9891b9fdf7de64f1f35 (patch) | |
tree | 06a052b8018ae4fb6ccbac647d2a4f77cc3a99d1 /src/gpu/GrContext.cpp | |
parent | cc49e5950d3a0de03c24da71d23bbdaebead97c6 (diff) |
(Mostly) Retract GrRenderTarget from SkGpuDevice
This gets us most of the way to having SkGpuDevice exclusively use a GrDrawContext instead of a GrRenderTarget. There are a few other refactorings (e.g., rm need for fLegacyBitmap and accessRenderTarget) before the GrRenderTarget can be completely removed.
Has calved off:
https://codereview.chromium.org/1925313002/ (Tighten up SkSpecialSurface factory functions)
https://codereview.chromium.org/1925803004/ (Add sk_sp to SkSurface_Gpu and SkGpuDevice)
https://codereview.chromium.org/1956473002/ (Retract GrRenderTarget a bit within SkGpuDevice)
https://codereview.chromium.org/1979913002/ (Rename GrDrawingMgr::abandon to wasAbandoned & add a matching entry point to GrDrawingContext)
https://codereview.chromium.org/1982583002/ (Add isUnifiedMultisampled entry point to GrDrawContext)
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1930013002
Review-Url: https://codereview.chromium.org/1930013002
Diffstat (limited to 'src/gpu/GrContext.cpp')
-rw-r--r-- | src/gpu/GrContext.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gpu/GrContext.cpp b/src/gpu/GrContext.cpp index 9f5d7bde0b..04fabaa6b3 100644 --- a/src/gpu/GrContext.cpp +++ b/src/gpu/GrContext.cpp @@ -656,7 +656,8 @@ sk_sp<GrDrawContext> GrContext::newDrawContext(SkBackingFit fit, GrPixelConfig config, int sampleCnt, GrSurfaceOrigin origin, - const SkSurfaceProps* surfaceProps) { + const SkSurfaceProps* surfaceProps, + SkBudgeted budgeted) { GrSurfaceDesc desc; desc.fFlags = kRenderTarget_GrSurfaceFlag; desc.fOrigin = origin; @@ -667,7 +668,7 @@ sk_sp<GrDrawContext> GrContext::newDrawContext(SkBackingFit fit, sk_sp<GrTexture> tex; if (SkBackingFit::kExact == fit) { - tex.reset(this->textureProvider()->createTexture(desc, SkBudgeted::kYes)); + tex.reset(this->textureProvider()->createTexture(desc, budgeted)); } else { tex.reset(this->textureProvider()->createApproxTexture(desc)); } |