Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1216)

Unified Diff: src/gpu/SkGr.cpp

Issue 559093003: Revert of Added test for non cached ETC1 (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gm/etc1bitmap.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/SkGr.cpp
diff --git a/src/gpu/SkGr.cpp b/src/gpu/SkGr.cpp
index cdbdc41c858d02c9fdcb108cb02bdf25731a1726..73773b00d144c532b802af8b99d1e91f991d70d2 100644
--- a/src/gpu/SkGr.cpp
+++ b/src/gpu/SkGr.cpp
@@ -139,7 +139,7 @@
bool cache,
const GrTextureParams* params,
const SkBitmap& bm,
- const GrTextureDesc& desc,
+ GrTextureDesc desc,
const void* pixels,
size_t rowBytes) {
GrTexture* result;
@@ -322,9 +322,12 @@
// Is this an ETC1 encoded texture?
#ifndef SK_IGNORE_ETC1_SUPPORT
else if (
+ // We do not support scratch ETC1 textures, hence they should all be at least
+ // trying to go to the cache.
+ cache
// Make sure that the underlying device supports ETC1 textures before we go ahead
// and check the data.
- ctx->getGpu()->caps()->isConfigTexturable(kETC1_GrPixelConfig)
+ && ctx->getGpu()->caps()->isConfigTexturable(kETC1_GrPixelConfig)
// If the bitmap had compressed data and was then uncompressed, it'll still return
// compressed data on 'refEncodedData' and upload it. Probably not good, since if
// the bitmap has available pixels, then they might not be what the decompressed
« no previous file with comments | « gm/etc1bitmap.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698