Hash :
4ffc254e
Author :
Date :
2020-01-08T09:58:24
Only initialize the timestamp query pools if the extension is available. Also added a few assertions to ensure that timestamp queries aren't attempted when support is missing. Bug: angleproject:4114 Change-Id: Ie6d7d5face59f9bc137aebd86c9d0e965773e6e6 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1992184 Commit-Queue: Eric Binet <ericbinet@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
//
// Copyright 2020 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
#ifndef ANGLE_TESTS_ANGLE_TEST_PLATFORM_H_
#define ANGLE_TESTS_ANGLE_TEST_PLATFORM_H_
#include <string>
#include "util/EGLWindow.h"
// Driver vendors
bool IsAdreno();
// Renderer back-ends
// Note: FL9_3 is explicitly *not* considered D3D11.
bool IsD3D11();
bool IsD3D11_FL93();
// Is a D3D9-class renderer.
bool IsD3D9();
// Is D3D9 or SM9_3 renderer.
bool IsD3DSM3();
bool IsDesktopOpenGL();
bool IsOpenGLES();
bool IsOpenGL();
bool IsNULL();
bool IsVulkan();
bool IsMetal();
// Debug/Release
bool IsDebug();
bool IsRelease();
bool EnsureGLExtensionEnabled(const std::string &extName);
bool IsEGLClientExtensionEnabled(const std::string &extName);
bool IsEGLDeviceExtensionEnabled(EGLDeviceEXT device, const std::string &extName);
bool IsEGLDisplayExtensionEnabled(EGLDisplay display, const std::string &extName);
bool IsGLExtensionEnabled(const std::string &extName);
bool IsGLExtensionRequestable(const std::string &extName);
#endif // ANGLE_TESTS_ANGLE_TEST_PLATFORM_H_