diff options
author | 2016-09-29 09:49:06 -0700 | |
---|---|---|
committer | 2016-09-29 09:49:06 -0700 | |
commit | 50094fb489543655df026be4e4f99e09e57a1f49 (patch) | |
tree | 5c8a936664ddbf5c51e615533200957871a53b6d /tools/gpu/gl/angle/GLTestContext_angle.h | |
parent | 6b1da0a53864530257906e31f0023a7b8ffccd07 (diff) |
Explicit control in tools of ANGLE frontend and backend
Update the ANGLE test GL context, GrContextFactory, and config parsing to allow explicit control of ANGLE front/backend.
This will allow us to explicitly test ES2 vs ES3 interfaces to ANGLE as well as D3D9, D3D11, and OpenGL backends.
Also makes the angle api types valid in all builds (but will just fail when SK_ANGLE=1 or not on windows for the d3d backends).
BUG=skia:5804
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2381033002
NOTREECHECKS=true
NOTRY=true
NOPRESUBMIT=true
Review-Url: https://codereview.chromium.org/2381033002
Diffstat (limited to 'tools/gpu/gl/angle/GLTestContext_angle.h')
-rw-r--r-- | tools/gpu/gl/angle/GLTestContext_angle.h | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/tools/gpu/gl/angle/GLTestContext_angle.h b/tools/gpu/gl/angle/GLTestContext_angle.h index 0140477a54..0da747f30f 100644 --- a/tools/gpu/gl/angle/GLTestContext_angle.h +++ b/tools/gpu/gl/angle/GLTestContext_angle.h @@ -13,18 +13,24 @@ namespace sk_gpu_test { /** - * Creates a GrGLInterface for the currently ANGLE GL context currently bound in ANGLE's EGL - * implementation. + * Creates a GrGLInterface for the current ANGLE GLES Context. Here current means bound in ANGLE's + * implementation of EGL. */ const GrGLInterface* CreateANGLEGLInterface(); -#ifdef SK_BUILD_FOR_WIN -/** Creates a GLTestContext backed by ANGLE's Direct3D backend. */ -GLTestContext* CreateANGLEDirect3DGLTestContext(); -#endif +enum class ANGLEBackend { + kD3D9, + kD3D11, + kOpenGL +}; + +enum class ANGLEContextVersion { + kES2, + kES3 +}; -/** Creates a GLTestContext backed by ANGLE's OpenGL backend. */ -GLTestContext* CreateANGLEOpenGLGLTestContext(); +/** Creates a GLTestContext backed by ANGLE. */ +GLTestContext* CreateANGLETestContext(ANGLEBackend, ANGLEContextVersion); } // namespace sk_gpu_test #endif |