• Home
  • Raw
  • Download

Lines Matching refs:dContext

39 void test_wrapping(GrDirectContext* dContext,  in test_wrapping()  argument
47 GrResourceCache* cache = dContext->priv().getResourceCache(); in test_wrapping()
51 sk_sp<ManagedBackendTexture> mbet = create(dContext, mipMapped, renderable); in test_wrapping()
74 if (dContext->backend() == GrBackend::kVulkan) { in test_wrapping()
80 if (GrRenderable::kYes == renderable && dContext->colorTypeSupportedAsSurface(skColorType)) { in test_wrapping()
81 sk_sp<SkSurface> surf = SkSurface::MakeFromBackendTexture(dContext, in test_wrapping()
97 sk_sp<SkImage> img = SkImage::MakeFromTexture(dContext, in test_wrapping()
107 GrTextureProxy* proxy = sk_gpu_test::GetTextureImageProxy(img.get(), dContext); in test_wrapping()
241 static void check_base_readbacks(GrDirectContext* dContext, in check_base_readbacks() argument
271 proxy = dContext->priv().proxyProvider()->wrapRenderableBackendTexture( in check_base_readbacks()
274 proxy = dContext->priv().proxyProvider()->wrapBackendTexture( in check_base_readbacks()
281 auto swizzle = dContext->priv().caps()->getReadSwizzle(backendTex.getBackendFormat(), in check_base_readbacks()
285 auto surfaceContext = GrSurfaceContext::Make(dContext, readView, info); in check_base_readbacks()
290 if (!surfaceContext->readPixels(dContext, actual, {0, 0})) { in check_base_readbacks()
307 void test_color_init(GrDirectContext* dContext, in test_color_init() argument
317 sk_sp<ManagedBackendTexture> mbet = create(dContext, color, mipmapped, renderable); in test_color_init()
328 check_mipmaps(dContext, mbet->texture(), colorType, expectedColors, reporter, in test_color_init()
333 check_base_readbacks(dContext, mbet->texture(), colorType, renderable, testColor, reporter, in test_color_init()
344 dContext->updateBackendTexture(mbet->texture(), in test_color_init()
355 static void check_mipmaps(GrDirectContext* dContext, in check_mipmaps() argument
363 if (GrBackendApi::kOpenGL == dContext->backend()) { in check_mipmaps()
364 GrGLGpu* glGPU = static_cast<GrGLGpu*>(dContext->priv().getGpu()); in check_mipmaps()
380 auto dstFillContext = GrSurfaceFillContext::Make(dContext, info); in check_mipmaps()
388 auto proxy = dContext->priv().proxyProvider()->wrapBackendTexture(backendTex, in check_mipmaps()
396 auto swizzle = dContext->priv().caps()->getReadSwizzle(backendTex.getBackendFormat(), in check_mipmaps()
430 bool result = dstFillContext->readPixels(dContext, actual, {0, 0}); in check_mipmaps()
472 static void test_pixmap_init(GrDirectContext* dContext, in test_pixmap_init() argument
497 sk_sp<ManagedBackendTexture> mbet = create(dContext, pixmaps, numMipLevels, origin, renderable); in test_pixmap_init()
520 check_mipmaps(dContext, mbet->texture(), grColorType, expectedColors, reporter, in test_pixmap_init()
525 check_base_readbacks(dContext, mbet->texture(), grColorType, renderable, colors[0], in test_pixmap_init()
542 dContext->updateBackendTexture(mbet->texture(), in test_pixmap_init()
635 auto uninitCreateMtd = [colorType](GrDirectContext* dContext, in color_type_backend_allocation_test()
638 auto mbet = ManagedBackendTexture::MakeWithoutData(dContext, in color_type_backend_allocation_test()
647 GrBackendFormat format = dContext->defaultBackendFormat(colorType, in color_type_backend_allocation_test()
661 auto createWithColorMtd = [colorType](GrDirectContext* dContext, in color_type_backend_allocation_test()
665 auto mbet = ManagedBackendTexture::MakeWithData(dContext, in color_type_backend_allocation_test()
676 GrBackendFormat format = dContext->defaultBackendFormat(colorType, in color_type_backend_allocation_test()
690 auto createWithSrcDataMtd = [](GrDirectContext* dContext, in color_type_backend_allocation_test()
696 auto mbet = ManagedBackendTexture::MakeWithData(dContext, in color_type_backend_allocation_test()
705 auto format = dContext->defaultBackendFormat(srcData[0].colorType(), in color_type_backend_allocation_test()
839 auto uninitCreateMtd = [format](GrDirectContext* dContext, in DEF_GPUTEST_FOR_ALL_GL_CONTEXTS()
842 return ManagedBackendTexture::MakeWithoutData(dContext, in DEF_GPUTEST_FOR_ALL_GL_CONTEXTS()
877 auto createWithColorMtd = [format, swizzle](GrDirectContext* dContext, in DEF_GPUTEST_FOR_ALL_GL_CONTEXTS()
882 return ManagedBackendTexture::MakeWithData(dContext, in DEF_GPUTEST_FOR_ALL_GL_CONTEXTS()
982 auto uninitCreateMtd = [format](GrDirectContext* dContext, in DEF_GPUTEST_FOR_VULKAN_CONTEXT()
985 auto mbet = ManagedBackendTexture::MakeWithoutData(dContext, in DEF_GPUTEST_FOR_VULKAN_CONTEXT()
1032 auto createWithColorMtd = [format, swizzle](GrDirectContext* dContext, in DEF_GPUTEST_FOR_VULKAN_CONTEXT()
1037 auto mbet = ManagedBackendTexture::MakeWithData(dContext, in DEF_GPUTEST_FOR_VULKAN_CONTEXT()