Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 "PathOpsExtendedTest.h" | 8 #include "PathOpsExtendedTest.h" |
| 9 #include "PathOpsThreadedCommon.h" | 9 #include "PathOpsThreadedCommon.h" |
| 10 #include "SkBitmap.h" | 10 #include "SkBitmap.h" |
| 11 #include "SkCanvas.h" | 11 #include "SkCanvas.h" |
| 12 #include "SkForceLinking.h" | 12 #include "SkForceLinking.h" |
| 13 #include "SkMatrix.h" | 13 #include "SkMatrix.h" |
| 14 #include "SkMutex.h" | 14 #include "SkMutex.h" |
| 15 #include "SkPaint.h" | 15 #include "SkPaint.h" |
| 16 #include "SkRTConf.h" | |
| 17 #include "SkStream.h" | 16 #include "SkStream.h" |
| 18 | 17 |
| 19 #include <stdlib.h> | 18 #include <stdlib.h> |
| 20 | 19 |
| 21 #ifdef SK_BUILD_FOR_MAC | 20 #ifdef SK_BUILD_FOR_MAC |
| 22 #include <sys/sysctl.h> | 21 #include <sys/sysctl.h> |
| 23 #endif | 22 #endif |
| 24 | 23 |
| 25 bool OpDebug(const SkPath& one, const SkPath& two, SkPathOp op, SkPath* result | 24 bool OpDebug(const SkPath& one, const SkPath& two, SkPathOp op, SkPath* result |
| 26 SkDEBUGPARAMS(bool skipAssert) | 25 SkDEBUGPARAMS(bool skipAssert) |
| (...skipping 597 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 624 return false; | 623 return false; |
| 625 } | 624 } |
| 626 SkASSERT(out == orig); | 625 SkASSERT(out == orig); |
| 627 return true; | 626 return true; |
| 628 } | 627 } |
| 629 | 628 |
| 630 SK_DECLARE_STATIC_MUTEX(gMutex); | 629 SK_DECLARE_STATIC_MUTEX(gMutex); |
| 631 | 630 |
| 632 void initializeTests(skiatest::Reporter* reporter, const char* test) { | 631 void initializeTests(skiatest::Reporter* reporter, const char* test) { |
| 633 #if 0 // doesn't work yet | 632 #if 0 // doesn't work yet |
| 634 SK_CONF_SET("images.jpeg.suppressDecoderWarnings", true); | 633 SK_CONF_SET("images.jpeg.suppressDecoderWarnings", true); |
|
mtklein
2016/08/03 17:43:20
Kill?
hal.canary
2016/08/03 21:23:43
Done.
| |
| 635 SK_CONF_SET("images.png.suppressDecoderWarnings", true); | 634 SK_CONF_SET("images.png.suppressDecoderWarnings", true); |
| 636 #endif | 635 #endif |
| 637 if (reporter->verbose()) { | 636 if (reporter->verbose()) { |
| 638 SkAutoMutexAcquire lock(gMutex); | 637 SkAutoMutexAcquire lock(gMutex); |
| 639 testName = test; | 638 testName = test; |
| 640 size_t testNameSize = strlen(test); | 639 size_t testNameSize = strlen(test); |
| 641 SkFILEStream inFile("../../experimental/Intersection/op.htm"); | 640 SkFILEStream inFile("../../experimental/Intersection/op.htm"); |
| 642 if (inFile.isValid()) { | 641 if (inFile.isValid()) { |
| 643 SkTDArray<char> inData; | 642 SkTDArray<char> inData; |
| 644 inData.setCount((int) inFile.getLength()); | 643 inData.setCount((int) inFile.getLength()); |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 730 if (foundSkip && tests[index].fun != firstTest) { | 729 if (foundSkip && tests[index].fun != firstTest) { |
| 731 SkDebugf(" %s,\n", tests[index].str); | 730 SkDebugf(" %s,\n", tests[index].str); |
| 732 } | 731 } |
| 733 if (tests[index].fun == stopTest || index == last) { | 732 if (tests[index].fun == stopTest || index == last) { |
| 734 break; | 733 break; |
| 735 } | 734 } |
| 736 index += reverse ? -1 : 1; | 735 index += reverse ? -1 : 1; |
| 737 } while (true); | 736 } while (true); |
| 738 #endif | 737 #endif |
| 739 } | 738 } |
| OLD | NEW |