From ded47a50143470d1acdafa03e878cc7da5608038 Mon Sep 17 00:00:00 2001 From: Brian Osman Date: Thu, 1 Mar 2018 20:10:11 +0000 Subject: [PATCH] Revert "Add 1010102 support to Ganesh" This reverts commit 44b61204d9f5681b9474db017577d56f42a32d66. Reason for revert: TSAN bot crashing Original change's description: > Add 1010102 support to Ganesh > > Adds gl1010102, gles1010102, vk1010102, and mtl1010102 > configs to DM. > > This uses the same saveLayer approach as CPU, switching > to 8888 so that we have enough alpha precision. > > Change-Id: I9f5b63747ec01031c8db97dadfc42f77e4863ccb > Reviewed-on: https://skia-review.googlesource.com/110500 > Reviewed-by: Brian Salomon > Commit-Queue: Brian Osman TBR=mtklein@google.com,bsalomon@google.com,brianosman@google.com Change-Id: I782e740763044c1ae78fb219161e37eec7617c74 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://skia-review.googlesource.com/111580 Reviewed-by: Brian Osman Commit-Queue: Brian Osman --- include/gpu/GrTypes.h | 5 -- include/private/GrTypesPriv.h | 87 ++++++++----------- ...P400-x86_64-Debug-All-Vulkan_Coverage.json | 1 - ..._AbandonGpuContext_SK_CPU_LIMIT_SSE41.json | 1 - ...eAbandonGpuContext_SK_CPU_LIMIT_SSE41.json | 1 - ...lease-All-Valgrind_SK_CPU_LIMIT_SSE41.json | 1 - infra/bots/recipes/test.py | 7 -- src/core/SkCanvas.cpp | 2 - src/core/SkGpuBlurUtils.cpp | 3 +- src/gpu/GrCaps.cpp | 1 - src/gpu/GrContext.cpp | 25 +++--- src/gpu/SkGpuDevice.cpp | 10 +-- src/gpu/SkGr.cpp | 5 +- src/gpu/effects/GrDitherEffect.fp | 1 - src/gpu/effects/GrDitherEffect.h | 1 - src/gpu/gl/GrGLCaps.cpp | 24 +---- src/gpu/gl/GrGLDefines.h | 2 - src/gpu/gl/GrGLGpu.cpp | 1 - src/gpu/gl/GrGLUtil.cpp | 2 - src/gpu/mtl/GrMtlUtil.mm | 7 +- src/gpu/vk/GrVkCaps.cpp | 5 +- src/gpu/vk/GrVkUtil.cpp | 8 -- tests/GrSurfaceTest.cpp | 1 - tests/ImageGeneratorTest.cpp | 2 - tests/ProxyTest.cpp | 5 +- tests/ReadWriteAlphaTest.cpp | 15 +--- tests/SpecialSurfaceTest.cpp | 15 ++-- tests/SurfaceTest.cpp | 14 +-- tests/TestConfigParsing.cpp | 6 +- tools/flags/SkCommonFlagsConfig.cpp | 9 -- 30 files changed, 69 insertions(+), 198 deletions(-) diff --git a/include/gpu/GrTypes.h b/include/gpu/GrTypes.h index ef7426cbba..c88d9ee63b 100644 --- a/include/gpu/GrTypes.h +++ b/include/gpu/GrTypes.h @@ -314,11 +314,6 @@ enum GrPixelConfig { */ kSBGRA_8888_GrPixelConfig, - /** - * Premultiplied. - */ - kRGBA_1010102_GrPixelConfig, - /** * Byte order is r, g, b, a. This color format is 32 bits per channel */ diff --git a/include/private/GrTypesPriv.h b/include/private/GrTypesPriv.h index c7a7296639..1c28c400d0 100644 --- a/include/private/GrTypesPriv.h +++ b/include/private/GrTypesPriv.h @@ -797,7 +797,6 @@ static inline GrSRGBEncoded GrPixelConfigIsSRGBEncoded(GrPixelConfig config) { case kRGBA_4444_GrPixelConfig: case kRGBA_8888_GrPixelConfig: case kBGRA_8888_GrPixelConfig: - case kRGBA_1010102_GrPixelConfig: case kRGBA_float_GrPixelConfig: case kRG_float_GrPixelConfig: case kAlpha_half_GrPixelConfig: @@ -833,7 +832,6 @@ static inline GrPixelConfig GrPixelConfigSwapRAndB(GrPixelConfig config) { case kGray_8_as_Red_GrPixelConfig: case kRGB_565_GrPixelConfig: case kRGBA_4444_GrPixelConfig: - case kRGBA_1010102_GrPixelConfig: case kRGBA_float_GrPixelConfig: case kRG_float_GrPixelConfig: case kAlpha_half_GrPixelConfig: @@ -863,7 +861,6 @@ static inline size_t GrBytesPerPixel(GrPixelConfig config) { case kBGRA_8888_GrPixelConfig: case kSRGBA_8888_GrPixelConfig: case kSBGRA_8888_GrPixelConfig: - case kRGBA_1010102_GrPixelConfig: return 4; case kRGBA_half_GrPixelConfig: return 8; @@ -896,7 +893,6 @@ static inline bool GrPixelConfigIsOpaque(GrPixelConfig config) { case kBGRA_8888_GrPixelConfig: case kSRGBA_8888_GrPixelConfig: case kSBGRA_8888_GrPixelConfig: - case kRGBA_1010102_GrPixelConfig: case kRGBA_half_GrPixelConfig: case kRGBA_float_GrPixelConfig: case kUnknown_GrPixelConfig: @@ -924,7 +920,6 @@ static inline bool GrPixelConfigIsAlphaOnly(GrPixelConfig config) { case kBGRA_8888_GrPixelConfig: case kSRGBA_8888_GrPixelConfig: case kSBGRA_8888_GrPixelConfig: - case kRGBA_1010102_GrPixelConfig: case kRGBA_float_GrPixelConfig: case kRG_float_GrPixelConfig: case kRGBA_half_GrPixelConfig: @@ -955,7 +950,6 @@ static inline bool GrPixelConfigIsFloatingPoint(GrPixelConfig config) { case kBGRA_8888_GrPixelConfig: case kSRGBA_8888_GrPixelConfig: case kSBGRA_8888_GrPixelConfig: - case kRGBA_1010102_GrPixelConfig: return false; } SK_ABORT("Invalid pixel config"); @@ -976,7 +970,6 @@ static inline bool GrPixelConfigIsUnorm(GrPixelConfig config) { case kBGRA_8888_GrPixelConfig: case kSRGBA_8888_GrPixelConfig: case kSBGRA_8888_GrPixelConfig: - case kRGBA_1010102_GrPixelConfig: return true; case kUnknown_GrPixelConfig: case kAlpha_half_GrPixelConfig: @@ -1015,7 +1008,6 @@ static inline GrSLPrecision GrSLSamplerPrecision(GrPixelConfig config) { case kAlpha_half_GrPixelConfig: case kAlpha_half_as_Red_GrPixelConfig: case kRGBA_half_GrPixelConfig: - case kRGBA_1010102_GrPixelConfig: return kMedium_GrSLPrecision; } SK_ABORT("Unexpected type"); @@ -1041,7 +1033,6 @@ enum class GrColorType { kABGR_4444, // This name differs from SkColorType. kARGB_4444_SkColorType is misnamed. kRGBA_8888, kBGRA_8888, - kRGBA_1010102, kGray_8, kAlpha_F16, kRGBA_F16, @@ -1051,18 +1042,17 @@ enum class GrColorType { static inline SkColorType GrColorTypeToSkColorType(GrColorType ct) { switch (ct) { - case GrColorType::kUnknown: return kUnknown_SkColorType; - case GrColorType::kAlpha_8: return kAlpha_8_SkColorType; - case GrColorType::kRGB_565: return kRGB_565_SkColorType; - case GrColorType::kABGR_4444: return kARGB_4444_SkColorType; - case GrColorType::kRGBA_8888: return kRGBA_8888_SkColorType; - case GrColorType::kBGRA_8888: return kBGRA_8888_SkColorType; - case GrColorType::kRGBA_1010102: return kRGBA_1010102_SkColorType; - case GrColorType::kGray_8: return kGray_8_SkColorType; - case GrColorType::kAlpha_F16: return kUnknown_SkColorType; - case GrColorType::kRGBA_F16: return kRGBA_F16_SkColorType; - case GrColorType::kRG_F32: return kUnknown_SkColorType; - case GrColorType::kRGBA_F32: return kUnknown_SkColorType; + case GrColorType::kUnknown: return kUnknown_SkColorType; + case GrColorType::kAlpha_8: return kAlpha_8_SkColorType; + case GrColorType::kRGB_565: return kRGB_565_SkColorType; + case GrColorType::kABGR_4444: return kARGB_4444_SkColorType; + case GrColorType::kRGBA_8888: return kRGBA_8888_SkColorType; + case GrColorType::kBGRA_8888: return kBGRA_8888_SkColorType; + case GrColorType::kGray_8: return kGray_8_SkColorType; + case GrColorType::kAlpha_F16: return kUnknown_SkColorType; + case GrColorType::kRGBA_F16: return kRGBA_F16_SkColorType; + case GrColorType::kRG_F32: return kUnknown_SkColorType; + case GrColorType::kRGBA_F32: return kUnknown_SkColorType; } SK_ABORT("Invalid GrColorType"); return kUnknown_SkColorType; @@ -1079,7 +1069,7 @@ static inline GrColorType SkColorTypeToGrColorType(SkColorType ct) { case kRGB_888x_SkColorType: return GrColorType::kUnknown; case kGray_8_SkColorType: return GrColorType::kGray_8; case kRGBA_F16_SkColorType: return GrColorType::kRGBA_F16; - case kRGBA_1010102_SkColorType: return GrColorType::kRGBA_1010102; + case kRGBA_1010102_SkColorType: return GrColorType::kUnknown; case kRGB_101010x_SkColorType: return GrColorType::kUnknown; } SK_ABORT("Invalid SkColorType"); @@ -1088,18 +1078,17 @@ static inline GrColorType SkColorTypeToGrColorType(SkColorType ct) { static inline int GrColorTypeBytesPerPixel(GrColorType ct) { switch (ct) { - case GrColorType::kUnknown: return 0; - case GrColorType::kAlpha_8: return 1; - case GrColorType::kRGB_565: return 2; - case GrColorType::kABGR_4444: return 2; - case GrColorType::kRGBA_8888: return 4; - case GrColorType::kBGRA_8888: return 4; - case GrColorType::kRGBA_1010102: return 4; - case GrColorType::kGray_8: return 1; - case GrColorType::kAlpha_F16: return 2; - case GrColorType::kRGBA_F16: return 8; - case GrColorType::kRG_F32: return 8; - case GrColorType::kRGBA_F32: return 16; + case GrColorType::kUnknown: return 0; + case GrColorType::kAlpha_8: return 1; + case GrColorType::kRGB_565: return 2; + case GrColorType::kABGR_4444: return 2; + case GrColorType::kRGBA_8888: return 4; + case GrColorType::kBGRA_8888: return 4; + case GrColorType::kGray_8: return 1; + case GrColorType::kAlpha_F16: return 2; + case GrColorType::kRGBA_F16: return 8; + case GrColorType::kRG_F32: return 8; + case GrColorType::kRGBA_F32: return 16; } SK_ABORT("Invalid GrColorType"); return 0; @@ -1107,18 +1096,17 @@ static inline int GrColorTypeBytesPerPixel(GrColorType ct) { static inline int GrColorTypeIsAlphaOnly(GrColorType ct) { switch (ct) { - case GrColorType::kUnknown: return false; - case GrColorType::kAlpha_8: return true; - case GrColorType::kRGB_565: return false; - case GrColorType::kABGR_4444: return false; - case GrColorType::kRGBA_8888: return false; - case GrColorType::kBGRA_8888: return false; - case GrColorType::kRGBA_1010102: return false; - case GrColorType::kGray_8: return false; - case GrColorType::kAlpha_F16: return true; - case GrColorType::kRGBA_F16: return false; - case GrColorType::kRG_F32: return false; - case GrColorType::kRGBA_F32: return false; + case GrColorType::kUnknown: return false; + case GrColorType::kAlpha_8: return true; + case GrColorType::kRGB_565: return false; + case GrColorType::kABGR_4444: return false; + case GrColorType::kRGBA_8888: return false; + case GrColorType::kBGRA_8888: return false; + case GrColorType::kGray_8: return false; + case GrColorType::kAlpha_F16: return true; + case GrColorType::kRGBA_F16: return false; + case GrColorType::kRG_F32: return false; + case GrColorType::kRGBA_F32: return false; } SK_ABORT("Invalid GrColorType"); return false; @@ -1154,9 +1142,6 @@ static inline GrColorType GrPixelConfigToColorTypeAndEncoding(GrPixelConfig conf case kSBGRA_8888_GrPixelConfig: *srgbEncoded = GrSRGBEncoded::kYes; return GrColorType::kBGRA_8888; - case kRGBA_1010102_GrPixelConfig: - *srgbEncoded = GrSRGBEncoded::kNo; - return GrColorType::kRGBA_1010102; case kRGBA_float_GrPixelConfig: *srgbEncoded = GrSRGBEncoded::kNo; return GrColorType::kRGBA_F32; @@ -1223,10 +1208,6 @@ static inline GrPixelConfig GrColorTypeToPixelConfig(GrColorType config, return (GrSRGBEncoded::kYes == srgbEncoded) ? kSBGRA_8888_GrPixelConfig : kBGRA_8888_GrPixelConfig; - case GrColorType::kRGBA_1010102: - return (GrSRGBEncoded::kYes == srgbEncoded) ? kUnknown_GrPixelConfig - : kRGBA_1010102_GrPixelConfig; - case GrColorType::kRGBA_F32: return (GrSRGBEncoded::kYes == srgbEncoded) ? kUnknown_GrPixelConfig : kRGBA_float_GrPixelConfig; diff --git a/infra/bots/recipes/test.expected/Test-Ubuntu17-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-Vulkan_Coverage.json b/infra/bots/recipes/test.expected/Test-Ubuntu17-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-Vulkan_Coverage.json index e6711e9c02..95092be02b 100644 --- a/infra/bots/recipes/test.expected/Test-Ubuntu17-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-Vulkan_Coverage.json +++ b/infra/bots/recipes/test.expected/Test-Ubuntu17-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-Vulkan_Coverage.json @@ -164,7 +164,6 @@ "--nocpu", "--config", "vk", - "vk1010102", "--src", "tests", "gm", diff --git a/infra/bots/recipes/test.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_AbandonGpuContext_SK_CPU_LIMIT_SSE41.json b/infra/bots/recipes/test.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_AbandonGpuContext_SK_CPU_LIMIT_SSE41.json index 38939f214e..6b351265b6 100644 --- a/infra/bots/recipes/test.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_AbandonGpuContext_SK_CPU_LIMIT_SSE41.json +++ b/infra/bots/recipes/test.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_AbandonGpuContext_SK_CPU_LIMIT_SSE41.json @@ -169,7 +169,6 @@ "gldft", "glsrgb", "glmsaa8", - "gl1010102", "--src", "tests", "gm", diff --git a/infra/bots/recipes/test.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_PreAbandonGpuContext_SK_CPU_LIMIT_SSE41.json b/infra/bots/recipes/test.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_PreAbandonGpuContext_SK_CPU_LIMIT_SSE41.json index 5eb98b88a1..cfff7ae3f4 100644 --- a/infra/bots/recipes/test.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_PreAbandonGpuContext_SK_CPU_LIMIT_SSE41.json +++ b/infra/bots/recipes/test.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_PreAbandonGpuContext_SK_CPU_LIMIT_SSE41.json @@ -169,7 +169,6 @@ "gldft", "glsrgb", "glmsaa8", - "gl1010102", "--src", "tests", "gm", diff --git a/infra/bots/recipes/test.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_SK_CPU_LIMIT_SSE41.json b/infra/bots/recipes/test.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_SK_CPU_LIMIT_SSE41.json index 0cf53f2028..4f0ad74cc1 100644 --- a/infra/bots/recipes/test.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_SK_CPU_LIMIT_SSE41.json +++ b/infra/bots/recipes/test.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_SK_CPU_LIMIT_SSE41.json @@ -169,7 +169,6 @@ "gldft", "glsrgb", "glmsaa8", - "gl1010102", "--src", "tests", "gm", diff --git a/infra/bots/recipes/test.py b/infra/bots/recipes/test.py index 5cc7c94434..4115043cb7 100644 --- a/infra/bots/recipes/test.py +++ b/infra/bots/recipes/test.py @@ -212,13 +212,6 @@ def dm_flags(api, bot): if 'Vulkan' in bot: configs = ['vk'] - # Test 1010102 on our Linux/NVIDIA bots - if 'QuadroP400' in bot and api.vars.is_linux: - if 'Vulkan' in bot: - configs.append('vk1010102') - else: - configs.append('gl1010102') - if 'ChromeOS' in bot: # Just run GLES for now - maybe add gles_msaa4 in the future configs = ['gles'] diff --git a/src/core/SkCanvas.cpp b/src/core/SkCanvas.cpp index 34b9d369ec..269fac6f31 100644 --- a/src/core/SkCanvas.cpp +++ b/src/core/SkCanvas.cpp @@ -2880,7 +2880,6 @@ int SkCanvas::LayerIter::y() const { return fImpl->getY(); } /////////////////////////////////////////////////////////////////////////////// -// TODO: This still disagrees with SkSurfaceValidateRasterInfo static bool supported_for_raster_canvas(const SkImageInfo& info) { switch (info.alphaType()) { case kPremul_SkAlphaType: @@ -2895,7 +2894,6 @@ static bool supported_for_raster_canvas(const SkImageInfo& info) { case kRGB_565_SkColorType: case kN32_SkColorType: case kRGBA_F16_SkColorType: - case kRGBA_1010102_SkColorType: break; default: return false; diff --git a/src/core/SkGpuBlurUtils.cpp b/src/core/SkGpuBlurUtils.cpp index 755e8daf70..7fa05454d0 100644 --- a/src/core/SkGpuBlurUtils.cpp +++ b/src/core/SkGpuBlurUtils.cpp @@ -235,8 +235,7 @@ sk_sp GaussianBlur(GrContext* context, SkASSERT(kBGRA_8888_GrPixelConfig == config || kRGBA_8888_GrPixelConfig == config || kRGBA_4444_GrPixelConfig == config || kRGB_565_GrPixelConfig == config || kSRGBA_8888_GrPixelConfig == config || kSBGRA_8888_GrPixelConfig == config || - kRGBA_half_GrPixelConfig == config || kAlpha_8_GrPixelConfig == config || - kRGBA_1010102_GrPixelConfig == config); + kRGBA_half_GrPixelConfig == config || kAlpha_8_GrPixelConfig == config); const int width = dstBounds.width(); const int height = dstBounds.height(); diff --git a/src/gpu/GrCaps.cpp b/src/gpu/GrCaps.cpp index 37c31001d1..8cfbc5faea 100644 --- a/src/gpu/GrCaps.cpp +++ b/src/gpu/GrCaps.cpp @@ -27,7 +27,6 @@ static const char* pixel_config_name(GrPixelConfig config) { case kBGRA_8888_GrPixelConfig: return "BGRA8888"; case kSRGBA_8888_GrPixelConfig: return "SRGBA8888"; case kSBGRA_8888_GrPixelConfig: return "SBGRA8888"; - case kRGBA_1010102_GrPixelConfig: return "RGBA1010102"; case kRGBA_float_GrPixelConfig: return "RGBAFloat"; case kRG_float_GrPixelConfig: return "RGFloat"; case kAlpha_half_GrPixelConfig: return "AlphaHalf"; diff --git a/src/gpu/GrContext.cpp b/src/gpu/GrContext.cpp index ee623678bf..7cca4a44ad 100644 --- a/src/gpu/GrContext.cpp +++ b/src/gpu/GrContext.cpp @@ -623,7 +623,6 @@ static bool valid_premul_config(GrPixelConfig config) { case kBGRA_8888_GrPixelConfig: return true; case kSRGBA_8888_GrPixelConfig: return true; case kSBGRA_8888_GrPixelConfig: return true; - case kRGBA_1010102_GrPixelConfig: return true; case kRGBA_float_GrPixelConfig: return true; case kRG_float_GrPixelConfig: return false; case kAlpha_half_GrPixelConfig: return false; @@ -640,18 +639,17 @@ static bool valid_premul_config(GrPixelConfig config) { static bool valid_premul_color_type(GrColorType ct) { switch (ct) { - case GrColorType::kUnknown: return false; - case GrColorType::kAlpha_8: return false; - case GrColorType::kRGB_565: return false; - case GrColorType::kABGR_4444: return true; - case GrColorType::kRGBA_8888: return true; - case GrColorType::kBGRA_8888: return true; - case GrColorType::kRGBA_1010102: return true; - case GrColorType::kGray_8: return false; - case GrColorType::kAlpha_F16: return false; - case GrColorType::kRGBA_F16: return true; - case GrColorType::kRG_F32: return false; - case GrColorType::kRGBA_F32: return true; + case GrColorType::kUnknown: return false; + case GrColorType::kAlpha_8: return false; + case GrColorType::kRGB_565: return false; + case GrColorType::kABGR_4444: return true; + case GrColorType::kRGBA_8888: return true; + case GrColorType::kBGRA_8888: return true; + case GrColorType::kGray_8: return false; + case GrColorType::kAlpha_F16: return false; + case GrColorType::kRGBA_F16: return true; + case GrColorType::kRG_F32: return false; + case GrColorType::kRGBA_F32: return true; } SK_ABORT("Invalid GrColorType"); return false; @@ -1316,7 +1314,6 @@ static inline GrPixelConfig GrPixelConfigFallback(GrPixelConfig config) { case kRGB_565_GrPixelConfig: case kRGBA_4444_GrPixelConfig: case kBGRA_8888_GrPixelConfig: - case kRGBA_1010102_GrPixelConfig: return kRGBA_8888_GrPixelConfig; case kSBGRA_8888_GrPixelConfig: return kSRGBA_8888_GrPixelConfig; diff --git a/src/gpu/SkGpuDevice.cpp b/src/gpu/SkGpuDevice.cpp index 2722292506..1a4538af72 100644 --- a/src/gpu/SkGpuDevice.cpp +++ b/src/gpu/SkGpuDevice.cpp @@ -1713,15 +1713,9 @@ SkBaseDevice* SkGpuDevice::onCreateDevice(const CreateInfo& cinfo, const SkPaint SkBackingFit fit = kNever_TileUsage == cinfo.fTileUsage ? SkBackingFit::kApprox : SkBackingFit::kExact; - GrPixelConfig config = fRenderTargetContext->colorSpaceInfo().config(); - if (kRGBA_1010102_GrPixelConfig == config) { - // If the original device is 1010102, fall back to 8888 so that we have a usable alpha - // channel in the layer. - config = kRGBA_8888_GrPixelConfig; - } - sk_sp rtc(fContext->makeDeferredRenderTargetContext( - fit, cinfo.fInfo.width(), cinfo.fInfo.height(), config, + fit, cinfo.fInfo.width(), cinfo.fInfo.height(), + fRenderTargetContext->colorSpaceInfo().config(), fRenderTargetContext->colorSpaceInfo().refColorSpace(), fRenderTargetContext->numStencilSamples(), GrMipMapped::kNo, kBottomLeft_GrSurfaceOrigin, &props)); diff --git a/src/gpu/SkGr.cpp b/src/gpu/SkGr.cpp index 095a867605..37e4c8f430 100644 --- a/src/gpu/SkGr.cpp +++ b/src/gpu/SkGr.cpp @@ -264,7 +264,7 @@ GrPixelConfig SkImageInfo2GrPixelConfig(const SkColorType type, SkColorSpace* cs return (caps.srgbSupport() && cs && cs->gammaCloseToSRGB()) ? kSBGRA_8888_GrPixelConfig : kBGRA_8888_GrPixelConfig; case kRGBA_1010102_SkColorType: - return kRGBA_1010102_GrPixelConfig; + return kUnknown_GrPixelConfig; case kRGB_101010x_SkColorType: return kUnknown_GrPixelConfig; case kGray_8_SkColorType: @@ -311,9 +311,6 @@ bool GrPixelConfigToColorType(GrPixelConfig config, SkColorType* ctOut) { case kSBGRA_8888_GrPixelConfig: ct = kBGRA_8888_SkColorType; break; - case kRGBA_1010102_GrPixelConfig: - ct = kRGBA_1010102_SkColorType; - break; case kRGBA_half_GrPixelConfig: ct = kRGBA_F16_SkColorType; break; diff --git a/src/gpu/effects/GrDitherEffect.fp b/src/gpu/effects/GrDitherEffect.fp index 7cf07da311..8ae323e089 100644 --- a/src/gpu/effects/GrDitherEffect.fp +++ b/src/gpu/effects/GrDitherEffect.fp @@ -28,7 +28,6 @@ layout(key) in int rangeType; rangeType = 2; break; case kUnknown_GrPixelConfig: - case kRGBA_1010102_GrPixelConfig: case kAlpha_half_GrPixelConfig: case kAlpha_half_as_Red_GrPixelConfig: case kRGBA_float_GrPixelConfig: diff --git a/src/gpu/effects/GrDitherEffect.h b/src/gpu/effects/GrDitherEffect.h index 2e650a68f4..c614982538 100644 --- a/src/gpu/effects/GrDitherEffect.h +++ b/src/gpu/effects/GrDitherEffect.h @@ -37,7 +37,6 @@ public: rangeType = 2; break; case kUnknown_GrPixelConfig: - case kRGBA_1010102_GrPixelConfig: case kAlpha_half_GrPixelConfig: case kAlpha_half_as_Red_GrPixelConfig: case kRGBA_float_GrPixelConfig: diff --git a/src/gpu/gl/GrGLCaps.cpp b/src/gpu/gl/GrGLCaps.cpp index 487b17d095..9068525148 100644 --- a/src/gpu/gl/GrGLCaps.cpp +++ b/src/gpu/gl/GrGLCaps.cpp @@ -1603,25 +1603,6 @@ void GrGLCaps::initConfigTable(const GrContextOptions& contextOptions, } fConfigTable[kRGBA_4444_GrPixelConfig].fSwizzle = GrSwizzle::RGBA(); - fConfigTable[kRGBA_1010102_GrPixelConfig].fFormats.fBaseInternalFormat = GR_GL_RGBA; - fConfigTable[kRGBA_1010102_GrPixelConfig].fFormats.fSizedInternalFormat = GR_GL_RGB10_A2; - fConfigTable[kRGBA_1010102_GrPixelConfig].fFormats.fExternalFormat[kOther_ExternalFormatUsage] = - GR_GL_RGBA; - fConfigTable[kRGBA_1010102_GrPixelConfig].fFormats.fExternalType = - GR_GL_UNSIGNED_INT_2_10_10_10_REV; - fConfigTable[kRGBA_1010102_GrPixelConfig].fFormatType = kNormalizedFixedPoint_FormatType; - if (kGL_GrGLStandard == standard || version >= GR_GL_VER(3, 0)) { - fConfigTable[kRGBA_1010102_GrPixelConfig].fFlags = ConfigInfo::kTextureable_Flag | - allRenderFlags; - } - if (texStorageSupported) { - fConfigTable[kRGBA_1010102_GrPixelConfig].fFlags |= ConfigInfo::kCanUseTexStorage_Flag; - } - if (texelBufferSupport) { - fConfigTable[kRGBA_1010102_GrPixelConfig].fFlags |= ConfigInfo::kCanUseWithTexelBuffer_Flag; - } - fConfigTable[kRGBA_1010102_GrPixelConfig].fSwizzle = GrSwizzle::RGBA(); - bool alpha8IsValidForGL = kGL_GrGLStandard == standard && (!fIsCoreProfile || version <= GR_GL_VER(3, 0)); @@ -2530,10 +2511,7 @@ bool validate_sized_format(GrGLenum format, SkColorType ct, GrPixelConfig* confi } break; case kRGBA_1010102_SkColorType: - if (GR_GL_RGB10_A2 == format) { - *config = kRGBA_1010102_GrPixelConfig; - } - break; + return false; case kRGB_101010x_SkColorType: return false; case kGray_8_SkColorType: diff --git a/src/gpu/gl/GrGLDefines.h b/src/gpu/gl/GrGLDefines.h index e5e74eb68e..9da060b412 100644 --- a/src/gpu/gl/GrGLDefines.h +++ b/src/gpu/gl/GrGLDefines.h @@ -508,7 +508,6 @@ #define GR_GL_RGBA4 0x8056 #define GR_GL_RGB5_A1 0x8057 #define GR_GL_RGBA8 0x8058 -#define GR_GL_RGB10_A2 0x8059 #define GR_GL_SRGB8_ALPHA8 0x8C43 #define GR_GL_RGBA16F 0x881A #define GR_GL_RGBA32F 0x8814 @@ -530,7 +529,6 @@ #define GR_GL_UNSIGNED_SHORT_4_4_4_4 0x8033 #define GR_GL_UNSIGNED_SHORT_5_5_5_1 0x8034 #define GR_GL_UNSIGNED_SHORT_5_6_5 0x8363 -#define GR_GL_UNSIGNED_INT_2_10_10_10_REV 0x8368 /* Shaders */ #define GR_GL_FRAGMENT_SHADER 0x8B30 diff --git a/src/gpu/gl/GrGLGpu.cpp b/src/gpu/gl/GrGLGpu.cpp index a571f5a81e..af7c4706d3 100644 --- a/src/gpu/gl/GrGLGpu.cpp +++ b/src/gpu/gl/GrGLGpu.cpp @@ -800,7 +800,6 @@ static inline GrGLint config_alignment(GrPixelConfig config) { case kBGRA_8888_GrPixelConfig: case kSRGBA_8888_GrPixelConfig: case kSBGRA_8888_GrPixelConfig: - case kRGBA_1010102_GrPixelConfig: case kRGBA_float_GrPixelConfig: case kRG_float_GrPixelConfig: return 4; diff --git a/src/gpu/gl/GrGLUtil.cpp b/src/gpu/gl/GrGLUtil.cpp index 6b44402c1b..791d9ecfcb 100644 --- a/src/gpu/gl/GrGLUtil.cpp +++ b/src/gpu/gl/GrGLUtil.cpp @@ -504,8 +504,6 @@ GrPixelConfig GrGLSizedFormatToPixelConfig(GrGLenum sizedFormat) { return kRGB_565_GrPixelConfig; case GR_GL_RGBA4: return kRGBA_4444_GrPixelConfig; - case GR_GL_RGB10_A2: - return kRGBA_1010102_GrPixelConfig; case GR_GL_LUMINANCE8: return kGray_8_GrPixelConfig; case GR_GL_RGBA32F: diff --git a/src/gpu/mtl/GrMtlUtil.mm b/src/gpu/mtl/GrMtlUtil.mm index 383cc98264..a188afe4ad 100644 --- a/src/gpu/mtl/GrMtlUtil.mm +++ b/src/gpu/mtl/GrMtlUtil.mm @@ -30,12 +30,9 @@ bool GrPixelConfigToMTLFormat(GrPixelConfig config, MTLPixelFormat* format) { case kSBGRA_8888_GrPixelConfig: *format = MTLPixelFormatBGRA8Unorm_sRGB; return true; - case kRGBA_1010102_GrPixelConfig: - *format = MTLPixelFormatRGB10A2Unorm; - return true; case kRGB_565_GrPixelConfig: #ifdef SK_BUILD_FOR_IOS - *format = MTLPixelFormatB5G6R5Unorm; + *format = MTLPixelFormatR5G6B5Unorm; return true; #else return false; @@ -87,8 +84,6 @@ GrPixelConfig GrMTLFormatToPixelConfig(MTLPixelFormat format) { return kSRGBA_8888_GrPixelConfig; case MTLPixelFormatBGRA8Unorm_sRGB: return kSBGRA_8888_GrPixelConfig; - case MTLPixelFormatRGB10A2Unorm: - return kRGBA_1010102_GrPixelConfig; #ifdef SK_BUILD_FOR_IOS case MTLPixelFormatB5G6R5Unorm: return kRGB_565_GrPixelConfig; diff --git a/src/gpu/vk/GrVkCaps.cpp b/src/gpu/vk/GrVkCaps.cpp index 40a0eb5e3f..649f68b61b 100644 --- a/src/gpu/vk/GrVkCaps.cpp +++ b/src/gpu/vk/GrVkCaps.cpp @@ -485,10 +485,7 @@ bool validate_image_info(VkFormat format, SkColorType ct, GrPixelConfig* config) } break; case kRGBA_1010102_SkColorType: - if (VK_FORMAT_A2B10G10R10_UNORM_PACK32 == format) { - *config = kRGBA_1010102_GrPixelConfig; - } - break; + return false; case kRGB_101010x_SkColorType: return false; case kGray_8_SkColorType: diff --git a/src/gpu/vk/GrVkUtil.cpp b/src/gpu/vk/GrVkUtil.cpp index 4f0acdb8f4..330a1de7a2 100644 --- a/src/gpu/vk/GrVkUtil.cpp +++ b/src/gpu/vk/GrVkUtil.cpp @@ -31,9 +31,6 @@ bool GrPixelConfigToVkFormat(GrPixelConfig config, VkFormat* format) { case kSBGRA_8888_GrPixelConfig: *format = VK_FORMAT_B8G8R8A8_SRGB; return true; - case kRGBA_1010102_GrPixelConfig: - *format = VK_FORMAT_A2B10G10R10_UNORM_PACK32; - return true; case kRGB_565_GrPixelConfig: *format = VK_FORMAT_R5G6B5_UNORM_PACK16; return true; @@ -82,8 +79,6 @@ GrPixelConfig GrVkFormatToPixelConfig(VkFormat format) { return kSRGBA_8888_GrPixelConfig; case VK_FORMAT_B8G8R8A8_SRGB: return kSBGRA_8888_GrPixelConfig; - case VK_FORMAT_A2B10G10R10_UNORM_PACK32: - return kRGBA_1010102_GrPixelConfig; case VK_FORMAT_R5G6B5_UNORM_PACK16: return kRGB_565_GrPixelConfig; break; @@ -116,8 +111,6 @@ bool GrVkFormatPixelConfigPairIsValid(VkFormat format, GrPixelConfig config) { return kSRGBA_8888_GrPixelConfig == config; case VK_FORMAT_B8G8R8A8_SRGB: return kSBGRA_8888_GrPixelConfig == config; - case VK_FORMAT_A2B10G10R10_UNORM_PACK32: - return kRGBA_1010102_GrPixelConfig == config; case VK_FORMAT_R5G6B5_UNORM_PACK16: return kRGB_565_GrPixelConfig == config; case VK_FORMAT_B4G4R4A4_UNORM_PACK16: @@ -150,7 +143,6 @@ bool GrVkFormatIsSupported(VkFormat format) { case VK_FORMAT_R8G8B8A8_SRGB: case VK_FORMAT_B8G8R8A8_SRGB: case VK_FORMAT_R8G8B8A8_SINT: - case VK_FORMAT_A2B10G10R10_UNORM_PACK32: case VK_FORMAT_R5G6B5_UNORM_PACK16: case VK_FORMAT_B4G4R4A4_UNORM_PACK16: case VK_FORMAT_R8_UNORM: diff --git a/tests/GrSurfaceTest.cpp b/tests/GrSurfaceTest.cpp index a645f99c3e..eb975852d1 100644 --- a/tests/GrSurfaceTest.cpp +++ b/tests/GrSurfaceTest.cpp @@ -92,7 +92,6 @@ DEF_GPUTEST_FOR_ALL_CONTEXTS(GrSurfaceRenderability, reporter, ctxInfo) { kBGRA_8888_GrPixelConfig, kSRGBA_8888_GrPixelConfig, kSBGRA_8888_GrPixelConfig, - kRGBA_1010102_GrPixelConfig, kRGBA_float_GrPixelConfig, kRG_float_GrPixelConfig, kAlpha_half_GrPixelConfig, diff --git a/tests/ImageGeneratorTest.cpp b/tests/ImageGeneratorTest.cpp index 574c8e8728..8a7f0decec 100644 --- a/tests/ImageGeneratorTest.cpp +++ b/tests/ImageGeneratorTest.cpp @@ -90,12 +90,10 @@ DEF_TEST(PictureImageGenerator, reporter) { { kRGBA_8888_SkColorType, kPremul_SkAlphaType, kRGBA_8888_SkColorType == kN32_SkColorType }, { kBGRA_8888_SkColorType, kPremul_SkAlphaType, kBGRA_8888_SkColorType == kN32_SkColorType }, { kRGBA_F16_SkColorType, kPremul_SkAlphaType, true }, - { kRGBA_1010102_SkColorType, kPremul_SkAlphaType, true }, { kRGBA_8888_SkColorType, kUnpremul_SkAlphaType, false }, { kBGRA_8888_SkColorType, kUnpremul_SkAlphaType, false }, { kRGBA_F16_SkColorType, kUnpremul_SkAlphaType, false }, - { kRGBA_1010102_SkColorType, kUnpremul_SkAlphaType, false }, }; auto colorspace = SkColorSpace::MakeSRGB(); diff --git a/tests/ProxyTest.cpp b/tests/ProxyTest.cpp index 6ad8199849..f48e2a090f 100644 --- a/tests/ProxyTest.cpp +++ b/tests/ProxyTest.cpp @@ -104,7 +104,7 @@ DEF_GPUTEST_FOR_RENDERING_CONTEXTS(DeferredProxyTest, reporter, ctxInfo) { for (auto origin : { kBottomLeft_GrSurfaceOrigin, kTopLeft_GrSurfaceOrigin }) { for (auto widthHeight : { 100, 128, 1048576 }) { for (auto config : { kAlpha_8_GrPixelConfig, kRGB_565_GrPixelConfig, - kRGBA_8888_GrPixelConfig, kRGBA_1010102_GrPixelConfig }) { + kRGBA_8888_GrPixelConfig }) { for (auto fit : { SkBackingFit::kExact, SkBackingFit::kApprox }) { for (auto budgeted : { SkBudgeted::kYes, SkBudgeted::kNo }) { for (auto numSamples : {1, 4, 16, 128}) { @@ -196,8 +196,7 @@ DEF_GPUTEST_FOR_RENDERING_CONTEXTS(WrappedProxyTest, reporter, ctxInfo) { return; } for (auto origin : { kBottomLeft_GrSurfaceOrigin, kTopLeft_GrSurfaceOrigin }) { - for (auto colorType : { kAlpha_8_SkColorType, kRGBA_8888_SkColorType, - kRGBA_1010102_SkColorType }) { + for (auto colorType : { kAlpha_8_SkColorType, kRGBA_8888_SkColorType }) { for (auto numSamples : {1, 4}) { GrPixelConfig config = SkImageInfo2GrPixelConfig(colorType, nullptr, caps); SkASSERT(kUnknown_GrPixelConfig != config); diff --git a/tests/ReadWriteAlphaTest.cpp b/tests/ReadWriteAlphaTest.cpp index ba1022c689..68a3ee0983 100644 --- a/tests/ReadWriteAlphaTest.cpp +++ b/tests/ReadWriteAlphaTest.cpp @@ -25,17 +25,11 @@ static const int X_SIZE = 13; static const int Y_SIZE = 13; static void validate_alpha_data(skiatest::Reporter* reporter, int w, int h, const uint8_t* actual, - size_t actualRowBytes, const uint8_t* expected, SkString extraMsg, - GrPixelConfig config) { + size_t actualRowBytes, const uint8_t* expected, SkString extraMsg) { for (int y = 0; y < h; ++y) { for (int x = 0; x < w; ++x) { uint8_t a = actual[y * actualRowBytes + x]; uint8_t e = expected[y * w + x]; - if (kRGBA_1010102_GrPixelConfig == config) { - // This config only preserves two bits of alpha - a >>= 6; - e >>= 6; - } if (e != a) { ERRORF(reporter, "Failed alpha readback. Expected: 0x%02x, Got: 0x%02x at (%d,%d), %s", @@ -105,7 +99,7 @@ DEF_GPUTEST_FOR_RENDERING_CONTEXTS(ReadWriteAlpha, reporter, ctxInfo) { SkString msg; msg.printf("rb:%d A8", SkToU32(rowBytes)); validate_alpha_data(reporter, X_SIZE, Y_SIZE, readback.get(), nonZeroRowBytes, - alphaData, msg, kAlpha_8_GrPixelConfig); + alphaData, msg); // Now try writing to a single channel surface (if we could create one). if (surf) { @@ -142,8 +136,7 @@ DEF_GPUTEST_FOR_RENDERING_CONTEXTS(ReadWriteAlpha, reporter, ctxInfo) { static const GrPixelConfig kRGBAConfigs[] { kRGBA_8888_GrPixelConfig, kBGRA_8888_GrPixelConfig, - kSRGBA_8888_GrPixelConfig, - kRGBA_1010102_GrPixelConfig, + kSRGBA_8888_GrPixelConfig }; for (int y = 0; y < Y_SIZE; ++y) { @@ -207,7 +200,7 @@ DEF_GPUTEST_FOR_RENDERING_CONTEXTS(ReadWriteAlpha, reporter, ctxInfo) { SkString msg; msg.printf("rt:%d, rb:%d 8888", rt, SkToU32(rowBytes)); validate_alpha_data(reporter, X_SIZE, Y_SIZE, readback.get(), nonZeroRowBytes, - alphaData, msg, config); + alphaData, msg); } } } diff --git a/tests/SpecialSurfaceTest.cpp b/tests/SpecialSurfaceTest.cpp index 40de08de85..a336cf669d 100644 --- a/tests/SpecialSurfaceTest.cpp +++ b/tests/SpecialSurfaceTest.cpp @@ -80,15 +80,12 @@ DEF_TEST(SpecialSurface_Raster2, reporter) { #if SK_SUPPORT_GPU DEF_GPUTEST_FOR_RENDERING_CONTEXTS(SpecialSurface_Gpu1, reporter, ctxInfo) { - for (auto config : { kRGBA_8888_GrPixelConfig, kRGBA_1010102_GrPixelConfig }) { - if (!ctxInfo.grContext()->caps()->isConfigRenderable(config)) { - continue; - } - sk_sp surf(SkSpecialSurface::MakeRenderTarget(ctxInfo.grContext(), - kSmallerSize, kSmallerSize, - config, nullptr)); - test_surface(surf, reporter, 0); - } + sk_sp surf(SkSpecialSurface::MakeRenderTarget(ctxInfo.grContext(), + kSmallerSize, kSmallerSize, + kRGBA_8888_GrPixelConfig, + nullptr)); + + test_surface(surf, reporter, 0); } #endif diff --git a/tests/SurfaceTest.cpp b/tests/SurfaceTest.cpp index 35b72a972e..ab91061094 100644 --- a/tests/SurfaceTest.cpp +++ b/tests/SurfaceTest.cpp @@ -932,7 +932,6 @@ static void test_surface_creation_and_snapshot_with_color_space( skiatest::Reporter* reporter, const char* prefix, bool f16Support, - bool supports1010102, std::function(const SkImageInfo&)> surfaceMaker) { auto srgbColorSpace = SkColorSpace::MakeSRGB(); @@ -961,7 +960,6 @@ static void test_surface_creation_and_snapshot_with_color_space( { kRGBA_F16_SkColorType, oddColorSpace, false, "F16-odd" }, { kRGB_565_SkColorType, srgbColorSpace, false, "565-srgb" }, { kAlpha_8_SkColorType, srgbColorSpace, false, "A8-srgb" }, - { kRGBA_1010102_SkColorType, nullptr, true, "1010102-nullptr" }, }; for (auto& testConfig : testConfigs) { @@ -972,8 +970,7 @@ static void test_surface_creation_and_snapshot_with_color_space( // For some GPU contexts (eg ANGLE), we don't have f16 support, so we should fail to create // any surface of that type: bool shouldWork = testConfig.fShouldWork && - (f16Support || kRGBA_F16_SkColorType != testConfig.fColorType) && - (supports1010102 || kRGBA_1010102_SkColorType != testConfig.fColorType); + (f16Support || kRGBA_F16_SkColorType != testConfig.fColorType); auto surface(surfaceMaker(info)); REPORTER_ASSERT(reporter, SkToBool(surface) == shouldWork, fullTestName.c_str()); @@ -993,8 +990,7 @@ DEF_TEST(SurfaceCreationWithColorSpace, reporter) { return SkSurface::MakeRaster(info); }; - test_surface_creation_and_snapshot_with_color_space(reporter, "raster", true, true, - surfaceMaker); + test_surface_creation_and_snapshot_with_color_space(reporter, "raster", true, surfaceMaker); } #if SK_SUPPORT_GPU @@ -1002,13 +998,11 @@ DEF_GPUTEST_FOR_RENDERING_CONTEXTS(SurfaceCreationWithColorSpace_Gpu, reporter, GrContext* context = ctxInfo.grContext(); bool f16Support = context->caps()->isConfigRenderable(kRGBA_half_GrPixelConfig); - bool supports1010102 = context->caps()->isConfigRenderable(kRGBA_1010102_GrPixelConfig); auto surfaceMaker = [context](const SkImageInfo& info) { return SkSurface::MakeRenderTarget(context, SkBudgeted::kNo, info); }; - test_surface_creation_and_snapshot_with_color_space(reporter, "gpu", f16Support, - supports1010102, surfaceMaker); + test_surface_creation_and_snapshot_with_color_space(reporter, "gpu", f16Support, surfaceMaker); std::vector backendTextures; auto wrappedSurfaceMaker = [ context, &backendTextures ](const SkImageInfo& info) { @@ -1034,7 +1028,7 @@ DEF_GPUTEST_FOR_RENDERING_CONTEXTS(SurfaceCreationWithColorSpace_Gpu, reporter, }; test_surface_creation_and_snapshot_with_color_space(reporter, "wrapped", f16Support, - supports1010102, wrappedSurfaceMaker); + wrappedSurfaceMaker); context->flush(); diff --git a/tests/TestConfigParsing.cpp b/tests/TestConfigParsing.cpp index 6ff1fd830f..ec69235ccc 100644 --- a/tests/TestConfigParsing.cpp +++ b/tests/TestConfigParsing.cpp @@ -110,8 +110,7 @@ DEF_TEST(ParseConfigs_DefaultConfigs, reporter) { "mtl", "gl4444", "gl565", - "gltestthreading", - "gl1010102", + "gltestthreading" }); SkCommandLineConfigArray configs; @@ -201,9 +200,6 @@ DEF_TEST(ParseConfigs_DefaultConfigs, reporter) { REPORTER_ASSERT(reporter, configs[35]->asConfigGpu()->getAlphaType() == kOpaque_SkAlphaType); REPORTER_ASSERT(reporter, configs[36]->asConfigGpu()); REPORTER_ASSERT(reporter, configs[36]->asConfigGpu()->getTestThreading()); - REPORTER_ASSERT(reporter, configs[37]->asConfigGpu()); - REPORTER_ASSERT(reporter, configs[37]->asConfigGpu()->getColorType() == - kRGBA_1010102_SkColorType); #endif } diff --git a/tools/flags/SkCommonFlagsConfig.cpp b/tools/flags/SkCommonFlagsConfig.cpp index 7ff6ce6849..f9988f8769 100644 --- a/tools/flags/SkCommonFlagsConfig.cpp +++ b/tools/flags/SkCommonFlagsConfig.cpp @@ -46,11 +46,9 @@ static const struct { { "gl4444", "gpu", "api=gl,color=4444" }, { "gl565", "gpu", "api=gl,color=565" }, { "glf16", "gpu", "api=gl,color=f16" }, - { "gl1010102", "gpu", "api=gl,color=1010102" }, { "glsrgb", "gpu", "api=gl,color=srgb" }, { "glsrgbnl", "gpu", "api=gl,color=srgbnl" }, { "glesf16", "gpu", "api=gles,color=f16" }, - { "gles1010102", "gpu", "api=gles,color=1010102" }, { "glessrgb", "gpu", "api=gles,color=srgb" }, { "glessrgbnl", "gpu", "api=gles,color=srgbnl" }, { "glsrgb", "gpu", "api=gl,color=srgb" }, @@ -79,7 +77,6 @@ static const struct { { "mock", "gpu", "api=mock" } #ifdef SK_VULKAN ,{ "vk", "gpu", "api=vulkan" } - ,{ "vk1010102", "gpu", "api=vulkan,color=1010102" } ,{ "vksrgb", "gpu", "api=vulkan,color=srgb" } ,{ "vkwide", "gpu", "api=vulkan,color=f16_wide" } ,{ "vkmsaa4", "gpu", "api=vulkan,samples=4" } @@ -87,7 +84,6 @@ static const struct { #endif #ifdef SK_METAL ,{ "mtl", "gpu", "api=metal" } - ,{ "mtl1010102", "gpu", "api=metal,color=1010102" } ,{ "mtlsrgb", "gpu", "api=metal,color=srgb" } ,{ "mtlwide", "gpu", "api=metal,color=f16_wide" } ,{ "mtlmsaa4", "gpu", "api=metal,samples=4" } @@ -144,7 +140,6 @@ static const char configExtendedHelp[] = "\t\t4444\t\t\tLinear 4444.\n" "\t\t565\t\t\tLinear 565.\n" "\t\tf16{_gamut}\t\tLinear 16-bit floating point.\n" - "\t\t1010102\t\tLinear 1010102.\n" "\t\tsrgb{_gamut}\t\tsRGB 8888.\n" "\t gamut\ttype: string\tdefault: srgb.\n" "\t Select color gamut for f16 or sRGB format buffers.\n" @@ -326,10 +321,6 @@ static bool parse_option_gpu_color(const SkString& value, *alphaType = kOpaque_SkAlphaType; *outColorSpace = nullptr; return true; - } else if (value.equals("1010102")) { - *outColorType = kRGBA_1010102_SkColorType; - *outColorSpace = nullptr; - return true; } SkTArray commands;