Flutter Engine
The Flutter Engine
third_party
skia
tools
gpu
mtl
MtlTestContext.h
Go to the documentation of this file.
1
/*
2
* Copyright 2017 Google Inc.
3
*
4
* Use of this source code is governed by a BSD-style license that can be
5
* found in the LICENSE file.
6
*/
7
8
#ifndef MtlTestContext_h
9
#define MtlTestContext_h
10
11
#include "
tools/gpu/TestContext.h
"
12
13
#ifdef SK_METAL
14
15
#include "
include/gpu/ganesh/mtl/GrMtlBackendContext.h
"
16
17
namespace
sk_gpu_test
{
18
class
MtlTestContext :
public
TestContext {
19
public
:
20
GrBackendApi
backend
()
override
{
return
GrBackendApi::kMetal
; }
21
22
const
GrMtlBackendContext
& getMtlBackendContext()
const
{
23
return
fMtl;
24
}
25
26
protected
:
27
MtlTestContext(
const
GrMtlBackendContext
& mtl)
28
: fMtl(mtl) {}
29
30
GrMtlBackendContext
fMtl;
31
32
private
:
33
using
INHERITED
= TestContext;
34
};
35
36
/**
37
* Creates Metal context object bound to the native Metal library.
38
*/
39
MtlTestContext*
CreatePlatformMtlTestContext
(MtlTestContext*);
40
41
}
// namespace sk_gpu_test
42
43
#endif
44
45
#endif
/* MtlTestContext_h */
backend
const char * backend
Definition:
CommonFlagsConfig.cpp:42
GrMtlBackendContext.h
GrBackendApi
GrBackendApi
Definition:
GrTypes.h:95
GrBackendApi::kMetal
@ kMetal
INHERITED
#define INHERITED(method,...)
Definition:
SkRecorder.cpp:128
TestContext.h
sk_gpu_test
Definition:
gm_bindings.cpp:339
sk_gpu_test::CreatePlatformMtlTestContext
MtlTestContext * CreatePlatformMtlTestContext(MtlTestContext *sharedContext)
Definition:
MtlTestContext.mm:79
GrMtlBackendContext
Definition:
GrMtlBackendContext.h:16
Generated on Sun Jun 23 2024 21:56:50 for Flutter Engine by
1.9.4