| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 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 "SkBitmap.h" | 8 #include "SkBitmap.h" |
| 9 #include "SkCanvas.h" | 9 #include "SkCanvas.h" |
| 10 #include "SkData.h" | 10 #include "SkData.h" |
| 11 #include "SkDiscardableMemoryPool.h" | 11 #include "SkDiscardableMemoryPool.h" |
| 12 #include "SkImageGeneratorPriv.h" | 12 #include "SkImageGeneratorPriv.h" |
| 13 #include "SkMatrixUtils.h" | 13 #include "SkMatrixUtils.h" |
| 14 #include "SkPaint.h" | 14 #include "SkPaint.h" |
| 15 #include "SkPath.h" |
| 15 #include "SkRandom.h" | 16 #include "SkRandom.h" |
| 16 #include "SkShader.h" | 17 #include "SkShader.h" |
| 17 #include "SkSurface.h" | 18 #include "SkSurface.h" |
| 18 #include "Test.h" | 19 #include "Test.h" |
| 19 | 20 |
| 20 // A BitmapFactory that always fails when asked to return pixels. | 21 // A BitmapFactory that always fails when asked to return pixels. |
| 21 class FailureImageGenerator : public SkImageGenerator { | 22 class FailureImageGenerator : public SkImageGenerator { |
| 22 public: | 23 public: |
| 23 FailureImageGenerator() : SkImageGenerator(SkImageInfo::MakeN32Premul(100, 1
00)) {} | 24 FailureImageGenerator() : SkImageGenerator(SkImageInfo::MakeN32Premul(100, 1
00)) {} |
| 24 protected: | 25 protected: |
| (...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 303 | 304 |
| 304 // ensure that we draw nothing if srcR does not intersect the bitmap | 305 // ensure that we draw nothing if srcR does not intersect the bitmap |
| 305 REPORTER_ASSERT(reporter, check_for_all_zeros(dst)); | 306 REPORTER_ASSERT(reporter, check_for_all_zeros(dst)); |
| 306 | 307 |
| 307 test_nan_antihair(); | 308 test_nan_antihair(); |
| 308 test_giantrepeat_crbug118018(reporter); | 309 test_giantrepeat_crbug118018(reporter); |
| 309 | 310 |
| 310 test_treatAsSprite(reporter); | 311 test_treatAsSprite(reporter); |
| 311 test_faulty_pixelref(reporter); | 312 test_faulty_pixelref(reporter); |
| 312 } | 313 } |
| OLD | NEW |