diff options
author | Greg Daniel <egdaniel@google.com> | 2018-11-06 09:31:08 -0700 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2018-11-08 19:44:55 +0000 |
commit | 51b1c12bbc2fa3f8d4faa29ad19c6f3cb34837ce (patch) | |
tree | 1434c94506b420bb31c3a93b7ea7ef62d117a035 /samplecode | |
parent | 885f10787b2f57a91edac8c39ca2c1861dd25a9e (diff) | |
download | skqp-51b1c12bbc2fa3f8d4faa29ad19c6f3cb34837ce.tar.gz |
Have a GrBackendFormat be stored on gpu proxies.
Bug: skia:
Change-Id: Iaf1fb24ab29a61d44e5fa59a5e0867ed02dcda90
Reviewed-on: https://skia-review.googlesource.com/c/168021
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
Diffstat (limited to 'samplecode')
-rw-r--r-- | samplecode/SampleCCPRGeometry.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/samplecode/SampleCCPRGeometry.cpp b/samplecode/SampleCCPRGeometry.cpp index f234951a10..426962a874 100644 --- a/samplecode/SampleCCPRGeometry.cpp +++ b/samplecode/SampleCCPRGeometry.cpp @@ -182,8 +182,11 @@ void CCPRGeometryView::onDrawContent(SkCanvas* canvas) { GrOpMemoryPool* pool = ctx->contextPriv().opMemoryPool(); + const GrBackendFormat format = + ctx->contextPriv().caps()->getBackendFormatFromGrColorType(GrColorType::kAlpha_F16, + GrSRGBEncoded::kNo); sk_sp<GrRenderTargetContext> ccbuff = - ctx->contextPriv().makeDeferredRenderTargetContext(SkBackingFit::kApprox, + ctx->contextPriv().makeDeferredRenderTargetContext(format, SkBackingFit::kApprox, this->width(), this->height(), kAlpha_half_GrPixelConfig, nullptr); |