Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1515)

Side by Side Diff: dm/DM.cpp

Issue 1845473004: Revert of Move SkGLContext and some GrGLInterface implementations to skgputest module (Closed) Base URL: https://chromium.googlesource.com/skia.git@debugobject
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « cmake/CMakeLists.txt ('k') | dm/DMGpuSupport.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2013 Google Inc. 2 * Copyright 2013 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "CrashHandler.h" 8 #include "CrashHandler.h"
9 #include "DMJsonWriter.h" 9 #include "DMJsonWriter.h"
10 #include "DMSrcSink.h" 10 #include "DMSrcSink.h"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 63
64 DEFINE_string(uninterestingHashesFile, "", 64 DEFINE_string(uninterestingHashesFile, "",
65 "File containing a list of uninteresting hashes. If a result hashes to s omething in " 65 "File containing a list of uninteresting hashes. If a result hashes to s omething in "
66 "this list, no image is written for that result."); 66 "this list, no image is written for that result.");
67 67
68 DEFINE_int32(shards, 1, "We're splitting source data into this many shards."); 68 DEFINE_int32(shards, 1, "We're splitting source data into this many shards.");
69 DEFINE_int32(shard, 0, "Which shard do I run?"); 69 DEFINE_int32(shard, 0, "Which shard do I run?");
70 DEFINE_bool(simpleCodec, false, "Only decode images to native scale"); 70 DEFINE_bool(simpleCodec, false, "Only decode images to native scale");
71 71
72 using namespace DM; 72 using namespace DM;
73 using sk_gpu_test::GrContextFactory;
74 using sk_gpu_test::GLContext;
75 73
76 /*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~*/ 74 /*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~*/
77 75
78 static const double kStartMs = SkTime::GetMSecs(); 76 static const double kStartMs = SkTime::GetMSecs();
79 77
80 static FILE* gVLog; 78 static FILE* gVLog;
81 79
82 template <typename... Args> 80 template <typename... Args>
83 static void vlog(const char* fmt, Args&&... args) { 81 static void vlog(const char* fmt, Args&&... args) {
84 if (gVLog) { 82 if (gVLog) {
(...skipping 1321 matching lines...) Expand 10 before | Expand all | Expand 10 after
1406 print_status(); 1404 print_status();
1407 info("Finished!\n"); 1405 info("Finished!\n");
1408 return 0; 1406 return 0;
1409 } 1407 }
1410 1408
1411 // TODO: currently many GPU tests are declared outside SK_SUPPORT_GPU guards. 1409 // TODO: currently many GPU tests are declared outside SK_SUPPORT_GPU guards.
1412 // Thus we export the empty RunWithGPUTestContexts when SK_SUPPORT_GPU=0. 1410 // Thus we export the empty RunWithGPUTestContexts when SK_SUPPORT_GPU=0.
1413 namespace skiatest { 1411 namespace skiatest {
1414 namespace { 1412 namespace {
1415 typedef void(*TestWithGrContext)(skiatest::Reporter*, GrContext*); 1413 typedef void(*TestWithGrContext)(skiatest::Reporter*, GrContext*);
1416 typedef void(*TestWithGrContextAndGLContext)(skiatest::Reporter*, GrContext*, GL Context*); 1414 typedef void(*TestWithGrContextAndGLContext)(skiatest::Reporter*, GrContext*, Sk GLContext*);
1417 #if SK_SUPPORT_GPU 1415 #if SK_SUPPORT_GPU
1418 template<typename T> 1416 template<typename T>
1419 void call_test(T test, skiatest::Reporter* reporter, const GrContextFactory::Con textInfo& context); 1417 void call_test(T test, skiatest::Reporter* reporter, const GrContextFactory::Con textInfo& context);
1420 template<> 1418 template<>
1421 void call_test(TestWithGrContext test, skiatest::Reporter* reporter, 1419 void call_test(TestWithGrContext test, skiatest::Reporter* reporter,
1422 const GrContextFactory::ContextInfo& context) { 1420 const GrContextFactory::ContextInfo& context) {
1423 test(reporter, context.fGrContext); 1421 test(reporter, context.fGrContext);
1424 } 1422 }
1425 template<> 1423 template<>
1426 void call_test(TestWithGrContextAndGLContext test, skiatest::Reporter* reporter, 1424 void call_test(TestWithGrContextAndGLContext test, skiatest::Reporter* reporter,
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
1495 Reporter* reporter, 1493 Reporter* reporter,
1496 GrContextFactory* fac tory); 1494 GrContextFactory* fac tory);
1497 } // namespace skiatest 1495 } // namespace skiatest
1498 1496
1499 #if !defined(SK_BUILD_FOR_IOS) 1497 #if !defined(SK_BUILD_FOR_IOS)
1500 int main(int argc, char** argv) { 1498 int main(int argc, char** argv) {
1501 SkCommandLineFlags::Parse(argc, argv); 1499 SkCommandLineFlags::Parse(argc, argv);
1502 return dm_main(); 1500 return dm_main();
1503 } 1501 }
1504 #endif 1502 #endif
OLDNEW
« no previous file with comments | « cmake/CMakeLists.txt ('k') | dm/DMGpuSupport.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698