aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/SkGr.h
diff options
context:
space:
mode:
authorGravatar Greg Daniel <egdaniel@google.com>2017-09-29 09:32:44 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-09-29 14:08:04 +0000
commit55afd6dcee62b403ab888bb8a333c538a79041d3 (patch)
tree0926f4ef773d9a65b89e1d19b28beb186f54ba53 /src/gpu/SkGr.h
parent135db05fa114f0fc545c53f3047990c027cec9f6 (diff)
Revert "Revert "Update GrBitmapTextureMaker for handling mipped requests""
This reverts commit 8b059bd946d9f14607f6d2e8b966267dd8e5a54d. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Update GrBitmapTextureMaker for handling mipped requests" > > This reverts commit d1935c16e889b6707a522f711e79c75353caa343. > > Reason for revert: breaking lots of GMs, especially on gles > > Original change's description: > > Update GrBitmapTextureMaker for handling mipped requests > > > > Specifically this updates the case when we are requesting to use mip > > maps but there is already an unmipped version in the cache. Previously > > we just grabbed the unmipped. > > > > Now we will create a new mipped resource. Upload the cpu data to all > > the levels besides the base, copy the base level on GPU from the > > original resource to the mipped one. Then the mipped resource will > > take over the originals unique key. > > > > Bug: skia: > > Change-Id: I38e9725c93280dc2460a0be8a7a229e7f20e1614 > > Reviewed-on: https://skia-review.googlesource.com/43840 > > Commit-Queue: Greg Daniel <egdaniel@google.com> > > Reviewed-by: Robert Phillips <robertphillips@google.com> > > TBR=egdaniel@google.com,robertphillips@google.com,brianosman@google.com > > Change-Id: Id82e8b6e8ab69e46ff018bb07ae5d1f6ea8d7e76 > No-Presubmit: true > No-Tree-Checks: true > No-Try: true > Bug: skia: > Reviewed-on: https://skia-review.googlesource.com/52901 > Reviewed-by: Greg Daniel <egdaniel@google.com> > Commit-Queue: Greg Daniel <egdaniel@google.com> TBR=egdaniel@google.com,robertphillips@google.com,brianosman@google.com Bug: skia: Change-Id: Ie5b9553aa67def6f9c5a61f9b6b065b9fce3ff76 Reviewed-on: https://skia-review.googlesource.com/53240 Reviewed-by: Brian Osman <brianosman@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
Diffstat (limited to 'src/gpu/SkGr.h')
-rw-r--r--src/gpu/SkGr.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/gpu/SkGr.h b/src/gpu/SkGr.h
index 7ecec96477..20110a516f 100644
--- a/src/gpu/SkGr.h
+++ b/src/gpu/SkGr.h
@@ -225,6 +225,13 @@ sk_sp<GrTextureProxy> GrUploadPixmapToTextureProxy(GrResourceProvider*,
const SkPixmap&, SkBudgeted, SkColorSpace*);
/**
+ * Creates a new texture with mipmap levels and copies the baseProxy into the base layer.
+ */
+sk_sp<GrTextureProxy> GrCopyBaseMipMapToTextureProxy(GrContext*,
+ GrTextureProxy* baseProxy,
+ SkColorSpace* dstColorSpace);
+
+/**
* Creates a new texture populated with the mipmap levels.
*/
sk_sp<GrTextureProxy> GrUploadMipMapToTextureProxy(GrContext*, const SkImageInfo&,