Flutter Engine
The Flutter Engine
third_party
skia
tools
gpu
d3d
D3DTestContext.h
Go to the documentation of this file.
1
/*
2
* Copyright 2020 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 D3DTestContext_DEFINED
9
#define D3DTestContext_DEFINED
10
11
#include "
tools/gpu/TestContext.h
"
12
13
#ifdef SK_DIRECT3D
14
15
#include "
include/gpu/d3d/GrD3DBackendContext.h
"
16
17
namespace
sk_gpu_test
{
18
class
D3DTestContext :
public
TestContext {
19
public
:
20
virtual
GrBackendApi
backend
()
override
{
return
GrBackendApi::kDirect3D
; }
21
22
const
GrD3DBackendContext
& getD3DBackendContext()
const
{
23
return
fD3D;
24
}
25
26
protected
:
27
D3DTestContext(
const
GrD3DBackendContext
& d3d,
bool
ownsContext)
28
: fD3D(d3d)
29
, fOwnsContext(ownsContext) {}
30
31
GrD3DBackendContext
fD3D;
32
bool
fOwnsContext;
33
34
private
:
35
using
INHERITED
= TestContext;
36
};
37
38
/**
39
* Creates D3D context object bound to the native D3D library.
40
*/
41
D3DTestContext* CreatePlatformD3DTestContext(D3DTestContext*);
42
43
}
// namespace sk_gpu_test
44
45
#endif
46
47
#endif
backend
const char * backend
Definition:
CommonFlagsConfig.cpp:42
GrD3DBackendContext.h
GrBackendApi
GrBackendApi
Definition:
GrTypes.h:95
GrBackendApi::kDirect3D
@ kDirect3D
INHERITED
#define INHERITED(method,...)
Definition:
SkRecorder.cpp:128
TestContext.h
sk_gpu_test
Definition:
gm_bindings.cpp:339
GrD3DBackendContext
Definition:
GrD3DBackendContext.h:27
Generated on Sun Jun 23 2024 21:56:50 for Flutter Engine by
1.9.4