Index: include/gpu/GrTextureProvider.h |
diff --git a/include/gpu/GrTextureProvider.h b/include/gpu/GrTextureProvider.h |
index 338dddbaca87f0a87c89c29129afad0ae3fadac4..f943da33667c998aef69e98ac0d4ca5b09716391 100644 |
--- a/include/gpu/GrTextureProvider.h |
+++ b/include/gpu/GrTextureProvider.h |
@@ -98,10 +98,19 @@ public: |
* the client will resolve to a texture). Currently wrapped render targets |
* always use the kBorrow_GrWrapOwnership semantics. |
* |
- * @return GrTexture object or NULL on failure. |
+ * @return GrRenderTarget object or NULL on failure. |
*/ |
GrRenderTarget* wrapBackendRenderTarget(const GrBackendRenderTargetDesc& desc); |
+ /** |
+ * Wraps an existing texture with a GrRenderTarget object. This is useful when the provided |
+ * texture has a format that cannot be textured from by Skia, but we want to raster to it. |
+ * |
+ * @return GrRenderTarget object or NULL on failure. |
+ */ |
+ GrRenderTarget* wrapBackendTextureAsRenderTarget(const GrBackendTextureDesc& desc, |
bsalomon
2016/02/22 16:41:01
Can we put this in GrResourceProvider (it's a deri
ericrk
2016/02/22 21:02:59
I was planning on calling this directly from Chrom
bsalomon
2016/02/23 02:25:27
Gotcha, what if we added a prepareForExternalIO (o
ericrk
2016/02/24 00:39:53
Added this function.
|
+ GrWrapOwnership = kBorrow_GrWrapOwnership); |
+ |
protected: |
GrTextureProvider(GrGpu* gpu, GrResourceCache* cache, GrSingleOwner* singleOwner); |