18#if defined(SK_GRAPHITE)
49 static bool supported =
false;
51 static std::once_flag
flag;
52 std::call_once(
flag, []() {
56 std::unique_ptr<TestContext> testCtx(sk_gpu_test::CreatePlatformVkTestContext(
nullptr));
65#if defined(SK_BUILD_FOR_UNIX) || defined(SK_BUILD_FOR_WIN) || defined(SK_BUILD_FOR_MAC)
72#ifdef SK_BUILD_FOR_ANDROID
104 if (filter && !(*filter)(contextType)) {
121#if defined(SK_GRAPHITE)
129 ContextFactory factory(
options);
137 if (filter && !(*filter)(contextType)) {
157void SkQP::printBackendInfo(
const char* dstPath) {
158#ifdef SK_ENABLE_DUMP_GPU
160 out.writeText(
"[\n");
164 for (
auto contextType : contextsToDump) {
165 std::unique_ptr<TestContext> testCtx;
166 switch (contextType) {
178 testCtx.reset(sk_gpu_test::CreatePlatformVkTestContext(
nullptr));
187 testCtx->makeCurrent();
192 out.writeText(
",\n");
196 out.writeText(
"]\n");
static void info(const char *fmt,...) SK_PRINTF_LIKE(1
void flushAndSubmit(GrSyncCpu sync=GrSyncCpu::kNo)
GrDirectContext * directContext() const
TestContext * testContext() const
FlutterSemanticsFlag flag
GLTestContext * CreatePlatformGLTestContext(GrGLStandard forcedGpuAPI, GLTestContext *shareContext)
GrBackendApi ContextTypeBackend(skgpu::ContextType type)
static const int kContextTypeCount
@ kVulkan
ANGLE on Metal ES 3 context.
@ kMock
Dawn on OpenGL ES.
const char * ContextTypeName(skgpu::ContextType type)
void(Reporter *, skgpu::graphite::Context *, skiatest::graphite::GraphiteTestContext *) GraphiteTestFn
void RunWithGraphiteTestContexts(GraphiteTestFn *, ContextTypeFilterFn *filter, Reporter *, const TestOptions &)
void RunWithGaneshTestContexts(GrContextTestFn *testFn, ContextTypeFilterFn *filter, Reporter *reporter, const GrContextOptions &options)
bool IsMetalContextType(skgpu::ContextType type)
bool IsGLContextType(skgpu::ContextType type)
bool ContextTypeFilterFn(GpuContextType)
bool IsMockContextType(skgpu::ContextType type)
bool IsDirect3DContextType(skgpu::ContextType type)
static constexpr auto kNativeGLType
void GrContextTestFn(Reporter *, const sk_gpu_test::ContextInfo &)
bool IsDawnContextType(skgpu::ContextType type)
static bool skip_context(skgpu::ContextType contextType)
static bool vk_has_physical_devices()
bool IsVulkanContextType(skgpu::ContextType type)
GraphiteTestContext * fTestContext
skgpu::graphite::Context * fContext