c7ad40f76f
Most of this is (obviously) not necessary to do, but once I started, I figured I'd just get it all. Tools (nanobench, DM, skiaserve), all GMs, benches, and unit tests, plus support code (command line parsing and config stuff). This is almost entirely mechanical. Bug: skia: Change-Id: I209500f8df8c5bd43f8298ff26440d1c4d7425fb Reviewed-on: https://skia-review.googlesource.com/131153 Reviewed-by: Mike Klein <mtklein@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
32 lines
1.3 KiB
C++
32 lines
1.3 KiB
C++
/*
|
|
* Copyright 2017 Google Inc.
|
|
*
|
|
* Use of this source code is governed by a BSD-style license that can be
|
|
* found in the LICENSE file.
|
|
*/
|
|
|
|
#include "Test.h"
|
|
|
|
class GrSurfaceContext;
|
|
class GrSurfaceProxy;
|
|
|
|
// Ensure that reading back from 'srcContext' as RGBA 8888 matches 'expectedPixelValues
|
|
void test_read_pixels(skiatest::Reporter*,
|
|
GrSurfaceContext* srcContext, uint32_t expectedPixelValues[],
|
|
const char* testName);
|
|
|
|
// See if trying to write RGBA 8888 pixels to 'dstContext' matches matches the
|
|
// expectation ('expectedToWork')
|
|
void test_write_pixels(skiatest::Reporter*,
|
|
GrSurfaceContext* srcContext, bool expectedToWork, const char* testName);
|
|
|
|
// Ensure that the pixels can be copied from 'proxy' to an RGBA 8888 destination (both
|
|
// texture-backed and rendertarget-backed).
|
|
void test_copy_from_surface(skiatest::Reporter*, GrContext*,
|
|
GrSurfaceProxy* proxy, uint32_t expectedPixelValues[],
|
|
bool onlyTestRTConfig, const char* testName);
|
|
|
|
// Ensure that RGBA 8888 pixels can be copied into 'dstContext'
|
|
void test_copy_to_surface(skiatest::Reporter*, GrProxyProvider*,
|
|
GrSurfaceContext* dstContext, const char* testName);
|