Add support for Mtl backend to DeferredDisplayListTest

Change-Id: Ie576bc8442e5a646c33191100be1be5f89d72290
Reviewed-on: https://skia-review.googlesource.com/c/189483
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
This commit is contained in:
Robert Phillips 2019-02-06 16:04:34 -05:00 committed by Skia Commit-Bot
parent 500133b1e2
commit c1bee13e13
4 changed files with 5 additions and 6 deletions

View File

@ -487,8 +487,6 @@
".SRW",
"--match",
"~^ClearOp$",
"~^DDLSurfaceCharacterizationTest$",
"~^DDLNonTextureabilityTest$",
"~^DDLOperatorEqTest$",
"~^DeferredProxyTest$",
"~^GPUMemorySize$",

View File

@ -756,8 +756,6 @@ def dm_flags(api, bot):
if 'Metal' in bot:
# skia:8243
match.append('~^ClearOp$')
match.append('~^DDLSurfaceCharacterizationTest$')
match.append('~^DDLNonTextureabilityTest$')
match.append('~^DDLOperatorEqTest$')
match.append('~^DeferredProxyTest$')
match.append('~^GPUMemorySize$')

View File

@ -714,7 +714,7 @@ bool GrVkCaps::onSurfaceSupportsWritePixels(const GrSurface* surface) const {
return true;
}
GrPixelConfig validate_image_info(VkFormat format, SkColorType ct, bool hasYcbcrConversion) {
static GrPixelConfig validate_image_info(VkFormat format, SkColorType ct, bool hasYcbcrConversion) {
if (format == VK_FORMAT_UNDEFINED) {
// If the format is undefined then it is only valid as an external image which requires that
// we have a valid VkYcbcrConversion.

View File

@ -54,6 +54,10 @@ static GrBackendFormat create_backend_format(GrContext* context,
const GrCaps* caps = context->priv().caps();
switch (context->backend()) {
#ifdef SK_METAL
case GrBackendApi::kMetal:
return caps->getBackendFormatFromColorType(ct);
#endif
case GrBackendApi::kOpenGL: {
const GrGLCaps* glCaps = static_cast<const GrGLCaps*>(caps);
GrGLStandard standard = glCaps->standard();
@ -705,7 +709,6 @@ DEF_GPUTEST_FOR_RENDERING_CONTEXTS(DDLNonTextureabilityTest, reporter, ctxInfo)
GrBackendTexture backend;
sk_sp<SkSurface> s = params.make(context, &backend);
if (!s) {
params.cleanUpBackEnd(context, backend);
continue;
}