From c74dad6f1850ebed53b07366380724bd63fadf4f Mon Sep 17 00:00:00 2001 From: Brian Osman Date: Thu, 12 Jan 2017 17:18:22 -0500 Subject: Remove spurious checks for sRGB float data We don't support this. F16 or F32 textures must be built with a linear transfer function, if any. BUG=skia: Change-Id: Ia8d83a03d12ddc3b70f5d7e4fabed72f6c2af538 Reviewed-on: https://skia-review.googlesource.com/6978 Reviewed-by: Robert Phillips Reviewed-by: Matt Sarett Reviewed-by: Brian Salomon --- src/gpu/SkGr.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src') diff --git a/src/gpu/SkGr.cpp b/src/gpu/SkGr.cpp index 5c937d40e8..eec3cd70d2 100644 --- a/src/gpu/SkGr.cpp +++ b/src/gpu/SkGr.cpp @@ -177,9 +177,7 @@ GrTexture* GrUploadPixmapToTexture(GrContext* ctx, const SkPixmap& pixmap, SkBud if (caps->srgbSupport() && pixmap.info().colorSpace() && pixmap.info().colorSpace()->gammaCloseToSRGB() && - !(GrPixelConfigIsSRGB(desc.fConfig) || - kRGBA_half_GrPixelConfig == desc.fConfig || - kRGBA_float_GrPixelConfig == desc.fConfig)) { + !GrPixelConfigIsSRGB(desc.fConfig)) { // We were supplied an sRGB-like color space, but we don't have a suitable pixel config. // Convert to 8888 sRGB so we can handle the data correctly. The raster backend doesn't // handle sRGB Index8 -> sRGB 8888 correctly (yet), so lie about both the source and -- cgit v1.2.3