diff --git a/lib/web_ui/skwasm/image.cpp b/lib/web_ui/skwasm/image.cpp index 74df647625600..0e7665d0722d2 100644 --- a/lib/web_ui/skwasm/image.cpp +++ b/lib/web_ui/skwasm/image.cpp @@ -12,6 +12,7 @@ #include "third_party/skia/include/core/SkImage.h" #include "third_party/skia/include/core/SkImageInfo.h" #include "third_party/skia/include/core/SkPicture.h" +#include "third_party/skia/include/gpu/GpuTypes.h" #include "third_party/skia/include/gpu/GrBackendSurface.h" #include "third_party/skia/include/gpu/GrDirectContext.h" #include "third_party/skia/include/gpu/ganesh/GrExternalTextureGenerator.h" @@ -90,7 +91,7 @@ class TextureSourceImageGenerator : public GrExternalTextureGenerator { std::unique_ptr generateExternalTexture( GrRecordingContext* context, - GrMipMapped mipmapped) override { + skgpu::Mipmapped mipmapped) override { GrGLTextureInfo glInfo; glInfo.fID = skwasm_createGlTextureFromTextureSource( _textureSourceWrapper->getTextureSource(), fInfo.width(), diff --git a/shell/common/rasterizer.cc b/shell/common/rasterizer.cc index 4ed0b2fb4fd31..9a7e6e16552b0 100644 --- a/shell/common/rasterizer.cc +++ b/shell/common/rasterizer.cc @@ -27,6 +27,7 @@ #include "third_party/skia/include/core/SkSize.h" #include "third_party/skia/include/core/SkSurface.h" #include "third_party/skia/include/encode/SkPngEncoder.h" +#include "third_party/skia/include/gpu/GpuTypes.h" #include "third_party/skia/include/gpu/GrBackendSurface.h" #include "third_party/skia/include/gpu/GrDirectContext.h" #include "third_party/skia/include/gpu/GrTypes.h" @@ -346,7 +347,7 @@ std::unique_ptr Rasterizer::MakeSkiaGpuImage( GrBackendTexture texture = context->createBackendTexture( image_info.width(), image_info.height(), image_info.colorType(), - GrMipmapped::kNo, GrRenderable::kYes); + skgpu::Mipmapped::kNo, GrRenderable::kYes); if (!texture.isValid()) { result = std::make_unique( GrBackendTexture(), nullptr, nullptr, diff --git a/shell/gpu/gpu_surface_metal_skia.mm b/shell/gpu/gpu_surface_metal_skia.mm index ed884151d0ab7..652891c9acbd6 100644 --- a/shell/gpu/gpu_surface_metal_skia.mm +++ b/shell/gpu/gpu_surface_metal_skia.mm @@ -24,6 +24,7 @@ #include "third_party/skia/include/core/SkSize.h" #include "third_party/skia/include/core/SkSurface.h" #include "third_party/skia/include/core/SkSurfaceProps.h" +#include "third_party/skia/include/gpu/GpuTypes.h" #include "third_party/skia/include/gpu/GrBackendSurface.h" #include "third_party/skia/include/gpu/ganesh/SkSurfaceGanesh.h" #include "third_party/skia/include/ports/SkCFObject.h" @@ -44,7 +45,7 @@ SkSurface::ReleaseContext release_context) { GrMtlTextureInfo info; info.fTexture.reset([texture retain]); - GrBackendTexture backend_texture(texture.width, texture.height, GrMipmapped::kNo, info); + GrBackendTexture backend_texture(texture.width, texture.height, skgpu::Mipmapped::kNo, info); return SkSurfaces::WrapBackendTexture( context, backend_texture, origin, static_cast(sample_cnt), color_type, std::move(color_space), props, release_proc, release_context); diff --git a/shell/platform/darwin/graphics/FlutterDarwinExternalTextureMetal.mm b/shell/platform/darwin/graphics/FlutterDarwinExternalTextureMetal.mm index 9c0190e827dec..55ca7cb906408 100644 --- a/shell/platform/darwin/graphics/FlutterDarwinExternalTextureMetal.mm +++ b/shell/platform/darwin/graphics/FlutterDarwinExternalTextureMetal.mm @@ -10,6 +10,7 @@ #include "third_party/skia/include/core/SkColorSpace.h" #include "third_party/skia/include/core/SkImage.h" #include "third_party/skia/include/core/SkYUVAInfo.h" +#include "third_party/skia/include/gpu/GpuTypes.h" #include "third_party/skia/include/gpu/GrBackendSurface.h" #include "third_party/skia/include/gpu/GrDirectContext.h" #include "third_party/skia/include/gpu/GrYUVABackendTextures.h" @@ -295,7 +296,7 @@ @implementation FlutterDarwinExternalTextureSkImageWrapper GrBackendTexture skiaBackendTextures[2]; skiaBackendTextures[0] = GrBackendTexture(/*width=*/width, /*height=*/height, - /*mipMapped=*/GrMipMapped::kNo, + /*mipMapped=*/skgpu::Mipmapped::kNo, /*textureInfo=*/ySkiaTextureInfo); GrMtlTextureInfo uvSkiaTextureInfo; @@ -303,7 +304,7 @@ @implementation FlutterDarwinExternalTextureSkImageWrapper skiaBackendTextures[1] = GrBackendTexture(/*width=*/width, /*height=*/height, - /*mipMapped=*/GrMipMapped::kNo, + /*mipMapped=*/skgpu::Mipmapped::kNo, /*textureInfo=*/uvSkiaTextureInfo); SkYUVAInfo yuvaInfo(skiaBackendTextures[0].dimensions(), SkYUVAInfo::PlaneConfig::kY_UV, SkYUVAInfo::Subsampling::k444, colorSpace); @@ -324,7 +325,7 @@ GrYUVABackendTextures yuvaBackendTextures(yuvaInfo, skiaBackendTextures, GrBackendTexture skiaBackendTexture(/*width=*/width, /*height=*/height, - /*mipMapped=*/GrMipMapped ::kNo, + /*mipMapped=*/skgpu::Mipmapped ::kNo, /*textureInfo=*/skiaTextureInfo); return SkImages::BorrowTextureFrom(grContext, skiaBackendTexture, kTopLeft_GrSurfaceOrigin, diff --git a/shell/platform/embedder/embedder.cc b/shell/platform/embedder/embedder.cc index af32d9ffa3f1c..eb6b4edb85bbf 100644 --- a/shell/platform/embedder/embedder.cc +++ b/shell/platform/embedder/embedder.cc @@ -20,6 +20,7 @@ #include "third_party/dart/runtime/bin/elf_loader.h" #include "third_party/dart/runtime/include/dart_native_api.h" #include "third_party/skia/include/core/SkSurface.h" +#include "third_party/skia/include/gpu/GpuTypes.h" #include "third_party/skia/include/gpu/GrBackendSurface.h" #include "third_party/skia/include/gpu/ganesh/SkSurfaceGanesh.h" @@ -924,10 +925,10 @@ static sk_sp MakeSkSurfaceFromBackingStore( sk_cfp mtl_texture; mtl_texture.retain(metal->texture.texture); texture_info.fTexture = mtl_texture; - GrBackendTexture backend_texture(config.size.width, // - config.size.height, // - GrMipMapped::kNo, // - texture_info // + GrBackendTexture backend_texture(config.size.width, // + config.size.height, // + skgpu::Mipmapped::kNo, // + texture_info // ); SkSurfaceProps surface_properties(0, kUnknown_SkPixelGeometry); diff --git a/shell/platform/embedder/tests/embedder_metal_unittests.mm b/shell/platform/embedder/tests/embedder_metal_unittests.mm index f3666d9fee4c4..c23a6553a5360 100644 --- a/shell/platform/embedder/tests/embedder_metal_unittests.mm +++ b/shell/platform/embedder/tests/embedder_metal_unittests.mm @@ -21,6 +21,7 @@ #include "flutter/testing/testing.h" #include "third_party/skia/include/core/SkSurface.h" +#include "third_party/skia/include/gpu/GpuTypes.h" #include "third_party/skia/include/gpu/GrBackendSurface.h" #include "third_party/skia/include/gpu/ganesh/SkSurfaceGanesh.h" @@ -63,8 +64,8 @@ void* texture) { GrMtlTextureInfo info; info.fTexture.reset([(id)texture retain]); - GrBackendTexture backend_texture(texture_size.width(), texture_size.height(), GrMipmapped::kNo, - info); + GrBackendTexture backend_texture(texture_size.width(), texture_size.height(), + skgpu::Mipmapped::kNo, info); return SkSurfaces::WrapBackendTexture(skia_context.get(), backend_texture, kTopLeft_GrSurfaceOrigin, 1, kBGRA_8888_SkColorType, diff --git a/shell/platform/embedder/tests/embedder_test_backingstore_producer.cc b/shell/platform/embedder/tests/embedder_test_backingstore_producer.cc index eb74388dac16c..0c67e3dccea2d 100644 --- a/shell/platform/embedder/tests/embedder_test_backingstore_producer.cc +++ b/shell/platform/embedder/tests/embedder_test_backingstore_producer.cc @@ -11,6 +11,7 @@ #include "third_party/skia/include/core/SkImageInfo.h" #include "third_party/skia/include/core/SkSize.h" #include "third_party/skia/include/core/SkSurface.h" +#include "third_party/skia/include/gpu/GpuTypes.h" #include "third_party/skia/include/gpu/GrBackendSurface.h" #include "third_party/skia/include/gpu/ganesh/SkSurfaceGanesh.h" #include "third_party/skia/include/gpu/ganesh/gl/GrGLBackendSurface.h" @@ -281,7 +282,7 @@ bool EmbedderTestBackingStoreProducer::CreateMTLTexture( GrMtlTextureInfo skia_texture_info; skia_texture_info.fTexture.reset(SkCFSafeRetain(texture_info.texture)); GrBackendTexture backend_texture(surface_size.width(), surface_size.height(), - GrMipmapped::kNo, skia_texture_info); + skgpu::Mipmapped::kNo, skia_texture_info); sk_sp surface = SkSurfaces::WrapBackendTexture( context_.get(), backend_texture, kTopLeft_GrSurfaceOrigin, 1, diff --git a/testing/test_metal_surface_impl.mm b/testing/test_metal_surface_impl.mm index 34878a9613d0d..cf2c6931f8621 100644 --- a/testing/test_metal_surface_impl.mm +++ b/testing/test_metal_surface_impl.mm @@ -15,6 +15,7 @@ #include "third_party/skia/include/core/SkRefCnt.h" #include "third_party/skia/include/core/SkSize.h" #include "third_party/skia/include/core/SkSurface.h" +#include "third_party/skia/include/gpu/GpuTypes.h" #include "third_party/skia/include/gpu/GrBackendSurface.h" #include "third_party/skia/include/gpu/ganesh/SkSurfaceGanesh.h" @@ -26,8 +27,8 @@ GrMtlTextureInfo skia_texture_info; skia_texture_info.fTexture.reset([texture retain]); - GrBackendTexture backend_texture(surface_size.width(), surface_size.height(), GrMipmapped::kNo, - skia_texture_info); + GrBackendTexture backend_texture(surface_size.width(), surface_size.height(), + skgpu::Mipmapped::kNo, skia_texture_info); sk_sp surface = SkSurfaces::WrapBackendTexture( test_metal_context_.GetSkiaContext().get(), backend_texture, kTopLeft_GrSurfaceOrigin, 1,