#include "ANGLEPerfTest.h"
#include <iostream>
#include <random>
#include <sstream>
#include "util/shader_utils.h"
usingnamespaceangle;
namespace
{
constexpr unsigned int kIterationsPerStep = …;
struct TextureSamplingParams final : public RenderTestParams
{ … };
std::ostream &operator<<(std::ostream &os, const TextureSamplingParams ¶ms)
{ … }
std::string TextureSamplingParams::story() const
{ … }
class TextureSamplingBenchmark : public ANGLERenderTest,
public ::testing::WithParamInterface<TextureSamplingParams>
{ … };
TextureSamplingBenchmark::TextureSamplingBenchmark()
: … { … }
void TextureSamplingBenchmark::initializeBenchmark()
{ … }
void TextureSamplingBenchmark::initShaders()
{ … }
void TextureSamplingBenchmark::initVertexBuffer()
{ … }
void TextureSamplingBenchmark::initTextures()
{ … }
void TextureSamplingBenchmark::destroyBenchmark()
{ … }
void TextureSamplingBenchmark::drawBenchmark()
{ … }
class TextureSamplingMutableFormatBenchmark : public TextureSamplingBenchmark
{ … };
void TextureSamplingMutableFormatBenchmark::initializeBenchmark()
{ … }
void TextureSamplingMutableFormatBenchmark::initTextures()
{ … }
TextureSamplingParams D3D11Params()
{ … }
TextureSamplingParams MetalParams()
{ … }
TextureSamplingParams OpenGLOrGLESParams()
{ … }
TextureSamplingParams VulkanParams()
{ … }
}
TEST_P(TextureSamplingBenchmark, Run)
{ … }
TEST_P(TextureSamplingMutableFormatBenchmark, Run)
{ … }
ANGLE_INSTANTIATE_TEST(…);
GTEST_ALLOW_UNINSTANTIATED_PARAMETERIZED_TEST(…);
ANGLE_INSTANTIATE_TEST(…);