From: Herb Derby Date: Thu, 9 Feb 2017 17:24:55 +0000 (-0500) Subject: Remove last use of ktx.h X-Git-Tag: accepted/tizen/5.0/unified/20181102.025319~55^2~415 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=cf1bff945b70bdcbe9243c22760d4e1fee4523cb;p=platform%2Fupstream%2FlibSkiaSharp.git Remove last use of ktx.h If this breaks something in Google3, revert it. Change-Id: Id719a87b6ca95c41d06f44f05ee1fdd430d4e0a2 Reviewed-on: https://skia-review.googlesource.com/8262 Commit-Queue: Herb Derby Reviewed-by: Robert Phillips Reviewed-by: Leon Scroggins Reviewed-by: Matt Sarett --- diff --git a/src/gpu/SkGr.cpp b/src/gpu/SkGr.cpp index 0dbe577..14379d5 100644 --- a/src/gpu/SkGr.cpp +++ b/src/gpu/SkGr.cpp @@ -39,7 +39,6 @@ #include "effects/GrXfermodeFragmentProcessor.h" #ifndef SK_IGNORE_ETC1_SUPPORT -# include "ktx.h" # include "etc1.h" #endif @@ -87,22 +86,6 @@ GrPixelConfig GrIsCompressedTextureDataSupported(GrContext* ctx, SkData* data, *outStartOfDataToUpload = bytes + ETC_PKM_HEADER_SIZE; return kETC1_GrPixelConfig; - } else if (SkKTXFile::is_ktx(bytes, data->size())) { - SkKTXFile ktx(data); - - // Is it actually an ETC1 texture? - if (!ktx.isCompressedFormat(SkTextureCompressor::kETC1_Format)) { - return kUnknown_GrPixelConfig; - } - - // Does the data match the dimensions of the bitmap? If not, - // then we don't know how to scale the image to match it... - if (ktx.width() != expectedW || ktx.height() != expectedH) { - return kUnknown_GrPixelConfig; - } - - *outStartOfDataToUpload = ktx.pixelData(); - return kETC1_GrPixelConfig; } #endif return kUnknown_GrPixelConfig;